Re: [PATCH v2 1/5] ARM: head-common.S: speed up startup code

2017-10-03 Thread Ard Biesheuvel
ut. This will >> allow for further cleanups in the non-XIP linker script. >> >> Signed-off-by: Nicolas Pitre <n...@linaro.org> >> Reviewed-by: Ard Biesheuvel <ard.biesheu...@linaro.org> > > This is now commit 9520b1a1b5f7a348 ("ARM: head-common.S: speed

Re: [PATCH 05/15] ARM: head: use PC-relative insn sequence for __smp_alt

2017-08-14 Thread Ard Biesheuvel
On 14 August 2017 at 17:19, Tony Lindgren <t...@atomide.com> wrote: > * Ard Biesheuvel <ard.biesheu...@linaro.org> [170811 12:37]: >> On 11 August 2017 at 16:13, Tony Lindgren <t...@atomide.com> wrote: >> > * Ard Biesheuvel <ard.biesheu...@linaro.org> [1

Re: [PATCH 05/15] ARM: head: use PC-relative insn sequence for __smp_alt

2017-08-11 Thread Ard Biesheuvel
On 11 August 2017 at 21:06, Nicolas Pitre <nicolas.pi...@linaro.org> wrote: > On Fri, 11 Aug 2017, Ard Biesheuvel wrote: > >> On 11 August 2017 at 20:58, Nicolas Pitre <nicolas.pi...@linaro.org> wrote: >> > On Fri, 11 Aug 2017, Ard Biesheuvel wrote: >> &

Re: [PATCH 05/15] ARM: head: use PC-relative insn sequence for __smp_alt

2017-08-11 Thread Ard Biesheuvel
On 11 August 2017 at 20:58, Nicolas Pitre <nicolas.pi...@linaro.org> wrote: > On Fri, 11 Aug 2017, Ard Biesheuvel wrote: > >> On 11 August 2017 at 16:13, Tony Lindgren <t...@atomide.com> wrote: >> > * Ard Biesheuvel <ard.biesheu...@linaro.org> [170805

Re: [PATCH 05/15] ARM: head: use PC-relative insn sequence for __smp_alt

2017-08-11 Thread Ard Biesheuvel
On 11 August 2017 at 16:13, Tony Lindgren <t...@atomide.com> wrote: > * Ard Biesheuvel <ard.biesheu...@linaro.org> [170805 13:54]: >> Replace the open coded PC relative offset calculations with a pair >> of adr_l invocations. >> >> Signed-off-by: Ar

Re: [PATCH 12/15] arm-soc: omap: replace open coded VA->PA calculations

2017-08-11 Thread Ard Biesheuvel
On 10 August 2017 at 15:03, Tony Lindgren <t...@atomide.com> wrote: > * Ard Biesheuvel <ard.biesheu...@linaro.org> [170810 02:23]: >> On 9 August 2017 at 22:05, Tony Lindgren <t...@atomide.com> wrote: >> > * Ard Biesheuvel <ard.biesheu...@linaro.org> [1708

Re: [PATCH 12/15] arm-soc: omap: replace open coded VA->PA calculations

2017-08-10 Thread Ard Biesheuvel
On 9 August 2017 at 22:05, Tony Lindgren <t...@atomide.com> wrote: > * Ard Biesheuvel <ard.biesheu...@linaro.org> [170809 12:24]: >> On 9 August 2017 at 20:05, Tony Lindgren <t...@atomide.com> wrote: >> > * Ard Biesheuvel <ard.biesheu...@linaro.org> [1

Re: [PATCH 01/15] ARM: assembler: introduce adr_l, ldr_l and str_l macros

2017-08-08 Thread Ard Biesheuvel
On 8 August 2017 at 16:10, Nicolas Pitre <nicolas.pi...@linaro.org> wrote: > On Sat, 5 Aug 2017, Ard Biesheuvel wrote: > >> Like arm64, ARM supports position independent code sequences that >> produce symbol references with a greater reach than the ordinary >> adr/ldr

[PATCH 10/15] arm-soc: exynos: replace open coded VA->PA conversions

2017-08-05 Thread Ard Biesheuvel
This replaces a couple of open coded calculations to obtain the physical address of a far symbol with calls to the new adr_l etc macros. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mach-exynos/headsmp.S | 9 +-- arch/arm/mach-exynos/sleep.S

[PATCH 15/15] ARM: l2c: replace open coded VA->PA calculation

2017-08-05 Thread Ard Biesheuvel
This replaces an open coded calculation to obtain the physical address of a far symbol with a call to the new adr_l macro. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mm/l2c-l2x0-resume.S | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git

[PATCH 14/15] arm-soc: shmobile: replace open coded VA->PA calculation

2017-08-05 Thread Ard Biesheuvel
This replaces a couple of open coded calculations to obtain the physical address of a far symbol with calls to the new adr_l etc macros. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mach-shmobile/headsmp.S | 14 -- 1 file changed, 4 insertions(

[PATCH 13/15] arm-soc: various: replace open coded VA->PA calculation of pen_release

2017-08-05 Thread Ard Biesheuvel
This replaces a few copies of the open coded calculations of the physical address of 'pen_release' in the secondary startup code of a couple of platforms. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mach-prima2/headsmp.S| 11 +++ arch/arm/mach

[PATCH 12/15] arm-soc: omap: replace open coded VA->PA calculations

2017-08-05 Thread Ard Biesheuvel
This replaces a couple of open coded calculations to obtain the physical address of a far symbol with calls to the new adr_l etc macros. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mach-omap2/sleep34xx.S | 21 arch/arm/mach-omap2/sleep44xx.

[PATCH 08/15] ARM: head.S: use PC relative insn sequence to calculate PHYS_OFFSET

2017-08-05 Thread Ard Biesheuvel
Replace the open coded arithmetic with a simple adr_l/sub pair. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head.S | 10 ++ 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S index 939543

[PATCH 11/15] arm-soc: mvebu: replace open coded VA->PA conversion

2017-08-05 Thread Ard Biesheuvel
This replaces an open coded calculation to obtain the physical address of a far symbol with a call to the new ldr_l etc macro. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/mach-mvebu/coherency_ll.S | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff

[PATCH 09/15] ARM: kvm: replace open coded VA->PA calculations with adr_l call

2017-08-05 Thread Ard Biesheuvel
Replace the open coded calculations of the actual physical address of the KVM stub vector table with a single adr_l invocation. Cc: Marc Zyngier <marc.zyng...@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/boot/compressed/head.S | 15 ++--- arc

[PATCH 07/15] ARM: head.S: use PC-relative insn sequences for __fixup_pv_table

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with adr_l and mov_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head.S | 27 ++-- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/arch/arm/kernel/head.S

[PATCH 04/15] ARM: head.S: use PC-relative insn sequence for secondary_data

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with adr_l and ldr_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head.S | 19 --- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/arch/arm/kernel/head.S b/ar

[PATCH 05/15] ARM: head: use PC-relative insn sequence for __smp_alt

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with a pair of adr_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head.S | 12 ++-- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/arch/arm/kernel/head.S b/arch/arm/

[PATCH 06/15] ARM: sleep.S: use PC-relative insn sequence for sleep_save_sp/mpidr_hash

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with adr_l and ldr_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/sleep.S | 16 +++- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/arch/arm/kernel/sleep.S b/ar

[PATCH 02/15] ARM: head-common.S: use PC-relative insn sequence for __proc_info

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with a pair of adr_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head-common.S | 22 ++-- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/arch/arm/kerne

[PATCH 03/15] ARM: head-common.S: use PC-relative insn sequence for __turn_mmu_on

2017-08-05 Thread Ard Biesheuvel
Replace the open coded PC relative offset calculations with a pair of adr_l invocations. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/kernel/head.S | 12 ++-- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/arch/arm/kernel/head.S b/arch/arm/

[PATCH 00/15] ARM: add and use convenience macros for PC relative references

2017-08-05 Thread Ard Biesheuvel
on the first one. I understand there may be concerns about churn, but some of these cleanups are really quite nice so please don't dismiss the series wholesale for that reason. Ard Biesheuvel (15): ARM: assembler: introduce adr_l, ldr_l and str_l macros ARM: head-common.S: use PC-relative insn

[PATCH 01/15] ARM: assembler: introduce adr_l, ldr_l and str_l macros

2017-08-05 Thread Ard Biesheuvel
rs on v7 and later CPUs, and use PC-relative literals otherwise. Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- arch/arm/include/asm/assembler.h | 70 1 file changed, 70 insertions(+) diff --git a/arch/arm/include/asm/assembler.h b/arch/arm/include/a