[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v3 11/12] gdbstub: Remove gdb_has_xml variable
From: |
Akihiko Odaki |
Subject: |
[PATCH v3 11/12] gdbstub: Remove gdb_has_xml variable |
Date: |
Wed, 13 Sep 2023 07:41:00 +0900 |
GDB has XML support since 6.7 which was released in 2007.
It's time to remove support for old GDB versions without XML support.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
---
gdbstub/internals.h | 2 --
include/exec/gdbstub.h | 8 --------
gdbstub/gdbstub.c | 15 ---------------
3 files changed, 25 deletions(-)
diff --git a/gdbstub/internals.h b/gdbstub/internals.h
index fee243081f..7128c4aa85 100644
--- a/gdbstub/internals.h
+++ b/gdbstub/internals.h
@@ -32,8 +32,6 @@ enum {
typedef struct GDBProcess {
uint32_t pid;
bool attached;
-
- /* If gdb sends qXfer:features:read:target.xml this will be populated */
char *target_xml;
} GDBProcess;
diff --git a/include/exec/gdbstub.h b/include/exec/gdbstub.h
index 705be2c5d7..1a01c35f8e 100644
--- a/include/exec/gdbstub.h
+++ b/include/exec/gdbstub.h
@@ -45,14 +45,6 @@ int gdbserver_start(const char *port_or_device);
void gdb_set_stop_cpu(CPUState *cpu);
-/**
- * gdb_has_xml() - report of gdb supports modern target descriptions
- *
- * This will report true if the gdb negotiated qXfer:features:read
- * target descriptions.
- */
-bool gdb_has_xml(void);
-
/* in gdbstub-xml.c, generated by scripts/feature_to_c.py */
extern const GDBFeature gdb_static_features[];
diff --git a/gdbstub/gdbstub.c b/gdbstub/gdbstub.c
index a4f2bf3723..177dce9ba2 100644
--- a/gdbstub/gdbstub.c
+++ b/gdbstub/gdbstub.c
@@ -349,11 +349,6 @@ static CPUState *gdb_get_cpu(uint32_t pid, uint32_t tid)
}
}
-bool gdb_has_xml(void)
-{
- return !!gdb_get_cpu_process(gdbserver_state.g_cpu)->target_xml;
-}
-
static const char *get_feature_xml(const char *p, const char **newp,
GDBProcess *process)
{
@@ -1086,11 +1081,6 @@ static void handle_set_reg(GArray *params, void
*user_ctx)
{
int reg_size;
- if (!gdb_get_cpu_process(gdbserver_state.g_cpu)->target_xml) {
- gdb_put_packet("");
- return;
- }
-
if (params->len != 2) {
gdb_put_packet("E22");
return;
@@ -1107,11 +1097,6 @@ static void handle_get_reg(GArray *params, void
*user_ctx)
{
int reg_size;
- if (!gdb_get_cpu_process(gdbserver_state.g_cpu)->target_xml) {
- gdb_put_packet("");
- return;
- }
-
if (!params->len) {
gdb_put_packet("E14");
return;
--
2.42.0
- [PATCH v3 03/12] plugins: Check if vCPU is realized, (continued)
- [PATCH v3 03/12] plugins: Check if vCPU is realized, Akihiko Odaki, 2023/09/12
- [PATCH v3 04/12] contrib/plugins: Use GRWLock in execlog, Akihiko Odaki, 2023/09/12
- [PATCH v3 05/12] gdbstub: Introduce GDBFeature structure, Akihiko Odaki, 2023/09/12
- [PATCH v3 06/12] target/arm: Move the reference to arm-core.xml, Akihiko Odaki, 2023/09/12
- [PATCH v3 07/12] hw/core/cpu: Return static value with gdb_arch_name(), Akihiko Odaki, 2023/09/12
- [PATCH v3 08/12] gdbstub: Use g_markup_printf_escaped(), Akihiko Odaki, 2023/09/12
- [PATCH v3 09/12] target/arm: Remove references to gdb_has_xml, Akihiko Odaki, 2023/09/12
- [PATCH v3 10/12] target/ppc: Remove references to gdb_has_xml, Akihiko Odaki, 2023/09/12
- [PATCH v3 11/12] gdbstub: Remove gdb_has_xml variable,
Akihiko Odaki <=
- [PATCH v3 12/12] gdbstub: Replace gdb_regs with an array, Akihiko Odaki, 2023/09/12
- Re: [PATCH v3 00/12] gdbstub and TCG plugin improvements, Alex Bennée, 2023/09/14