Re: GPF on Current kernel

From: Larry Rosenman <ler_at_lerctr.org>
Date: Tue, 07 Jul 2015 08:50:15 -0500
On 2015-07-07 08:36, Konstantin Belousov wrote:
> On Tue, Jul 07, 2015 at 08:02:39AM -0500, Larry Rosenman wrote:
>> (kgdb) #0  doadump (textdump=1) at pcpu.h:221
>> #1  0xffffffff80a95445 in kern_reboot (howto=260)
>>     at /usr/src/sys/kern/kern_shutdown.c:447
>> #2  0xffffffff80a95a38 in vpanic (fmt=<value optimized out>,
>>     ap=<value optimized out>) at /usr/src/sys/kern/kern_shutdown.c:744
>> #3  0xffffffff80a95a83 in panic (fmt=0x0)
>>     at /usr/src/sys/kern/kern_shutdown.c:675
>> #4  0xffffffff80ed8275 in trap_fatal (frame=<value optimized out>,
>>     eva=<value optimized out>) at /usr/src/sys/amd64/amd64/trap.c:853
>> #5  0xffffffff80ed7f03 in trap (frame=<value optimized out>)
>>     at /usr/src/sys/amd64/amd64/trap.c:201
>> #6  0xffffffff80eb8582 in calltrap ()
>>     at /usr/src/sys/amd64/amd64/exception.S:235
>> #7  0xffffffff80a7984f in __mtx_lock_flags (c=0xdeadc0dedeadc116, 
>> opts=0,
>>     file=0xffffffff8120d108 "/usr/src/sys/kern/sys_generic.c", 
>> line=1808)
>>     at /usr/src/sys/kern/kern_mutex.c:211
>> #8  0xffffffff80af1215 in doselwakeup (sip=0xfffff8023d00a970, 
>> pri=104)
>>     at /usr/src/sys/kern/sys_generic.c:1808
>> #9  0xffffffff80af4276 in pipeselwakeup (cpipe=0xfffff8023d00a8b8)
>>     at /usr/src/sys/kern/sys_pipe.c:622
> From this frame, please do
> p *(cpipe->pipe_pair)
> p *pipe_zone
> 
>> #10 0xffffffff80af2f82 in pipe_write (fp=0xfffff8027f5f14b0,
>>     uio=<value optimized out>, active_cred=<value optimized out>, 
>> flags=1808,
>>     td=0xfffff801a357b980) at /usr/src/sys/kern/sys_pipe.c:1314
>> #11 0xffffffff80aeeeca in dofilewrite (td=0xfffff801a357b980, fd=1,
>>     fp=0xfffff8027f5f14b0, auio=0xfffffe2eb487cab0,
>>     offset=<value optimized out>, flags=0) at file.h:310
>> #12 0xffffffff80aeebd8 in kern_writev (td=0xfffff801a357b980, fd=1,
>>     auio=0xfffffe2eb487cab0) at /usr/src/sys/kern/sys_generic.c:485
>> #13 0xffffffff80aeeb63 in sys_write (td=0xdeadc0dedeadc116,
>>     uap=<value optimized out>) at /usr/src/sys/kern/sys_generic.c:398
>> #14 0xffffffff80ed8a6d in amd64_syscall (td=0xfffff801a357b980, 
>> traced=0)
>>     at subr_syscall.c:133
>> #15 0xffffffff80eb886b in Xfast_syscall ()
>>     at /usr/src/sys/amd64/amd64/exception.S:395
>> #16 0x000000000045ae8a in ?? ()
>> Previous frame inner to this frame (corrupt stack?)
>> Current language:  auto; currently minimal
>> (kgdb)
>> 
>> 
>> 
>> --
>> Larry Rosenman                     http://www.lerctr.org/~ler
>> Phone: +1 214-642-9640                 E-Mail: ler_at_lerctr.org
>> US Mail: 108 Turvey Cove, Hutto, TX 78634-5688
borg.lerctr.org /var/crash # kgdb -c vmcore.7 /boot/kernel/kernel
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 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for 
details.
This GDB was configured as "amd64-marcel-freebsd"...

Unread portion of the kernel message buffer:


