diff options
author | Luis Machado <luis.machado@linaro.org> | 2020-06-15 13:59:40 -0300 |
---|---|---|
committer | Luis Machado <luis.machado@linaro.org> | 2021-03-24 14:52:57 -0300 |
commit | 5e984dbf3523ea86e3ef3750d6ecaeed74d87c87 (patch) | |
tree | f6415f72ff6a9c4aae4905a2ad94b70e48b201eb /include | |
parent | c1bd443b4d86e12f2a97856270e40df24c7f3df7 (diff) | |
download | gdb-5e984dbf3523ea86e3ef3750d6ecaeed74d87c87.zip gdb-5e984dbf3523ea86e3ef3750d6ecaeed74d87c87.tar.gz gdb-5e984dbf3523ea86e3ef3750d6ecaeed74d87c87.tar.bz2 |
AArch64: Add MTE register set support for GDB and gdbserver
AArch64 MTE support in the Linux kernel exposes a new register
through ptrace. This patch adds the required code to support it.
include/ChangeLog:
2021-03-24 Luis Machado <luis.machado@linaro.org>
* elf/common.h (NT_ARM_TAGGED_ADDR_CTRL): Define.
gdb/ChangeLog:
2021-03-24 Luis Machado <luis.machado@linaro.org>
* aarch64-linux-nat.c (fetch_mteregs_from_thread): New function.
(store_mteregs_to_thread): New function.
(aarch64_linux_nat_target::fetch_registers): Update to call
fetch_mteregs_from_thread.
(aarch64_linux_nat_target::store_registers): Update to call
store_mteregs_to_thread.
* aarch64-tdep.c (aarch64_mte_register_names): New struct.
(aarch64_cannot_store_register): Handle MTE registers.
(aarch64_gdbarch_init): Initialize and setup MTE registers.
* aarch64-tdep.h (gdbarch_tdep) <mte_reg_base>: New field.
<has_mte>: New method.
* arch/aarch64-linux.h (AARCH64_LINUX_SIZEOF_MTE): Define.
gdbserver/ChangeLog:
2021-03-24 Luis Machado <luis.machado@linaro.org>
* linux-aarch64-low.cc (aarch64_fill_mteregset): New function.
(aarch64_store_mteregset): New function.
(aarch64_regsets): Add MTE register set entry.
(aarch64_sve_regsets): Add MTE register set entry.
Diffstat (limited to 'include')
-rw-r--r-- | include/elf/common.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/elf/common.h b/include/elf/common.h index 241f2be..f36bb0b 100644 --- a/include/elf/common.h +++ b/include/elf/common.h @@ -672,6 +672,9 @@ /* note name must be "LINUX". */ #define NT_ARM_PAC_MASK 0x406 /* AArch pointer authentication code masks */ /* note name must be "LINUX". */ +#define NT_ARM_TAGGED_ADDR_CTRL 0x409 /* AArch64 tagged address control + (prctl()) */ + /* note name must be "LINUX". */ #define NT_ARC_V2 0x600 /* ARC HS accumulator/extra registers. */ /* note name must be "LINUX". */ #define NT_RISCV_CSR 0x900 /* RISC-V Control and Status Registers */ |