This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
frv label16 relocation mis-applied
- From: Alexandre Oliva <aoliva at redhat dot com>
- To: binutils at sources dot redhat dot com
- Date: 07 Oct 2003 16:17:03 -0300
- Subject: frv label16 relocation mis-applied
- Organization: GCC Team, Red Hat
When the linker applies a label16 relocation, it fails to right-shift
the relocation by 2 bits, as required. I'm installing this fix, as
obvious.
Index: bfd/ChangeLog
from Alexandre Oliva <aoliva@redhat.com>
* elf32-frv.c (elf32_frv_howto_table): Set R_FRV_LABEL16's
rightshift to 2.
Index: bfd/elf32-frv.c
===================================================================
RCS file: /cvs/src/src/bfd/elf32-frv.c,v
retrieving revision 1.7
diff -u -p -r1.7 elf32-frv.c
--- bfd/elf32-frv.c 27 Aug 2003 09:21:15 -0000 1.7
+++ bfd/elf32-frv.c 7 Oct 2003 19:16:53 -0000
@@ -111,7 +111,7 @@ static reloc_howto_type elf32_frv_howto_
/* A 16 bit pc-relative relocation. */
HOWTO (R_FRV_LABEL16, /* type */
- 0, /* rightshift */
+ 2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
TRUE, /* pc_relative */
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer