[PATCH 1/8] ARM: assembler: introduce adr_l, ldr_l and str_l macros
Dave Martin
Dave.Martin at arm.com
Thu Aug 4 04:30:19 PDT 2016
On Thu, Aug 04, 2016 at 01:10:55PM +0200, Ard Biesheuvel wrote:
> On 4 August 2016 at 13:08, Dave Martin <Dave.Martin at arm.com> wrote:
[...]
> > or, for ldr_l:
> >
> > 0: add \dst, pc, #-8
> > 1: add \dst, \dst, #-4
> > 2: ldr [\dst, #0]
> >
> > .reloc 0b, R_ARM_ALU_PC_G0_NC, \sym
> > .reloc 1b, R_ARM_ALU_PC_G1_NC, \sym
> > .reloc 2b, R_ARM_LDR_PC_G2, \sym
> >
> > ... should produce precisely the same result at the .o stage.
> >
>
> Yes, but how is LD going to perform the arithmetic involved in
What arithmetic?
> handling these relocations? That's is the more interesting part, and
> that is not implemented either in binutils < 2.18
You mean .reloc is not implemented < 2.18?
[...]
Cheers
---Dave
More information about the linux-arm-kernel
mailing list