Fatal trap 9: general protection fault while in kernel mode
cpuid = 6; apic id = 06
instruction pointer	= 0x20:0xffffffff80a7984f
stack pointer	        = 0x28:0xfffffe2eb487c8a0
frame pointer	        = 0x28:0xfffffe2eb487c8e0
code segment		= base 0x0, limit 0xfffff, type 0x1b
			= DPL 0, pres 1, long 1, def32 0, gran 1
processor eflags	= interrupt enabled, resume, IOPL = 0
current process		= 27111 (make)
trap number		= 9
panic: general protection fault
cpuid = 6
KDB: stack backtrace:
db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 
0xfffffe2eb487c490
vpanic() at vpanic+0x189/frame 0xfffffe2eb487c510
panic() at panic+0x43/frame 0xfffffe2eb487c570
trap_fatal() at trap_fatal+0x355/frame 0xfffffe2eb487c5d0
trap() at trap+0x813/frame 0xfffffe2eb487c7e0
calltrap() at calltrap+0x8/frame 0xfffffe2eb487c7e0
--- trap 0x9, rip = 0xffffffff80a7984f, rsp = 0xfffffe2eb487c8a0, rbp = 
0xfffffe2eb487c8e0 ---
__mtx_lock_flags() at __mtx_lock_flags+0x4f/frame 0xfffffe2eb487c8e0
doselwakeup() at doselwakeup+0xb5/frame 0xfffffe2eb487c920
pipeselwakeup() at pipeselwakeup+0x46/frame 0xfffffe2eb487c940
pipe_write() at pipe_write+0x13d2/frame 0xfffffe2eb487c9f0
dofilewrite() at dofilewrite+0x8a/frame 0xfffffe2eb487ca40
kern_writev() at kern_writev+0x68/frame 0xfffffe2eb487ca90
sys_write() at sys_write+0x63/frame 0xfffffe2eb487cae0
amd64_syscall() at amd64_syscall+0x25d/frame 0xfffffe2eb487cbf0
Xfast_syscall() at Xfast_syscall+0xfb/frame 0xfffffe2eb487cbf0
--- syscall (4, FreeBSD ELF64, sys_write), rip = 0x45ae8a, rsp = 
0x7fffffffd308, rbp = 0x7fffffffd330 ---
Uptime: 5m43s
Dumping 3223 out of 64458 
MB:..1%..11%..21%..31%..41%..51%..61%..71%..81%..91%

