On Mon, Jun 29, 2009 at 11:15:06AM +0100, Lawrence Stewart wrote: > Hi All, > > My laptop panicked whilst shutting down yesterday. The shutdown sequence > seemed to terminate kde4/X correctly but got wedged prior to completing > the rest as seen on the console. Details below... > > uname -a: > FreeBSD lstewart-laptop 8.0-CURRENT FreeBSD 8.0-CURRENT #35 r195046: Fri > Jun 26 12:28:02 BST 2009 > lstewart_at_lstewart-laptop:/usr/obj/usr/src/sys/LAPTOP amd64 > > > > Backtrace: > > at /usr/src/sys/kern/subr_kdb.c:534 > #6 0xffffffff8084cb11 in trap (frame=0xffffff8058eb76a0) at > /usr/src/sys/amd64/amd64/trap.c:613 > > #7 0xffffffff80832f33 in calltrap () at > /usr/src/sys/amd64/amd64/exception.S:223 > > #8 0xffffffff805a736d in kdb_enter (why=0xffffffff80943489 "panic", > msg=0xa <Address 0xa out of bounds>) at cpufunc.h:63 > > #9 0xffffffff8057791b in panic (fmt=Variable "fmt" is not available. > ) at /usr/src/sys/kern/kern_shutdown.c:558 > > #10 0xffffffff805f6108 in vop_panic (ap=Variable "ap" is not available. > ) at /usr/src/sys/kern/vfs_default.c:175 > > #11 0xffffffff8054dee7 in exit1 (td=0xffffff00049c9720, rv=1) at > vnode_if.h:523 > > #12 0xffffffff8057927f in sigexit (td=0xffffff00049c9720, sig=0) > at /usr/src/sys/kern/kern_sig.c:2726 > > #13 0xffffffff80579e7f in postsig (sig=1491826128) at > /usr/src/sys/kern/kern_sig.c:2617 > > #14 0xffffffff805b422c in ast (framep=0xffffff8058eb7c90) at > /usr/src/sys/kern/subr_trap.c:225 > > #15 0xffffffff80833de9 in doreti_ast () at > /usr/src/sys/amd64/amd64/exception.S:623 > Are you able to reproduce the issue ? Please try the patch. diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index ae060da..c00b4f4 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c _at__at_ -334,10 +334,11 _at__at_ exit1(struct thread *td, int rv) tty_unlock(tp); } - if (ttyvp != NULL && ttyvp->v_type != VBAD) { + if (ttyvp != NULL) { sx_xunlock(&proctree_lock); - VOP_LOCK(ttyvp, LK_EXCLUSIVE); - VOP_REVOKE(ttyvp, REVOKEALL); + vn_lock(ttyvp, LK_EXCLUSIVE | LK_RETRY); + if (ttyvp->v_type != VBAD) + VOP_REVOKE(ttyvp, REVOKEALL); VOP_UNLOCK(ttyvp, 0); sx_xlock(&proctree_lock); }
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:50 UTC