aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf64-mips.c
diff options
context:
space:
mode:
authorStan Cox <scox@redhat.com>2002-09-18 01:38:20 +0000
committerStan Cox <scox@redhat.com>2002-09-18 01:38:20 +0000
commita902ee94b7b0212607630a2c0920565f01899051 (patch)
treec44eaf1ffede5a8c9d90be1f791ee0b9661b5ca3 /bfd/elf64-mips.c
parent419586656da32a0ea553d34a9bed51037a22993a (diff)
downloadgdb-a902ee94b7b0212607630a2c0920565f01899051.zip
gdb-a902ee94b7b0212607630a2c0920565f01899051.tar.gz
gdb-a902ee94b7b0212607630a2c0920565f01899051.tar.bz2
* elf64-mips.c (mips_elf64_be_swap_reloca_out): Handle type2 and type3.
(mips_elf64_final_gp): Don't make up gp value. * elfn32-mips.c (mips_elf_final_gp): Likewise. * elfxx-mips.c (_bfd_mips_elf_final_link): Always create .MIPS.options/.options section.
Diffstat (limited to 'bfd/elf64-mips.c')
-rw-r--r--bfd/elf64-mips.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/bfd/elf64-mips.c b/bfd/elf64-mips.c
index 95abaff..cc7ec40 100644
--- a/bfd/elf64-mips.c
+++ b/bfd/elf64-mips.c
@@ -1337,13 +1337,15 @@ mips_elf64_be_swap_reloc_out (abfd, src, dst)
mirel.r_offset = src[0].r_offset;
BFD_ASSERT(src[0].r_offset == src[1].r_offset);
+#if 0
BFD_ASSERT(src[0].r_offset == src[2].r_offset);
+#endif
mirel.r_type = ELF64_MIPS_R_TYPE (src[0].r_info);
mirel.r_sym = ELF64_R_SYM (src[0].r_info);
- mirel.r_type2 = ELF64_MIPS_R_TYPE2 (src[1].r_info);
+ mirel.r_type2 = ELF64_MIPS_R_TYPE (src[1].r_info);
mirel.r_ssym = ELF64_MIPS_R_SSYM (src[1].r_info);
- mirel.r_type3 = ELF64_MIPS_R_TYPE3 (src[2].r_info);
+ mirel.r_type3 = ELF64_MIPS_R_TYPE (src[2].r_info);
mips_elf64_swap_reloc_out (abfd, &mirel,
(Elf64_Mips_External_Rel *) dst);
@@ -1525,7 +1527,7 @@ mips_elf64_final_gp (output_bfd, symbol, relocateable, error_message, pgp)
if (relocateable)
{
/* Make up a value. */
- *pgp = symbol->section->output_section->vma + 0x4000;
+ *pgp = symbol->section->output_section->vma /*+ 0x4000*/;
_bfd_set_gp_value (output_bfd, *pgp);
}
else if (!mips_elf64_assign_gp (output_bfd, pgp))