From owner-freebsd-hackers@FreeBSD.ORG Sat Sep 18 00:02:53 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BDD2316A4CF for ; Sat, 18 Sep 2004 00:02:53 +0000 (GMT) Received: from pony2pub.arc.nasa.gov (pony2pub.arc.nasa.gov [128.102.31.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id AC3E843D5C for ; Sat, 18 Sep 2004 00:02:53 +0000 (GMT) (envelope-from jtoung@arc.nasa.gov) Received: from mrcrab.nas.nasa.gov ([129.99.139.47] verified) by pony2pub.arc.nasa.gov (CommuniGate Pro SMTP 4.1.8) with ESMTP id 13701936 for freebsd-hackers@freebsd.org; Fri, 17 Sep 2004 17:02:53 -0700 Content-Type: text/plain; charset="us-ascii" From: Jerry Toung To: freebsd-hackers@freebsd.org Date: Fri, 17 Sep 2004 17:02:58 -0700 User-Agent: KMail/1.4.3 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200409171702.58905.jtoung@arc.nasa.gov> Subject: add-symbol-file X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: jtoung@arc.nasa.gov List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 Sep 2004 00:02:53 -0000 Hello list, Could somebody tell me why I can't "list" the source code of this kld? I built the module with COPTS=3D-g, it is loaded in the kernel and I run = kgdb in=20 /usr/obj/...../MYKERNEL. Everything seems to go well, except kgdb still=20 doesn't like it. However if I run kldsyms, it only loads acpi.ko.debug an= d I=20 can list it. Thank you in advance, Jerry PC203# kgdb kernel.debug /usr/home/guest/crash/vmcore.2 [GDB will not be able to debug user-mode threads: /usr/lib/libthread_db.s= o:=20 Undefined symbol "ps_pglobal_lookup"] GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you = are welcome to change it and/or distribute copies of it under certain conditi= ons. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for detail= s. This GDB was configured as "i386-marcel-freebsd". Ready to go. Enter 'tr' to connect to the remote target with /dev/cuaa0, 'tr /dev/cuaa1' to connect to a different port or 'trf portno' to connect to the remote target with the firewire interface. portno defaults to 5556. Type 'getsyms' after connection to load kld symbols. If you're debugging a local system, you can use 'kldsyms' instead to load the kld symbols. That's a less obnoxious interface. doadump () at pcpu.h:159 (kgdb) add-symbol-file /usr/local/src/nren-6.0current/osr_src/if_osr.ko=20 0xc24b3184 -s .data 0xc24b6900 -s .bss 0xc24b6cc0 add symbol table from file "/usr/local/src/nren-6.0current/osr_src/if_osr= =2Eko"=20 at .text_addr =3D 0xc24b3184 .data_addr =3D 0xc24b6900 .bss_addr =3D 0xc24b6cc0 (y or n) y Reading symbols from /usr/local/src/nren-6.0current/osr_src/if_osr.ko...d= one. (kgdb) list *0xc24b3184 No source file for address 0xc24b3184. (kgdb) kldstat During symbol reading, Incomplete CFI data; unspecified registers at=20 0xc05ff7d1. Id Refs Address Size Name 1 4 0xc0400000 5d63e4 kernel 2 14 0xc09d7000 54784 acpi.ko 3 1 0xc2326000 6000 if_osr.ko (kgdb)=20