Panic with recent uipc changes?
Robert Watson
rwatson at FreeBSD.org
Wed Jul 26 18:13:52 UTC 2006
On Thu, 27 Jul 2006, Munehiro Matsuda wrote:
> Hi Robert Watson,
>
> Recent changes to uipc, the UNIX domain sockets, seems to cause my -current
> laptop to panic and reboot whenever I stop emacs.
>
> Is there anything I can do to help debug this?
I think that the information you attached is sufficient. Could you try
removing the call to soisdisconnected() in uipc_detach()? It should now occur
in the close path. Patch attached.
Robert N M Watson
Computer Laboratory
University of Cambridge
>
> =--------------------------------------------------------------------------
> kdb_backtrace(2,c378569c,c,c3488d80,de34fa10,...) at kdb_backtrace+0x29
> witness_warn(5,0,c07208c5) at witness_warn+0x192
> trap(c07b0008,28,c06f0028,c357c9dc,c357c914,...) at trap+0x108
> calltrap() at calltrap+0x5
> --- trap 0xc, eip = 0xc050fc8e, esp = 0xde34fa58, ebp = 0xde34fa58 ---
> knlist_mtx_locked(0) at knlist_mtx_locked+0x6
> knote(c357c9dc,0,1,c357c9f4,c357c914,...) at knote+0x1d
> sowakeup(c357c914,c357c9d0) at sowakeup+0x61
> soisdisconnected(c357c914,c357c9f4,c357c914,0,de34fad4,...) at soisdisconnected+0xdc
> uipc_detach(c357c914) at uipc_detach+0xe3
> sofree(c357c914) at sofree+0x27b
> soclose(c357c914) at soclose+0x2d9
> soo_close(c359eb88,c3488d80) at soo_close+0x4b
> fdrop_locked(c359eb88,c3488d80,c2dfa220,0,c06f91cb,...) at fdrop_locked+0x88
> fdrop(c359eb88,c3488d80,6b5,c0777974,0,...) at fdrop+0x24
> closef(c359eb88,c3488d80) at closef+0x367
> fdfree(c3488d80) at fdfree+0x4a3
> exit1(c3488d80,0,de34fd30,c06b8cea,c3488d80,...) at exit1+0x420
> exit1(c3488d80,de34fd04) at exit1
> syscall(58de003b,827003b,bfbf003b,bfbfdce0,bfbfdce0,...) at syscall+0x27e
> Xint0x80_syscall() at Xint0x80_syscall+0x1f
> --- syscall (1, FreeBSD ELF32, sys_exit), eip = 0x284da41b, esp = 0xbfbfdc7c, ebp = 0xbfbfdc98 ---
>
>
> Fatal trap 12: page fault while in kernel mode
> cpuid = 0; apic id = 00
> fault virtual address = 0x10
> fault code = supervisor read, page not present
> instruction pointer = 0x20:0xc050fc8e
> stack pointer = 0x28:0xde34fa58
> frame pointer = 0x28:0xde34fa58
> code segment = base 0x0, limit 0xfffff, type 0x1b
> = DPL 0, pres 1, def32 1, gran 1
> processor eflags = interrupt enabled, resume, IOPL = 0
> current process = 39065 (emacs)
> trap number = 12
> panic: page fault
> cpuid = 0
> KDB: enter: panic
> =--------------------------------------------------------------------------
>
>
> Thanks in advance,
> Haro
> =------------------------------------------------------------------------------
> _ _ Munehiro (haro) Matsuda
> -|- /_\ |_|_| Internet Solution Dept., KGT Inc.
> /|\ |_| |_|_| 2-8-8 Shinjuku Shinjuku-ku Tokyo 160-0022, Japan
> Tel: +81-3-3225-0767 Fax: +81-3-3225-0740
> Email: haro at kgt.co.jp
>
-------------- next part --------------
Index: uipc_usrreq.c
===================================================================
RCS file: /zoo/cvsup/FreeBSD-CVS/src/sys/kern/uipc_usrreq.c,v
retrieving revision 1.181
diff -u -r1.181 uipc_usrreq.c
--- uipc_usrreq.c 24 Jul 2006 15:20:07 -0000 1.181
+++ uipc_usrreq.c 26 Jul 2006 18:11:22 -0000
@@ -443,7 +443,6 @@
struct unpcb *ref = LIST_FIRST(&unp->unp_refs);
unp_drop(ref, ECONNRESET);
}
- soisdisconnected(unp->unp_socket);
unp->unp_socket->so_pcb = NULL;
local_unp_rights = unp_rights;
UNP_UNLOCK();
More information about the freebsd-current
mailing list