Skip to content

Commit

Permalink
x86: Remove gdbstub
Browse files Browse the repository at this point in the history
In 13y of working on Xen, I've never seen seen it used.  The implementation
was introduced (commit b69f92f, Jul 28 2004) with known issues such as:

  /* Resuming after we've stopped used to work, but more through luck
     than any actual intention.  It doesn't at the moment. */

which appear to have gone unfixed for the 20 years since.

Nowadays there are more robust ways of inspecting crashed state, such as a
kexec crash kernel, or running Xen in a VM.

This will allow us to clean up some hooks around the codebase which are
proving awkward for other tasks.

Signed-off-by: Andrew Cooper <[email protected]>
Acked-by: Jan Beulich <[email protected]>
  • Loading branch information
andyhhp committed Feb 1, 2024
1 parent 583f1d0 commit d182f9f
Show file tree
Hide file tree
Showing 10 changed files with 1 addition and 1,110 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- /usr/bin/pygrub symlink. This was deprecated in Xen 4.2 (2012) but left for
compatibility reasons. VMs configured with bootloader="/usr/bin/pygrub"
should be updated to just bootloader="pygrub".
- The Xen gdbstub on x86.

## [4.18.0](https://xenbits.xenproject.org/gitweb/?p=xen.git;a=shortlog;h=RELEASE-4.18.0) - 2023-11-16

Expand Down
7 changes: 0 additions & 7 deletions docs/misc/xen-command-line.pandoc
Original file line number Diff line number Diff line change
Expand Up @@ -1242,13 +1242,6 @@ requirement can be relaxed. This option is particularly useful for nested
virtualization, to allow the L1 hypervisor to use EPT even if the L0 hypervisor
does not provide `VM_ENTRY_LOAD_GUEST_PAT`.

### gdb
> `= com1[H,L] | com2[H,L] | dbgp`

> Default: ``

Specify which console gdbstub should use. See **console**.

### gnttab
> `= List of [ max-ver:<integer>, transitive=<bool>, transfer=<bool> ]`

Expand Down
7 changes: 0 additions & 7 deletions xen/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,6 @@ config DEBUG

if DEBUG || EXPERT

config CRASH_DEBUG
bool "Crash Debugging Support"
depends on X86
---help---
If you want to attach gdb to Xen to debug Xen if it crashes
then say Y.

config GDBSX
bool "Guest debugging with gdbsx"
depends on X86
Expand Down
1 change: 0 additions & 1 deletion xen/arch/x86/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ obj-y += e820.o
obj-y += emul-i8254.o
obj-y += extable.o
obj-y += flushtlb.o
obj-$(CONFIG_CRASH_DEBUG) += gdbstub.o
obj-$(CONFIG_GDBSX) += gdbsx.o
obj-y += hypercall.o
obj-y += i387.o
Expand Down
91 changes: 0 additions & 91 deletions xen/arch/x86/gdbstub.c

This file was deleted.

2 changes: 0 additions & 2 deletions xen/arch/x86/x86_64/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,3 @@ obj-$(CONFIG_COMPAT) += domain.o
obj-$(CONFIG_COMPAT) += cpu_idle.o
obj-$(CONFIG_COMPAT) += cpufreq.o
obj-bin-$(CONFIG_KEXEC) += kexec_reloc.o

obj-$(CONFIG_CRASH_DEBUG) += gdbstub.o
150 changes: 0 additions & 150 deletions xen/arch/x86/x86_64/gdbstub.c

This file was deleted.

1 change: 0 additions & 1 deletion xen/common/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ obj-$(CONFIG_OVERLAY_DTB) += dt-overlay.o
obj-y += event_2l.o
obj-y += event_channel.o
obj-y += event_fifo.o
obj-$(CONFIG_CRASH_DEBUG) += gdbstub.o
obj-$(CONFIG_GRANT_TABLE) += grant_table.o
obj-y += guestcopy.o
obj-bin-y += gunzip.init.o
Expand Down
Loading

0 comments on commit d182f9f

Please sign in to comment.