FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSIE_LD_GOTTPREL_PREL19, /* type */
- 0, /* rightshift */
+ 2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
21, /* bitsize */
FALSE, /* pc_relative */
FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSLE_MOVW_TPREL_G2, /* type */
- 8, /* rightshift */
+ 32, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
FALSE, /* pc_relative */
FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSLE_MOVW_TPREL_G1, /* type */
- 4, /* rightshift */
+ 16, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
FALSE, /* pc_relative */
FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSLE_MOVW_TPREL_G1_NC, /* type */
- 4, /* rightshift */
+ 16, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
FALSE, /* pc_relative */
FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSLE_ADD_TPREL_HI12, /* type */
- 3, /* rightshift */
+ 12, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
FALSE, /* pc_relative */
static reloc_howto_type elf64_aarch64_tlsdesc_howto_table[] =
{
HOWTO (R_AARCH64_TLSDESC_LD64_PREL19, /* type */
- 0, /* rightshift */
+ 2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
21, /* bitsize */
TRUE, /* pc_relative */
FALSE), /* pcrel_offset */
HOWTO (R_AARCH64_TLSDESC_OFF_G1, /* type */
- 4, /* rightshift */
+ 16, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
FALSE, /* pc_relative */
return NULL;
}
+/* Support for core dump NOTE sections. */
+
+static bfd_boolean
+elf64_aarch64_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
+{
+ int offset;
+ size_t size;
+
+ switch (note->descsz)
+ {
+ default:
+ return FALSE;
+
+ case 408: /* sizeof(struct elf_prstatus) on Linux/arm64. */
+ /* pr_cursig */
+ elf_tdata (abfd)->core_signal
+ = bfd_get_16 (abfd, note->descdata + 12);
+
+ /* pr_pid */
+ elf_tdata (abfd)->core_lwpid
+ = bfd_get_32 (abfd, note->descdata + 32);
+
+ /* pr_reg */
+ offset = 112;
+ size = 288;
+
+ break;
+ }
+
+ /* Make a ".reg/999" section. */
+ return _bfd_elfcore_make_pseudosection (abfd, ".reg",
+ size, note->descpos + offset);
+}
+
#define TARGET_LITTLE_SYM bfd_elf64_littleaarch64_vec
#define TARGET_LITTLE_NAME "elf64-littleaarch64"
#define TARGET_BIG_SYM bfd_elf64_bigaarch64_vec
#define TARGET_BIG_NAME "elf64-bigaarch64"
+#define elf_backend_grok_prstatus elf64_aarch64_grok_prstatus
+
typedef unsigned long int insn32;
/* The linker script knows the section names for placement.
case R_AARCH64_TLSLE_MOVW_TPREL_G1_NC:
case R_AARCH64_TLSLE_MOVW_TPREL_G2:
value = aarch64_resolve_relocation (r_type, place, value,
- - tpoff_base (info), weak_undef_p);
+ signed_addend - tpoff_base (info), weak_undef_p);
*unresolved_reloc_p = FALSE;
break;