From: Jan Kiszka <jan.kiszka@web.de>
To: Anthony Liguori <anthony@codemonkey.ws>
Cc: Jes Sorensen <jes@sgi.com>, Avi Kivity <avi@redhat.com>,
qemu-devel <qemu-devel@nongnu.org>
Subject: [Qemu-devel] [PATCH] Drop CONFIG_GDBSTUB
Date: Fri, 08 May 2009 09:01:00 +0200 [thread overview]
Message-ID: <4A03D8AC.8030901@web.de> (raw)
[-- Attachment #1: Type: text/plain, Size: 6258 bytes --]
This is no user-flippable switch, and no arch makes use of disabling
gdbstub support. So it's pointless to keep the related #ifdefs and
configure hunks around - and risking breakages like 711c410fdd again.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
Makefile.target | 26 +++++++-------------------
configure | 5 -----
monitor.c | 4 ----
vl.c | 8 --------
4 files changed, 7 insertions(+), 36 deletions(-)
diff --git a/Makefile.target b/Makefile.target
index f735105..fe83837 100644
--- a/Makefile.target
+++ b/Makefile.target
@@ -317,7 +317,7 @@ CFLAGS+=-p
endif
OBJS= main.o syscall.o strace.o mmap.o signal.o path.o thunk.o \
- elfload.o linuxload.o uaccess.o envlist.o
+ elfload.o linuxload.o uaccess.o envlist.o gdbstub.o gdbstub-xml.o
LIBS+= $(PTHREADLIBS)
LIBS+= $(CLOCKLIBS)
ifdef TARGET_HAS_BFLT
@@ -340,10 +340,6 @@ ifeq ($(TARGET_ARCH), m68k)
OBJS+= m68k-sim.o m68k-semi.o
endif
-ifdef CONFIG_GDBSTUB
-OBJS+=gdbstub.o gdbstub-xml.o
-endif
-
OBJS+= libqemu.a
# Note: this is a workaround. The real fix is to avoid compiling
@@ -373,14 +369,11 @@ LDFLAGS+=-Wl,-segaddr,__STD_PROG_ZONE,0x1000 -image_base 0x0e000000
LIBS+=-lmx
-OBJS= main.o commpage.o machload.o mmap.o signal.o syscall.o thunk.o
+OBJS= main.o commpage.o machload.o mmap.o signal.o syscall.o thunk.o \
+ gdbstub.o gdbstub-xml.o
OBJS+= libqemu.a
-ifdef CONFIG_GDBSTUB
-OBJS+=gdbstub.o gdbstub-xml.o
-endif
-
# Note: this is a workaround. The real fix is to avoid compiling
# cpu_signal_handler() in cpu-exec.c.
signal.o: CFLAGS += $(HELPER_CFLAGS)
@@ -476,15 +469,12 @@ LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH)el.ld
endif
endif
-OBJS= main.o bsdload.o elfload.o mmap.o path.o signal.o strace.o syscall.o
+OBJS= main.o bsdload.o elfload.o mmap.o path.o signal.o strace.o syscall.o \
+ gdbstub.o gdbstub-xml.o
OBJS+= uaccess.o
OBJS+= libqemu.a
-ifdef CONFIG_GDBSTUB
-OBJS+=gdbstub.o
-endif
-
# Note: this is a workaround. The real fix is to avoid compiling
# cpu_signal_handler() in cpu-exec.c.
signal.o: CFLAGS += $(HELPER_CFLAGS)
@@ -498,7 +488,8 @@ endif #CONFIG_BSD_USER
# System emulator target
ifndef CONFIG_USER_ONLY
-OBJS=vl.o osdep.o monitor.o pci.o loader.o isa_mmio.o machine.o dma-helpers.o
+OBJS=vl.o osdep.o monitor.o pci.o loader.o isa_mmio.o machine.o dma-helpers.o \
+ gdbstub.o gdbstub-xml.o
# virtio has to be here due to weird dependency between PCI and virtio-net.
# need to fix this properly
OBJS+=virtio.o virtio-blk.o virtio-balloon.o virtio-net.o virtio-console.o
@@ -686,9 +677,6 @@ ifeq ($(TARGET_BASE_ARCH), m68k)
OBJS+= an5206.o mcf5206.o mcf_uart.o mcf_intc.o mcf5208.o mcf_fec.o
OBJS+= m68k-semi.o dummy_m68k.o
endif
-ifdef CONFIG_GDBSTUB
-OBJS+=gdbstub.o gdbstub-xml.o
-endif
ifdef CONFIG_COCOA
COCOA_LIBS=-F/System/Library/Frameworks -framework Cocoa -framework IOKit
ifdef CONFIG_COREAUDIO
diff --git a/configure b/configure
index 82fb60a..b2a2540 100755
--- a/configure
+++ b/configure
@@ -159,7 +159,6 @@ strip_opt="yes"
bigendian="no"
mingw32="no"
EXESUF=""
-gdbstub="yes"
slirp="yes"
vde="yes"
fmod_lib=""
@@ -1526,10 +1525,6 @@ if test -n "$sparc_cpu"; then
echo "CONFIG__sparc_${sparc_cpu}__=yes" >> $config_mak
echo "#define __sparc_${sparc_cpu}__ 1" >> $config_h
fi
-if test "$gdbstub" = "yes" ; then
- echo "CONFIG_GDBSTUB=yes" >> $config_mak
- echo "#define CONFIG_GDBSTUB 1" >> $config_h
-fi
if test "$gprof" = "yes" ; then
echo "TARGET_GPROF=yes" >> $config_mak
echo "#define HAVE_GPROF 1" >> $config_h
diff --git a/monitor.c b/monitor.c
index d64f459..0f38c71 100644
--- a/monitor.c
+++ b/monitor.c
@@ -581,7 +581,6 @@ static void encrypted_bdrv_it(void *opaque, BlockDriverState *bs)
}
}
-#ifdef CONFIG_GDBSTUB
static void do_gdbserver(Monitor *mon, const char *device)
{
if (!device)
@@ -596,7 +595,6 @@ static void do_gdbserver(Monitor *mon, const char *device)
device);
}
}
-#endif
static void do_watchdog_action(Monitor *mon, const char *action)
{
@@ -1692,10 +1690,8 @@ static const mon_cmd_t mon_cmds[] = {
"", "stop emulation", },
{ "c|cont", "", do_cont,
"", "resume emulation", },
-#ifdef CONFIG_GDBSTUB
{ "gdbserver", "s?", do_gdbserver,
"[device]", "start gdbserver on given device (default 'tcp::1234'), stop with 'none'", },
-#endif
{ "x", "/l", do_memory_dump,
"/fmt addr", "virtual memory dump starting at 'addr'", },
{ "xp", "/l", do_physical_memory_dump,
diff --git a/vl.c b/vl.c
index 867111c..846d798 100644
--- a/vl.c
+++ b/vl.c
@@ -4350,13 +4350,11 @@ static void tcg_cpu_exec(void)
}
if (cpu_can_run(env))
ret = qemu_cpu_exec(env);
-#ifndef CONFIG_GDBSTUB
if (ret == EXCP_DEBUG) {
gdb_set_stop_cpu(env);
debug_requested = 1;
break;
}
-#endif
}
}
@@ -4795,9 +4793,7 @@ static void termsig_setup(void)
int main(int argc, char **argv, char **envp)
{
-#ifdef CONFIG_GDBSTUB
const char *gdbstub_dev = NULL;
-#endif
uint32_t boot_devices_bitmap = 0;
int i;
int snapshot, linux_boot, net_boot;
@@ -5229,14 +5225,12 @@ int main(int argc, char **argv, char **envp)
cpu_set_log(mask);
}
break;
-#ifdef CONFIG_GDBSTUB
case QEMU_OPTION_s:
gdbstub_dev = "tcp::" DEFAULT_GDBSTUB_PORT;
break;
case QEMU_OPTION_gdb:
gdbstub_dev = optarg;
break;
-#endif
case QEMU_OPTION_L:
bios_dir = optarg;
break;
@@ -6023,13 +6017,11 @@ int main(int argc, char **argv, char **envp)
}
}
-#ifdef CONFIG_GDBSTUB
if (gdbstub_dev && gdbserver_start(gdbstub_dev) < 0) {
fprintf(stderr, "qemu: could not open gdbserver on device '%s'\n",
gdbstub_dev);
exit(1);
}
-#endif
if (loadvm)
do_loadvm(cur_mon, loadvm);
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 257 bytes --]
reply other threads:[~2009-05-08 7:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4A03D8AC.8030901@web.de \
--to=jan.kiszka@web.de \
--cc=anthony@codemonkey.ws \
--cc=avi@redhat.com \
--cc=jes@sgi.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.