* elf64-mips.c (elf_backend_got_header_size): Correct definition.
authorMaciej W. Rozycki <macro@linux-mips.org>
Sat, 19 May 2012 19:30:45 +0000 (19:30 +0000)
committerMaciej W. Rozycki <macro@linux-mips.org>
Sat, 19 May 2012 19:30:45 +0000 (19:30 +0000)
* elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Use the ELF
backend's GOT header size instead of hardcoding it.

bfd/ChangeLog
bfd/elf64-mips.c
bfd/elfxx-mips.c

index a3daca5f0078763188200d90efe8efda933dd848..efa6cb7b4c4d9d3789da08bc156f00b40af6e54c 100644 (file)
@@ -1,3 +1,9 @@
+2012-05-19  Maciej W. Rozycki  <macro@linux-mips.org>
+
+       * elf64-mips.c (elf_backend_got_header_size): Correct definition.
+       * elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Use the ELF
+       backend's GOT header size instead of hardcoding it.
+
 2012-05-19  Maciej W. Rozycki  <macro@linux-mips.org>
 
        * elf32-vax.c (elf_vax_relocate_section)
index 054b262dc4edfa76ab8bc93bbda3765f0a0f4863..e02f969ed86015fb81da6e751c077cf60c20b480 100644 (file)
@@ -4126,7 +4126,7 @@ const struct elf_size_info mips_elf64_size_info =
 #define elf_backend_grok_prstatus      elf64_mips_grok_prstatus
 #define elf_backend_grok_psinfo                elf64_mips_grok_psinfo
 
-#define elf_backend_got_header_size    (4 * MIPS_RESERVED_GOTNO)
+#define elf_backend_got_header_size    (8 * MIPS_RESERVED_GOTNO)
 
 /* MIPS ELF64 can use a mixture of REL and RELA, but some Relocations
    work better/work only in RELA, so we default to this.  */
index 6dd0592917dbfd67c7d52c4ac805d8d168cb6202..9b4ccbf95da547e9bfbd9167bca5d02859014715 100644 (file)
@@ -8665,7 +8665,8 @@ _bfd_mips_elf_adjust_dynamic_symbol (struct bfd_link_info *info,
          /* On non-VxWorks targets, the first two entries in .got.plt
             are reserved.  */
          if (!htab->is_vxworks)
-           htab->sgotplt->size += 2 * MIPS_ELF_GOT_SIZE (dynobj);
+           htab->sgotplt->size
+             += get_elf_backend_data (dynobj)->got_header_size;
 
          /* On VxWorks, also allocate room for the header's
             .rela.plt.unloaded entries.  */
This page took 0.03855 seconds and 4 git commands to generate.