Subject: port-hp300/1821: gdb -k doesn't give complete stack backtrace
To: None <gnats-bugs@gnats.netbsd.org>
From: Don Lewis <gdonl@gv.ssi1.com>
List: netbsd-bugs
Date: 12/07/1995 00:41:41
>Number:         1821
>Category:       port-hp300
>Synopsis:       gdb -k doesn't give complete stack backtrace
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Dec  7 06:20:03 1995
>Last-Modified:
>Originator:     
>Organization:
Don "Truck" Lewis                                       Silicon Systems
Internet: gdonl@gv.ssi1.com                             138 New Mohawk Road
Phone: +1 916 478-8284       FAX: +1 916 478-8251       Nevada City, CA  95959
>Release:        NetBSD-1.1
>Environment:
	
System: NetBSD frankenstein 1.1 NetBSD 1.1 (FRANKENSTEIN) #2: Wed Dec 6 02:24:26 PST 1995 gdonl@frankenstein:/usr/src/sys/arch/hp300/compile/FRANKENSTEIN hp300


>Description:
After a system crash, I was unable to debug a crash dump with gdb.  Gdb
is only able to access the last few stack frames with the backtrace command.
The frame command was not able to get around the blockage either.  The kernel
was compiled with -g and I had a copy of netbsd.gdb available.  Gdb was not
able to get any further with the stripped copy of /netbsd.

This is what gdb reports:

] frankenstein gdonl 134> gdb -k /sys/arch/hp300/compile/FRANKENSTEIN/netbsd.gdb netbsd.0.core
] GDB is free software and you are welcome to distribute copies of it
]  under certain conditions; type "show copying" to see the conditions.
] There is absolutely no warranty for GDB; type "show warranty" for details.
] GDB 4.11 (m68k-netbsd), Copyright 1993 Free Software Foundation, Inc...
] panic: MMU fault
] #0  panic (fmt=0x100 "") at ../../../../kern/subr_prf.c:130
] 130     }
] (kgdb) bt
] #0  panic (fmt=0x100 "") at ../../../../kern/subr_prf.c:130
] #1  0x1923a in panic (fmt=0x7d71d "MMU fault")
]     at ../../../../kern/subr_prf.c:129
] #2  0x7da14 in trap (type=8, code=1349, v=7761920, frame={F_t = {tf_regs = {
]           -28672, 1, 2, 0, 0, 12, -2145892847, 29834752, 29809728, 4, 746508, 
]           7761920, 29437952, 7933640, 7933240, -1049348}, tf_pad = 0, 
]         tf_stackadj = 0, tf_sr = 8217, tf_pc = 82574, tf_format = 7, 
]         tf_vector = 8}, F_u = {F_fmt2 = {f_iaddr = 7933236}, F_fmt3 = {
]           f_ea = 7933236}, F_fmt7 = {f_ea = 7933236, f_ssw = 1349, f_wb3s = 5, 
]           f_wb2s = 69, f_wb1s = 5, f_fa = 7761920, f_wb3a = 7933208, 
]           f_wb3d = 2, f_wb2a = 82526, f_wb2d = 7933216, f_wb1a = 7933216, 
]           f_wb1d = 180308, f_pd1 = 7933208, f_pd2 = 29761024, f_pd3 = 82526}, 
]         F_fmt9 = {f_iaddr = 7933236, f_iregs = {1349, 5, 69, 5}}, F_fmtA = {
]           f_ir0 = 121, f_ssw = 3380, f_ipsc = 1349, f_ipsb = 5, 
]           f_dcfa = 4521989, f_ir1 = 118, f_ir2 = 28672, f_dob = 7933208, 
]           f_ir3 = 0, f_ir4 = 2}, F_fmtB = {f_ir0 = 121, f_ssw = 3380, 
]           f_ipsc = 1349, f_ipsb = 5, f_dcfa = 4521989, f_ir1 = 118, 
]           f_ir2 = 28672, f_dob = 7933208, f_ir3 = 0, f_ir4 = 2, f_ir5 = 1, 
]           f_ir6 = 16990, f_sba = 7933216, f_ir7 = 121, f_ir8 = 3360, 
]           f_dib = 180308, f_iregs = {121, 3352, 454, 7680, 1, 16990, 0, 2, 0, 
]             0, 0, 0, 0, 0, 0, 40, 1, 16990, 449, 12288, 121, 3784}}}})
]     at ../../../../arch/hp300/hp300/trap.c:250
] #3  0x544 in addrerr ()
] Cannot access memory at address 0x498.
] (kgdb) 

The stack backtrace accessible from the console looked more like:

_Debugger( ... )
_panic( ... ) + ...
_trap( ... ) + ...
_adderr( ... ) + ...
_ccdioctl( ... ) + ...
_spec_ioctl( ... ) + ...
_vn_ioctl( ... ) + ...
_sys_ioctl( ... ) + ...
_syscall( ... ) + ...
_trap0( ... ) + ...

>How-To-Repeat:
	
>Fix:
>Audit-Trail:
>Unformatted: