aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-mips.c
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>1998-01-31 00:11:34 +0000
committerDoug Evans <dje@google.com>1998-01-31 00:11:34 +0000
commitc62a82b5a0ce709b757df2e5b1f2efa6b404c77a (patch)
tree20318c29ce3ad557850691d14482083ed97e0731 /bfd/elf32-mips.c
parent8a5863beeb2c3e3040a1d0aeed57bb7a2eaae157 (diff)
downloadgdb-c62a82b5a0ce709b757df2e5b1f2efa6b404c77a.zip
gdb-c62a82b5a0ce709b757df2e5b1f2efa6b404c77a.tar.gz
gdb-c62a82b5a0ce709b757df2e5b1f2efa6b404c77a.tar.bz2
* elf32-mips.c (elf_mips_dvp_11_pcrel_howto): Set pcrel_offset=true.
(mips_elf_relocate_section): Recognize R_MIPS_DVP_11_PCREL.
Diffstat (limited to 'bfd/elf32-mips.c')
-rw-r--r--bfd/elf32-mips.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/bfd/elf32-mips.c b/bfd/elf32-mips.c
index 5acc462..eba42c0 100644
--- a/bfd/elf32-mips.c
+++ b/bfd/elf32-mips.c
@@ -772,7 +772,7 @@ static reloc_howto_type elf_mips_dvp_11_pcrel_howto =
true, /* partial_inplace */
0x7ff, /* src_mask */
0x7ff, /* dst_mask */
- false); /* pcrel_offset */
+ true); /* pcrel_offset */
/* end-sanitize-sky */
/* Do a R_MIPS_HI16 relocation. This has to be done in combination
@@ -4629,6 +4629,9 @@ mips_elf_relocate_section (output_bfd, info, input_bfd, input_section,
r_type = ELF32_R_TYPE (rel->r_info);
if ((r_type < 0 || r_type >= (int) R_MIPS_max)
+/* start-sanitize-sky */
+ && r_type != R_MIPS_DVP_11_PCREL
+/* end-sanitize-sky */
&& r_type != R_MIPS16_26
&& r_type != R_MIPS16_GPREL)
{
@@ -4639,6 +4642,10 @@ mips_elf_relocate_section (output_bfd, info, input_bfd, input_section,
howto = &elf_mips16_jump_howto;
else if (r_type == R_MIPS16_GPREL)
howto = &elf_mips16_gprel_howto;
+/* start-sanitize-sky */
+ else if (r_type == R_MIPS_DVP_11_PCREL)
+ howto = &elf_mips_dvp_11_pcrel_howto;
+/* end-sanitize-sky */
else
howto = elf_mips_howto_table + r_type;