Reading symbols from /boot/kernel/linux.ko.symbols...done.
Loaded symbols for /boot/kernel/linux.ko.symbols
Reading symbols from /boot/kernel/linux_common.ko.symbols...done.
Loaded symbols for /boot/kernel/linux_common.ko.symbols
Reading symbols from /boot/kernel/if_lagg.ko.symbols...done.
Loaded symbols for /boot/kernel/if_lagg.ko.symbols
Reading symbols from /boot/kernel/snd_envy24ht.ko.symbols...done.
Loaded symbols for /boot/kernel/snd_envy24ht.ko.symbols
Reading symbols from /boot/kernel/snd_spicds.ko.symbols...done.
Loaded symbols for /boot/kernel/snd_spicds.ko.symbols
Reading symbols from /boot/kernel/coretemp.ko.symbols...done.
Loaded symbols for /boot/kernel/coretemp.ko.symbols
Reading symbols from /boot/kernel/ichsmb.ko.symbols...done.
Loaded symbols for /boot/kernel/ichsmb.ko.symbols
Reading symbols from /boot/kernel/smbus.ko.symbols...done.
Loaded symbols for /boot/kernel/smbus.ko.symbols
Reading symbols from /boot/kernel/ichwd.ko.symbols...done.
Loaded symbols for /boot/kernel/ichwd.ko.symbols
Reading symbols from /boot/kernel/cpuctl.ko.symbols...done.
Loaded symbols for /boot/kernel/cpuctl.ko.symbols
Reading symbols from /boot/kernel/cryptodev.ko.symbols...done.
Loaded symbols for /boot/kernel/cryptodev.ko.symbols
Reading symbols from /boot/kernel/dtraceall.ko.symbols...done.
Loaded symbols for /boot/kernel/dtraceall.ko.symbols
Reading symbols from /boot/kernel/profile.ko.symbols...done.
Loaded symbols for /boot/kernel/profile.ko.symbols
Reading symbols from /boot/kernel/dtrace.ko.symbols...done.
Loaded symbols for /boot/kernel/dtrace.ko.symbols
Reading symbols from /boot/kernel/systrace_freebsd32.ko.symbols...done.
Loaded symbols for /boot/kernel/systrace_freebsd32.ko.symbols
Reading symbols from /boot/kernel/systrace.ko.symbols...done.
Loaded symbols for /boot/kernel/systrace.ko.symbols
Reading symbols from /boot/kernel/sdt.ko.symbols...done.
Loaded symbols for /boot/kernel/sdt.ko.symbols
Reading symbols from /boot/kernel/lockstat.ko.symbols...done.
Loaded symbols for /boot/kernel/lockstat.ko.symbols
Reading symbols from /boot/kernel/fasttrap.ko.symbols...done.
Loaded symbols for /boot/kernel/fasttrap.ko.symbols
Reading symbols from /boot/kernel/fbt.ko.symbols...done.
Loaded symbols for /boot/kernel/fbt.ko.symbols
Reading symbols from /boot/kernel/dtnfscl.ko.symbols...done.
Loaded symbols for /boot/kernel/dtnfscl.ko.symbols
Reading symbols from /boot/kernel/dtmalloc.ko.symbols...done.
Loaded symbols for /boot/kernel/dtmalloc.ko.symbols
Reading symbols from /boot/modules/nvidia.ko...done.
Loaded symbols for /boot/modules/nvidia.ko
Reading symbols from /boot/kernel/ipmi.ko.symbols...done.
Loaded symbols for /boot/kernel/ipmi.ko.symbols
Reading symbols from /boot/kernel/ipmi_linux.ko.symbols...done.
Loaded symbols for /boot/kernel/ipmi_linux.ko.symbols
Reading symbols from /boot/kernel/radeonkms.ko.symbols...done.
Loaded symbols for /boot/kernel/radeonkms.ko.symbols
Reading symbols from /boot/kernel/iicbb.ko.symbols...done.
Loaded symbols for /boot/kernel/iicbb.ko.symbols
Reading symbols from /boot/kernel/iicbus.ko.symbols...done.
Loaded symbols for /boot/kernel/iicbus.ko.symbols
Reading symbols from /boot/kernel/iic.ko.symbols...done.
Loaded symbols for /boot/kernel/iic.ko.symbols
Reading symbols from /boot/kernel/drm2.ko.symbols...done.
Loaded symbols for /boot/kernel/drm2.ko.symbols
Reading symbols from /boot/kernel/radeonkmsfw_R100_cp.ko.symbols...done.
Loaded symbols for /boot/kernel/radeonkmsfw_R100_cp.ko.symbols
Reading symbols from /boot/kernel/uhid.ko.symbols...done.
Loaded symbols for /boot/kernel/uhid.ko.symbols
#0  doadump (textdump=1) at pcpu.h:221
221	pcpu.h: No such file or directory.
	in pcpu.h
(kgdb) fr 9
#9  0xffffffff80af4276 in pipeselwakeup (cpipe=0xfffff8023d00a8b8)
     at /usr/src/sys/kern/sys_pipe.c:622
