Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChung-Lin Tang <cltang@codesourcery.com>2011-12-19 14:49:27 +0400
committerChung-Lin Tang <cltang@codesourcery.com>2011-12-19 14:49:27 +0400
commitffa40dedcdc1282db014fe9148fa7f7cf000cf63 (patch)
treeb0d084095ab8d0f38edd46470e2f6085b018fa47
parent5d8c5143954241dc696cedb38425806dd0657863 (diff)
2011-12-19 Chung-Lin Tang <cltang@codesourcery.com>binutils-2_22-branch
Backport from mainline: 2011-12-19 Chung-Lin Tang <cltang@codesourcery.com> gas/ * config/tc-mips.c (mips_pseudo_table): Add tprelword/tpreldword entries. (mips16_percent_op): Add MIPS16 TLS relocation ops. (md_apply_fix): Add BFD_RELOC_MIPS16_TLS_* switch cases. (s_tls_rel_directive): Rename from s_dtprel_internal(). Abstract out directive string and reloc type as function parameters. Update comments. (s_dtprelword,s_dtpreldword): Change to use s_tls_rel_directive(). (s_tprelword,s_tpreldword): New functions. include/ * elf/mips.h (elf_mips_reloc_type): Add R_MIPS16_TLS_* entries. bfd/ * reloc.c (BFD_RELOC_MIPS16_TLS_GD,BFD_RELOC_MIPS16_TLS_LDM, BFD_RELOC_MIPS16_TLS_DTPREL_HI16,BFD_RELOC_MIPS16_TLS_DTPREL_LO16, BFD_RELOC_MIPS16_TLS_GOTTPREL,BFD_RELOC_MIPS16_TLS_TPREL_HI16, BFD_RELOC_MIPS16_TLS_TPREL_LO16): New relocations for MIPS16 TLS. * bfd-in2.h (bfd_reloc_code_real): Regenerate. * libbfd.h (bfd_reloc_code_real_names): Regenerate. * elf32-mips.c (elf_mips16_howto_table_rel): Add R_MIPS16_TLS_* entries. (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_* mappings. * elfn32-mips.c (elf_mips16_howto_table_rel, elf_mips16_howto_table_rela): Add R_MIPS16_TLS_* entries. (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_* mappings. * elf64-mips.c (mips16_elf64_howto_table_rel, mips16_elf64_howto_table_rela): Add R_MIPS16_TLS_* entries. (mips16_reloc_map): Add BFD_RELOC_MIPS16_TLS_* to R_MIPS16_TLS_* mappings. * elfxx-mips.c (TLS_RELOC_P,mips16_reloc_p, _bfd_mips_elf_check_relocs): Add cases for R_MIPS16_TLS_* relocations. (tls_gd_reloc_p): Add R_MIPS16_TLS_GD case. (tls_ldm_reloc_p): Add R_MIPS16_TLS_LDM case. (tls_gottprel_reloc_p): Add R_MIPS16_TLS_GOTTPREL case. (mips_elf_calculate_relocation): Add cases for R_MIPS16_TLS_*, R_MIPS_TLS_DTPREL32/64, and R_MIPS_TLS_TPREL32/64 relocations.
-rw-r--r--include/ChangeLog8
-rw-r--r--include/elf/mips.h9
2 files changed, 16 insertions, 1 deletions
diff --git a/include/ChangeLog b/include/ChangeLog
index af969774f..e32f0f9e8 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,11 @@
+2011-12-19 Chung-Lin Tang <cltang@codesourcery.com>
+
+ Backport from mainline:
+
+ 2011-12-19 Chung-Lin Tang <cltang@codesourcery.com>
+
+ * elf/mips.h (elf_mips_reloc_type): Add R_MIPS16_TLS_* entries.
+
2011-10-25 Alan Modra <amodra@gmail.com>
Apply mainline patches.
diff --git a/include/elf/mips.h b/include/elf/mips.h
index db5fa5414..c2c5922dd 100644
--- a/include/elf/mips.h
+++ b/include/elf/mips.h
@@ -98,7 +98,14 @@ START_RELOC_NUMBERS (elf_mips_reloc_type)
RELOC_NUMBER (R_MIPS16_CALL16, 103)
RELOC_NUMBER (R_MIPS16_HI16, 104)
RELOC_NUMBER (R_MIPS16_LO16, 105)
- FAKE_RELOC (R_MIPS16_max, 106)
+ RELOC_NUMBER (R_MIPS16_TLS_GD, 106)
+ RELOC_NUMBER (R_MIPS16_TLS_LDM, 107)
+ RELOC_NUMBER (R_MIPS16_TLS_DTPREL_HI16, 108)
+ RELOC_NUMBER (R_MIPS16_TLS_DTPREL_LO16, 109)
+ RELOC_NUMBER (R_MIPS16_TLS_GOTTPREL, 110)
+ RELOC_NUMBER (R_MIPS16_TLS_TPREL_HI16, 111)
+ RELOC_NUMBER (R_MIPS16_TLS_TPREL_LO16, 112)
+ FAKE_RELOC (R_MIPS16_max, 113)
/* These relocations are specific to VxWorks. */
RELOC_NUMBER (R_MIPS_COPY, 126)
RELOC_NUMBER (R_MIPS_JUMP_SLOT, 127)