Open Source
KDB News

There is now a patch for IA64 kdb. You can download it here.

Use of the 'bp' command in v1.0 or v1.1 will cause eventual system failure. Use the 'bph' command as a workaround.

Release v1.1 supports the following new features and bugfixes:

  • Fixed hardware breakpoint register handling on ia32 smp systems
  • Insert module symbols prior to calling module init function
  • Update to latest kdbm_vm module.
  • Don't need to stop processors when machine_reset called from kdb.

Release v1.0 supports the following new features and bugfixes.

  • Support for ef (exception frame) command.
  • Support for mips architecture
  • Support for ia64 architecture
  • Support for ia32 last-branch recording
  • Better multiple console support.
  • Support for new bph command family (hardware register breakpoints)
  • Support for breakpoint instruction-style breakpoints
  • Support for new bta command (backtrace all processes)
  • Architected to support multiple architectures.
  • Support for ia32 control-flow tracing.
  • General bugfixes.

Release v0.6 supports the following new features and bugfixes.

  • Much better support for SMP systems, including use of NMI to force all processors into the kernel debugger independent of the interrupt state of the processor. Once all processors have stopped, no interrupts are necessary to switch the kernel debugger between processors.
  • Better breakpoint handling on multiprocessor systems. Simultaneous breakpoints (e.g. bpa schedule) on multiple processors will be handled serially by the kernel debugger.
  • Pentium and PentiumPRO machine check exception handling.
  • Invoke KDB upon NMI (for systems with NMI button, allows debugging systems when all interrupts are disabled).
  • Somewhat better keyboard handling. I haven't encountered the keyboard hang with this release, but I don't guarantee it has been fixed. The garbage characters leftover have been fixed, however.
  • New 'sr' command to call MAGIC_SYSRQ functions (Thanks Masahiro Adegawa).
  • Handle symbols with MODVERSIONS tags (Thanks Masahiro Adegawa).
  • Under some circumstances, spurious breakpoints would occur. This should be fixed.
  • New loadable module commands to examine SCSI mid-layer data structures (Scsi_Cmnd, Scsi_Disk, Scsi_Host) and to examine a struct file.
  • rm command can be used to alter debug register contents.
  • Enhanced ps command to print process state and to show current process as well as active processes on other processors.
  • Space is no longer allocated in the kernel image for the symbol table when CONFIG_KDB=N, and the space requirement is computed dynamically when CONFIG_KDB=Y based upon the maximum number of symbols configured with make *config.
  • General bugfixes.

Release v0.5 supports the following new features (see acknowledgments below for contributors to release v0.5):

  • Better serial port support. Interrupt via Control-A is not functional until the port is opened by mingetty. To enter the kernel debugger sooner on a serial port, use the 'kdb' flag to lilo.
  • A subset of the commands may be abbreviated.
  • If the input text is not a valid command it is treated as an address expression and the resultant value is printed along with the name of the nearest symbol.
  • A 'bl' (breakpoint list) command is added.
  • Various bp messages shortened, and some bugs fixed.
  • '*' may be used as an argument to 'bc', 'bd' and 'be' to affect all existing breakpoints.
  • ss enhancements: print both executed and next instruction.
  • ss enhancements: now works over lock prefix.
  • Show current Instruction at instruction breakpoints.
  • Updated stack traceback code (with framepointers enabled), especially for the btp command.
  • bt will, given the address of a return EIP on the stack, attempt to backtrace the stack from that point.
  • CPU # is now in both kdb and more prompts.
  • Use uaccess macros to access user space.
  • Add new pseudo registers, '®s' (address of register), 'kesp' (kernel stack pointer at time of fault) and '%' (user version of reg).
  • Handle symbols from modules correctly, both searching and removing.
  • Add 'u' option to 'rd' command to display registers from most recent transition from user-mode to kernel-mode.
  • add two optional arguments to md command, linecount and radix. They will be remembered by subsequent 'md' commands without arguments.
  • mm verifies the address is valid before attempting modification.
  • export kdb_printf symbol for module access to kdb built-in pager.
  • fix boundary problem with vmalloc memory range checking.
  • Handle japanese keyboards correctly

Release v0.4 supports the following new features:

  • Complete module support for loadable kdb commands (with sample command)
  • Support debugging via a serial port
  • Add the 'll' command to follow linked lists
  • Validate address parameters to avoid bad pointer dereferences from the kernel debugger.

Release v0.3 supports the following:

  • Include symbols from loadable modules in kdb symbol table
  • Ensure that the register contents (rd command) are correct when switching CPU's with cpu command.
  • Ignore mouse events (Thanks to Richard Schaal)
  • Add kdb_unregister function to be called from module cleanup function
  • Move config entries for kdb to Kernel Hacking category
  • Remove memory address validity checking in kdbgetword (for now)

The following features are planned for successive releases of the kernel debugger for linux:

  • sso (single step over) command
  • enhance no-frame-pointer stack backtraces
  • Finish user manual
  • move pc_keyb.h to common location
  • Add support for examination and display of Model specific Registers
  • Configurable symbol table size
  • int03 breakpoints
  • support for i386/i486 processors (not likely soon)
  • split into processor independent and processor dependent parts
  • support count argument for 'ss' command.
  • Selectively run a single cpu.
  • Support entry via Non-Maskable Interrupt for servers with NMI buttons

Contributions to v0.5 from:

  • Richard Bass
  • Chuck Fleckenstein
  • Masahiro Adegawa
  • Suggestions from many others.