diff options
author | Antonio Borneo <borneo.antonio@gmail.com> | 2018-11-01 14:50:27 +0100 |
---|---|---|
committer | Tomas Vanek <vanekt@fbl.cz> | 2019-01-08 09:59:42 +0000 |
commit | 5c941edc7b0d6e0bed596293d81867453d1462e9 (patch) | |
tree | ac90173d565b70969cf7dabbd142c82d0899b97e /src/target/cortex_m.c | |
parent | 97afb8b37229d6a140aaa81a3c71122e5d862296 (diff) |
target/arm: add support for multi-architecture gdb
GDB can be built for multi-architecture through the command
./configure --enable-targets=all && make
Such multi-architecture GDB requires the target's architecture to
be selected either manually by the user through the GDB command
"set architecture" or automatically by the target description sent
by the remote target (i.e. OpenOCD).
Commit e65acd889c61a424c7bd72fdee5d6a3aee1d8504 ("gdb_server: add
support for architecture element") already provides the required
infrastructure to support multi-architecture gdb.
arm-none-eabi-gdb 8.2 uses "arm" as default architecture, but also
supports the following values: "arm_any", "armv2", "armv2a",
"armv3", "armv3m", "armv4", "armv4t", "armv5", "armv5t", "armv5te",
"armv5tej", "armv6", "armv6k", "armv6kz", "armv6-m", "armv6s-m",
"armv6t2", "armv7", "armv7e-m", "armv8-a", "armv8-m.base",
"armv8-m.main", "armv8-r", "ep9312", "iwmmxt", "iwmmxt2", "xscale".
These values can be displayed on arm gdb prompt by typing
"set architecture " followed by a TAB for autocompletion.
Set the gdb architecture value for all arm targets to "arm".
Change-Id: I176cb89878606e1febd546ce26543b3e7849500a
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/4754
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Diffstat (limited to 'src/target/cortex_m.c')
-rw-r--r-- | src/target/cortex_m.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/target/cortex_m.c b/src/target/cortex_m.c index 4ce776cd..e8ad770e 100644 --- a/src/target/cortex_m.c +++ b/src/target/cortex_m.c @@ -2518,6 +2518,7 @@ struct target_type cortexm_target = { .deassert_reset = cortex_m_deassert_reset, .soft_reset_halt = cortex_m_soft_reset_halt, + .get_gdb_arch = arm_get_gdb_arch, .get_gdb_reg_list = armv7m_get_gdb_reg_list, .read_memory = cortex_m_read_memory, |