diff options
author | Rich Felker <dalias@aerifal.cx> | 2012-10-15 21:01:48 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2012-10-15 21:01:48 -0400 |
commit | 21284ec75db064d3f27fcd1d6ae37b613db61c43 (patch) | |
tree | fef641e851c42e43f5cca5d482b3b7b08377e7e9 | |
parent | 9ec4283b28cf676292fd5c6f681bef1e90e30c18 (diff) | |
download | musl-21284ec75db064d3f27fcd1d6ae37b613db61c43.tar.gz musl-21284ec75db064d3f27fcd1d6ae37b613db61c43.tar.bz2 musl-21284ec75db064d3f27fcd1d6ae37b613db61c43.tar.xz musl-21284ec75db064d3f27fcd1d6ae37b613db61c43.zip |
microblaze TLS relocation support, completely untested
-rw-r--r-- | arch/microblaze/reloc.h | 6 | ||||
-rw-r--r-- | include/elf.h | 9 |
2 files changed, 14 insertions, 1 deletions
diff --git a/arch/microblaze/reloc.h b/arch/microblaze/reloc.h index 67cb3c2e..81add5e9 100644 --- a/arch/microblaze/reloc.h +++ b/arch/microblaze/reloc.h @@ -24,6 +24,12 @@ static inline void do_single_reloc( case R_MICROBLAZE_COPY: memcpy(reloc_addr, (void *)sym_val, sym_size); break; + case R_MICROBLAZE_TLSDTPMOD32: + *reloc_addr = def.dso ? def.dso->tls_id : self->tls_id; + break; + case R_MICROBLAZE_TLSDTPREL32: + *reloc_addr = def.sym->st_value + addend; + break; } } diff --git a/include/elf.h b/include/elf.h index 079f47ce..0075f9fc 100644 --- a/include/elf.h +++ b/include/elf.h @@ -2538,7 +2538,14 @@ typedef Elf32_Addr Elf32_Conflict; #define R_MICROBLAZE_GOTOFF_64 19 #define R_MICROBLAZE_GOTOFF_32 20 #define R_MICROBLAZE_COPY 21 -#define R_MICROBLAZE_NUM 22 +#define R_MICROBLAZE_TLS 22 +#define R_MICROBLAZE_TLSGD 23 +#define R_MICROBLAZE_TLSLD 24 +#define R_MICROBLAZE_TLSDTPMOD32 25 +#define R_MICROBLAZE_TLSDTPREL32 26 +#define R_MICROBLAZE_TLSDTPREL64 27 +#define R_MICROBLAZE_TLSGOTTPREL32 28 +#define R_MICROBLAZE_TLSTPREL32 29 #ifdef __cplusplus } |