[patch] R_ARM_PLT32 inconsistency.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[patch] R_ARM_PLT32 inconsistency.

Paul Brook
Binutils now treats R_ARM_PLT32 the same as R_ARM_PC24, with on exception: The
howto entry for the former still has partial_inplace set to true. Generation
of R_ARM_PLT32 relocations seems to have been broken since this patch:

2005-06-30  Zack Weinberg  <[hidden email]>
       (do_branch): Always set inst.reloc.pc_rel.

The attached patch changes the R_ARM_PLT32 to match the R_ARM_PC24 entry.

Tested on arm-none-linux-gnueabi.
Ok?

Paul

2005-08-13  Paul Brook  <[hidden email]>

        * elf3-arm.c (elf32_arm_howto_table_1): Make R_ARM_PLT32 the same as
        R_ARM_PC24.

Index: bfd/elf32-arm.c
===================================================================
RCS file: /var/cvsroot/src-cvs/src/bfd/elf32-arm.c,v
retrieving revision 1.51
diff -u -p -r1.51 elf32-arm.c
--- bfd/elf32-arm.c 8 Aug 2005 11:06:16 -0000 1.51
+++ bfd/elf32-arm.c 13 Aug 2005 14:27:05 -0000
@@ -435,13 +435,13 @@ static reloc_howto_type elf32_arm_howto_
   HOWTO (R_ARM_PLT32, /* type */
          2,                     /* rightshift */
          2,                     /* size (0 = byte, 1 = short, 2 = long) */
-         26,                    /* bitsize */
+         24,                    /* bitsize */
          TRUE, /* pc_relative */
          0,                     /* bitpos */
          complain_overflow_bitfield,/* complain_on_overflow */
          bfd_elf_generic_reloc, /* special_function */
          "R_ARM_PLT32", /* name */
-         TRUE, /* partial_inplace */
+         FALSE, /* partial_inplace */
          0x00ffffff, /* src_mask */
          0x00ffffff, /* dst_mask */
          TRUE), /* pcrel_offset */
Reply | Threaded
Open this post in threaded view
|

Re: [patch] R_ARM_PLT32 inconsistency.

Richard Earnshaw-2
On Sat, 2005-08-13 at 15:54, Paul Brook wrote:

> Binutils now treats R_ARM_PLT32 the same as R_ARM_PC24, with on exception: The
> howto entry for the former still has partial_inplace set to true. Generation
> of R_ARM_PLT32 relocations seems to have been broken since this patch:
>
> 2005-06-30  Zack Weinberg  <[hidden email]>
>        (do_branch): Always set inst.reloc.pc_rel.
>
> The attached patch changes the R_ARM_PLT32 to match the R_ARM_PC24 entry.
>
> Tested on arm-none-linux-gnueabi.
> Ok?
>
> Paul
>
> 2005-08-13  Paul Brook  <[hidden email]>
>
> * elf3-arm.c (elf32_arm_howto_table_1): Make R_ARM_PLT32 the same as
> R_ARM_PC24.

OK.

R.