Re: Boot panic -CURRENT #196643

From: Kostik Belousov <kostikbel_at_gmail.com>
Date: Sat, 29 Aug 2009 23:57:23 +0300
On Sat, Aug 29, 2009 at 10:44:52PM +0200, Andreas Tobler wrote:
> Kostik Belousov wrote:
> >On Sat, Aug 29, 2009 at 10:00:45PM +0200, Andreas Tobler wrote:
> >>Kostik Belousov wrote:
> >>>On Sat, Aug 29, 2009 at 08:32:34PM +0200, Andreas Tobler wrote:
> >>>>Hello,
> >>>>
> >>>>I synced the sources today to #196643.
> >>>Try 196644.
> >>[tc:head/src/sys] andreast% svn info
> >>Path: .
> >>URL: svn://svn.freebsd.org/base/head/sys
> >>Repository Root: svn://svn.freebsd.org/base
> >>Repository UUID: ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
> >>Revision: 196644
> >>Node Kind: directory
> >>Schedule: normal
> >>Last Changed Author: kib
> >>Last Changed Rev: 196644
> >>Last Changed Date: 2009-08-29 20:01:02 +0200 (Sat, 29 Aug 2009)
> >>
> >>Still the same, as below.
> >>
> >>But with WITNESS etc. on:
> >>
> >>I get this panic:
> >>---
> >>Trying to mount root from zfs:zroot
> >>panic: thread_alloc got thread with kstack
> >>cpuid = 0
> >>KDB: enter: panic
> >>[thread pid 1 tid 100002 ]
> >>Stopped at	kdb_enter+0x3a: movl	$0,kdb_why
> >Can you show me the backtrace (from ddb) ?
> 
> I would like, yes, but as I said, the keyboard is not functional at this 
> moment, it would be activated after this mount.
> 
> Do I have other possibilties to get in connection with this machine?
> 
> 
> 
> >>>>And built a kernel with WITNESS etc. off.
> >>>>
> >>>>My boot partition sits on zfs.
> >>>>
> >>>>I get the below panic. Unfortunately I can't bt since the usb keyboard 
> >>>>ist not functional at this moment.
> >>>>
> >>>>---
> >>>>Trying to mount root from zfs:zroot
> >>>>spin lock 0x80dccc00 (sched lock 1) held by 0x8595baf0 (tid 100003) too 
> >>>>long
> >>>>panic: spin lock held too long
> >>>>cpuid = 0
> >>>>KDB: enter: panic
> >>>>[thread pid 1 tid 100002 ]
> >>>>Stopped at	kdb_enter+0x3a: movl	$0,kdb_why
> >>>>---
> >>>>
> >>>>Unfortunately I can't say exactly which version the previous, working, 
> >>>>kernel has. The svn nbr has gone. (I have this subversion:
> >>>>subversion-freebsd-1.6.5)
> >>This question is still open.
> >
> >r196639 will work for you.
> 
> :) I'll need a quick eye on it then.

Please, try this.

diff --git a/sys/vm/vm_glue.c b/sys/vm/vm_glue.c
index 234cde9..b0e8d3c 100644
--- a/sys/vm/vm_glue.c
+++ b/sys/vm/vm_glue.c
_at__at_ -447,6 +447,8 _at__at_ vm_thread_dispose(struct thread *td)
 	pages = td->td_kstack_pages;
 	ksobj = td->td_kstack_obj;
 	ks = td->td_kstack;
+	td->td_kstack = 0;
+	td->td_kstack_pages = 0;
 	if (pages == KSTACK_PAGES && kstacks <= kstack_cache_size) {
 		ks_ce = (struct kstack_cache_entry *)ks;
 		ks_ce->ksobj = ksobj;
_at__at_ -457,8 +459,6 _at__at_ vm_thread_dispose(struct thread *td)
 		return;
 	}
 	vm_thread_stack_dispose(ksobj, ks, pages);
-	td->td_kstack = 0;
-	td->td_kstack_pages = 0;
 }
 
 static void

Received on Sat Aug 29 2009 - 18:57:48 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:54 UTC