Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 24 Jan 2007 11:25:41 -0800
From:      "Rao, Nikhil" <nikhil.rao@intel.com>
To:        <freebsd-amd64@freebsd.org>
Subject:   Issue with using KGDB for remote debug over serial port
Message-ID:  <12A5C15467D5B94F8E0FF265D9498ADDE516F5@orsmsx419.amr.corp.intel.com>

index | next in thread | raw e-mail

I am trying to debug an AMD64 kernel over a serial connection. Both the
host and the target are running AMD64 6.1 release kernels.
 
Target platform - Dell Precision Workstation 690, (Dual Quad core system
with Intel Xeon  1.86 Ghz CPU)
Host - XPS 600 Dell - Intel Pentium D 3.00 Ghz CPU
 
The target platform boots a 6.1 release GENERIC AMD64 kernel with
makeoptions DEBUG=-g,  KDB and GDB options enabled and has a serial
connection with the host. In device.hints I have set
hint.sio0.flags=0x80
 
I am able to enter kgdb using the -d boot option, next I can break on a
breakpoint. However when I try to step the debugger, the target gets a
page fault in kernel mode. I have attached a log of the kgdb output
below. Please let me know if any other info. would be useful to resolve
this problem.
 
<cut>
[GDB will not be able to debug user-mode threads:
/usr/lib/libthread_db.so: Undefined symbol "ps_pglobal_lookup"]

<cut>

0xffffffff803ecf8f in kdb_enter (msg=0x0) at cpufunc.h:63

63 __asm __volatile("int $3");

Unread portion of the kernel message buffer:

Cannot access memory at address 0xf000a8ece001a840

(kgdb) break pmap_pinit0

Breakpoint 1 at 0xffffffff805c4d10: file
/usr/src/sys/amd64/amd64/pmap.c, line 1059.

(kgdb) c

Continuing.

[New Thread 0]

Program received signal SIGQUIT, Quit.

[Switching to Thread 0]

pmap_pinit0 (pmap=0xffffff0000049d00) at
/usr/src/sys/amd64/amd64/pmap.c:1061

1061 PMAP_LOCK_INIT(pmap);

(kgdb) break 1066

Breakpoint 2 at 0xffffffff805c4d70: file
/usr/src/sys/amd64/amd64/pmap.c, line 1066.

(kgdb) c

Continuing.

Program received signal SIGSYS, Bad system call.

0x0000000000000000 in ?? ()

(kgdb) bt

#0 0x0000000000000000 in ?? ()

#1 0x0000000000000000 in ?? ()

(kgdb)



help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?12A5C15467D5B94F8E0FF265D9498ADDE516F5>