[PATCH v2 3/3] arm64: remove __lookup_processor_type_data object from head.S
Catalin Marinas
catalin.marinas at arm.com
Wed Mar 4 10:09:55 PST 2015
On Wed, Mar 04, 2015 at 12:23:17PM +0100, Ard Biesheuvel wrote:
> This removes __lookup_processor_type_data, replacing the original
> use with a simple PC-relative address load.
>
> Signed-off-by: Ard Biesheuvel <ard.biesheuvel at linaro.org>
Reviewed-by: Catalin Marinas <catalin.marinas at arm.com>
> ENTRY(lookup_processor_type)
> - adr x1, __lookup_processor_type_data
> - ldp x2, x3, [x1]
> - sub x1, x1, x2 // get offset between VA and PA
> - add x3, x3, x1 // convert VA to PA
> + adrp x3, cpu_table
> + add x3, x3, :lo12:cpu_table
I wonder whether we should add a macro for these two instructions, it's
becoming a common pattern.
--
Catalin
More information about the linux-arm-kernel
mailing list