From owner-freebsd-current@FreeBSD.ORG Sun May 4 22:54:59 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 18DB237B401 for ; Sun, 4 May 2003 22:54:59 -0700 (PDT) Received: from rms21.rommon.net (rms21.rommon.net [193.64.42.200]) by mx1.FreeBSD.org (Postfix) with ESMTP id DC8A843F75 for ; Sun, 4 May 2003 22:54:57 -0700 (PDT) (envelope-from pete@he.iki.fi) Received: from PHE (h93.vuokselantie10.fi [193.64.42.147]) by rms21.rommon.net (8.12.6p2/8.12.6) with SMTP id h455suPG094378 for ; Mon, 5 May 2003 08:54:56 +0300 (EEST) (envelope-from pete@he.iki.fi) Message-ID: <010c01c312ca$dad34b00$932a40c1@PHE> From: "Petri Helenius" To: Date: Mon, 5 May 2003 08:54:55 +0300 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 Subject: kthread_exit and giant X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 May 2003 05:54:59 -0000 IŽve been bouncing this with Soren a few roundtrips and I thought IŽll ask a wider audience since I could not locate the information who would be responsible for grabbing Giant in this case, but it seems to be required to hold it when the thread exits; (the panic occurs when ATA RAID rebuild thread completes) FreeBSD 5.0-CURRENT #3: Sat May 3 11:09:45 GMT 2003 root@kompak.vuokselantie10.fi:/usr/src/sys/i386/compile/EMTEST kompak# atacontrol status 0 ar0: ATA RAID1 subdisks: ad4 ad6 status: REBUILDING 44% completed kompak# panic: mutex Giant not owned at ../../../kern/kern_exit.c:122 Debugger("panic") Stopped at Debugger+0x54: xchgl %ebx,in_Debugger.0 db> trace Debugger(c038d044,c03eedc0,c038c78b,d26f4c54,1) at Debugger+0x54 panic(c038c78b,c038c8c4,c038acdf,7a,104) at panic+0xab _mtx_assert(c03ed140,1,c038acdf,7a,85) at _mtx_assert+0xec exit1(c2a075f0,0,85,84,2) at exit1+0x33 kthread_exit(0,1,1,0,0) at kthread_exit+0xb6 ar_rebuild(c25e3000,d26f4d48,c038ad90,310,c2a075f0) at ar_rebuild+0x445 fork_exit(c0161c40,c25e3000,d26f4d48) at fork_exit+0xc0 fork_trampoline() at fork_trampoline+0x1a --- trap 0x1, eip = 0, esp = 0xd26f4d7c, ebp = 0 --- db>