622			selwakeuppri(&cpipe->pipe_sel, PSOCK);
Current language:  auto; currently minimal
(kgdb) p*(cpipe->pipe_pair)
$1 = {pp_rpipe = {pipe_buffer = {cnt = 39, in = 39, out = 0, size = 
16384,
       buffer = 0xfffffe2e728b4000 "--- scripts.cleandir ---\n--- clean 
---\nrm -f legacy_test legacy_test.tmp Kyuafile.auto Kyuafile.auto.tmp\n 
cleandepend)\n"}, pipe_map = {cnt = 0, pos = 0, npages = 0, ms = 
0xfffff8023d00a8e8},
     pipe_sel = {si_tdlist = {tqh_first = 0x0, tqh_last = 
0xfffff8023d00a970},
       si_note = {kl_list = {slh_first = 0x0},
         kl_lock = 0xffffffff80a52d60 <knlist_mtx_lock>,
         kl_unlock = 0xffffffff80a52d80 <knlist_mtx_unlock>,
         kl_assert_locked = 0xffffffff80a52da0 
<knlist_mtx_assert_locked>,
         kl_assert_unlocked = 0xffffffff80a52dc0 
<knlist_mtx_assert_unlocked>,
         kl_lockarg = 0xfffff8023d00ab78}, si_mtx = 0xfffffe1eaa7feb50},
     pipe_atime = {tv_sec = 1436273336, tv_nsec = 51546000}, pipe_mtime = 
{
       tv_sec = 1436273336, tv_nsec = 137561000}, pipe_ctime = {
       tv_sec = 1436273335, tv_nsec = 317414000}, pipe_sigio = 0x0,
     pipe_peer = 0xfffff8023d00aa18, pipe_pair = 0xfffff8023d00a8b8,
     pipe_state = 2368, pipe_busy = 0, pipe_present = 1, pipe_wgen = 0,
     pipe_ino = 4294967295}, pp_wpipe = {pipe_buffer = {cnt = 0, in = 0,
       out = 0, size = 0, buffer = 0x0}, pipe_map = {cnt = 0, pos = 0,
       npages = 0, ms = 0xfffff8023d00aa48}, pipe_sel = {si_tdlist = {
         tqh_first = 0x0, tqh_last = 0x0}, si_note = {kl_list = {
           slh_first = 0x0}, kl_lock = 0xffffffff80a52d60 
<knlist_mtx_lock>,
         kl_unlock = 0xffffffff80a52d80 <knlist_mtx_unlock>,
         kl_assert_locked = 0xffffffff80a52da0 
<knlist_mtx_assert_locked>,
         kl_assert_unlocked = 0xffffffff80a52dc0 
<knlist_mtx_assert_unlocked>,
---Type <return> to continue, or q <return> to quit---
         kl_lockarg = 0xfffff8023d00ab78}, si_mtx = 0x0}, pipe_atime = {
       tv_sec = 1436273335, tv_nsec = 317414000}, pipe_mtime = {
       tv_sec = 1436273335, tv_nsec = 317414000}, pipe_ctime = {
       tv_sec = 1436273335, tv_nsec = 317414000}, pipe_sigio = 0x0,
     pipe_peer = 0xfffff8023d00a8b8, pipe_pair = 0xfffff8023d00a8b8,
     pipe_state = 2048, pipe_busy = 0, pipe_present = 1, pipe_wgen = 0,
     pipe_ino = 12}, pp_mtx = {lock_object = {
       lo_name = 0xffffffff8120d423 "pipe mutex", lo_flags = 553844736,
       lo_data = 0, lo_witness = 0x0}, mtx_lock = 18446735284651932034},
   pp_label = 0x0}
(kgdb) p *pipe_zone
$2 = {uz_lock = {lock_object = {lo_name = 0xffffffff8123f237 "pipe",
       lo_flags = 21168128, lo_data = 0, lo_witness = 0x0}, mtx_lock = 
4},
   uz_lockptr = 0xfffff8003255f600, uz_name = 0xffffffff8123f237 "pipe",
   uz_link = {le_next = 0x0, le_prev = 0xfffff8003255f690}, uz_buckets = 
{
     lh_first = 0xfffff80032a32100}, uz_kegs = {lh_first = 
0xfffff800325980b0},
   uz_klink = {kl_link = {le_next = 0x0, le_prev = 0xfffff800325980a8},
     kl_keg = 0xfffff8003255f600},
   uz_slab = 0xffffffff80d46310 <zone_fetch_slab>,
   uz_ctor = 0xffffffff80af47a0 <pipe_zone_ctor>, uz_dtor = 0, uz_init = 
0,
   uz_fini = 0, uz_import = 0xffffffff80d463c0 <zone_import>,
   uz_release = 0xffffffff80d46630 <zone_release>, uz_arg = 
0xfffff80032598000,
   uz_flags = 0, uz_size = 744, uz_allocs = 16753, uz_fails = 0,
   uz_frees = 16558, uz_sleeps = 0, uz_count = 13, uz_count_min = 13,
   uz_warning = 0x0, uz_ratecheck = {tv_sec = 0, tv_usec = 0},
   uz_cpu = 0xfffff80032598200}
(kgdb) borg.lerctr.org /var/crash #
-- 
Larry Rosenman                     http://www.lerctr.org/~ler
Phone: +1 214-642-9640                 E-Mail: ler_at_lerctr.org
US Mail: 108 Turvey Cove, Hutto, TX 78634-5688
Received on Tue Jul 07 2015 - 11:50:16 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:58 UTC