From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13840 invoked by alias); 5 Jul 2004 16:04:39 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 13818 invoked from network); 5 Jul 2004 16:04:33 -0000 Received: from unknown (HELO walton.kettenis.dyndns.org) (213.93.77.109) by sourceware.org with SMTP; 5 Jul 2004 16:04:33 -0000 Received: from elgar.kettenis.dyndns.org (elgar.kettenis.dyndns.org [192.168.0.2]) by walton.kettenis.dyndns.org (8.12.6p3/8.12.6) with ESMTP id i65Fx5vB009883; Mon, 5 Jul 2004 17:59:06 +0200 (CEST) (envelope-from kettenis@elgar.kettenis.dyndns.org) Received: from elgar.kettenis.dyndns.org (localhost [127.0.0.1]) by elgar.kettenis.dyndns.org (8.12.6p3/8.12.6) with ESMTP id i65Fx5p3074274; Mon, 5 Jul 2004 17:59:05 +0200 (CEST) (envelope-from kettenis@elgar.kettenis.dyndns.org) Received: (from kettenis@localhost) by elgar.kettenis.dyndns.org (8.12.6p3/8.12.6/Submit) id i65Fx5wR074271; Mon, 5 Jul 2004 17:59:05 +0200 (CEST) Date: Mon, 05 Jul 2004 16:04:00 -0000 Message-Id: <200407051559.i65Fx5wR074271@elgar.kettenis.dyndns.org> From: Mark Kettenis To: eliz@gnu.org CC: gdb-patches@sources.redhat.com In-reply-to: <3405-Sun04Jul2004221423+0300-eliz@gnu.org> Subject: Re: [PATCH] BSD libkvm documentation References: <200407031332.i63DWFeQ021626@elgar.kettenis.dyndns.org> <3405-Sun04Jul2004000929+0300-eliz@gnu.org> <200407040703.i64734Di071430@elgar.kettenis.dyndns.org> <3405-Sun04Jul2004221423+0300-eliz@gnu.org> X-SW-Source: 2004-07/txt/msg00033.txt.bz2 Date: Sun, 04 Jul 2004 22:14:24 +0200 From: "Eli Zaretskii" > Date: Sun, 4 Jul 2004 09:03:04 +0200 (CEST) > From: Mark Kettenis > > There's no reason to have 2 index entries both starting with "kvm" > and both pointing to the same page; it just bloats the index. Please > leave only the first @kindex entry and make it say just "@kindex kvm". > > There may be more "kvm" commands in the future, such that the section > doesn't fit on a single page anymore. That doesn't really matter, since they all are described one after the other. > Also it seems that current practice is to give every command a > @kindex entry. We should fix all such entries. Fair enough. Thanks for the explanation. I committed the attached. Mark Index: doc/ChangeLog from Mark Kettenis * gdb.texinfo (BSD libkvm Interface): New node (section) (Native): Add it to the menu. Index: doc/gdb.texinfo =================================================================== RCS file: /cvs/src/src/gdb/doc/gdb.texinfo,v retrieving revision 1.207 diff -u -p -r1.207 gdb.texinfo --- doc/gdb.texinfo 19 Jun 2004 17:33:44 -0000 1.207 +++ doc/gdb.texinfo 5 Jul 2004 15:27:48 -0000 @@ -11412,6 +11412,7 @@ configurations. @menu * HP-UX:: HP-UX +* BSD libkvm Interface:: Debugging BSD kernel memory images * SVR4 Process Information:: SVR4 process information * DJGPP Native:: Features specific to the DJGPP port * Cygwin Native:: Features specific to the Cygwin port @@ -11424,6 +11425,46 @@ On HP-UX systems, if you refer to a func begins with a dollar sign, @value{GDBN} searches for a user or system name first, before it searches for a convenience variable. +@node BSD libkvm Interface +@subsection BSD libkvm Interface + +@cindex libkvm +@cindex kernel memory image +@cindex kernel crash dump + +BSD-derived systems (FreeBSD/NetBSD/OpenBSD) have a kernel memory +interface that provides a uniform interface for accessing kernel virtual +memory images, including live systems and crash dumps. @value{GDBN} +uses this interface to allow you to debug live kernels and kernel crash +dumps on many native BSD configurations. This is implemented as a +special @code{kvm} debugging target. For debugging a live system, load +the currently running kernel into @value{GDBN} and connect to the +@code{kvm} target: + +@smallexample +(@value{GDBP}) @b{target kvm} +@end smallexample + +For debugging crash dumps, provide the file name of the crash dump as an +argument: + +@smallexample +(@value{GDBP}) @b{target kvm /var/crash/bsd.0} +@end smallexample + +Once connected to the @code{kvm} target, the following commands are +available: + +@table @code +@kindex kvm +@item kvm pcb +Set current context from pcb address. + +@item kvm proc +Set current context from proc address. This command isn't available on +modern FreeBSD systems. +@end table + @node SVR4 Process Information @subsection SVR4 process information