From owner-freebsd-sparc64@FreeBSD.ORG Tue Apr 21 19:15:36 2009 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 67B7B1065672 for ; Tue, 21 Apr 2009 19:15:36 +0000 (UTC) (envelope-from flo@kasimir.com) Received: from mail.solomo.de (mail.solomo.de [85.214.49.72]) by mx1.freebsd.org (Postfix) with ESMTP id 0B6288FC24 for ; Tue, 21 Apr 2009 19:15:35 +0000 (UTC) (envelope-from flo@kasimir.com) Received: from localhost (localhost [127.0.0.1]) by mail.solomo.de (Postfix) with ESMTP id E1E6C3F4C1; Tue, 21 Apr 2009 21:15:34 +0200 (CEST) X-Virus-Scanned: amavisd-new at vistream.de Received: from mail.solomo.de ([127.0.0.1]) by localhost (mail.solomo.de [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Ie95Uy4gllrz; Tue, 21 Apr 2009 21:15:32 +0200 (CEST) Received: from nibbler.lan (i5E86A0C5.versanet.de [94.134.160.197]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mail.solomo.de (Postfix) with ESMTPSA id 868DE3F4DB; Tue, 21 Apr 2009 21:15:32 +0200 (CEST) Message-ID: <49EE1B54.50003@kasimir.com> Date: Tue, 21 Apr 2009 21:15:32 +0200 From: Florian Smeets User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1b4pre) Gecko/20090420 Shredder/3.0b3pre MIME-Version: 1.0 To: Marius Strobl References: <20090325114426.GA74306@alchemy.franken.de> <49CA1BF1.6090507@kasimir.com> <20090420183620.GA25251@alchemy.franken.de> <49ED0917.10402@kasimir.com> <20090421185814.GA33994@alchemy.franken.de> In-Reply-To: <20090421185814.GA33994@alchemy.franken.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-sparc64@freebsd.org Subject: Re: US-III crashes on current X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Apr 2009 19:15:36 -0000 On 21.04.09 20:58, Marius Strobl wrote: > On Tue, Apr 21, 2009 at 01:45:27AM +0200, Florian Smeets wrote: >> >> Yes, i can still reproduce this on every shutdown. Tried with r191337. >> Trace is still the same. >> > > Could you please run gdb(1) on the corresponding kernel.debug > and report the output of the following commands? > l *(0xc034c96c) > l *(callout_lock+0x40) > Change as needed if the addresses differ from the above > backtrace. Hrm, the one you reported to scsi@ actually > is a bit different: >> -- fast data access mmu miss tar=0x1454156000 %o7=0xc040e7a4 -- >> _mtx_lock_spin_flags() at _mtx_lock_spin_flags+0x5c >> callout_lock() at callout_lock+0x50 > > In that case please additionally get the output of > l *(_mtx_lock_spin_flags+0x5c) > OK, to get this straight this is the trace I'm talking about. Uptime: 19h19m49s panic: trap: fast data access mmu miss cpuid = 0 KDB: enter: panic [thread pid 97473 tid 100179 ] Stopped at kdb_enter+0x80: ta %xcc, 1 db> where Tracing pid 97473 tid 100179 td 0xfffff80006dfc370 panic() at panic+0x20c trap() at trap+0x4d0 -- fast data access mmu miss tar=0x20007e000 %o7=0xc03f70a4 -- callout_lock() at callout_lock+0x20 untimeout() at untimeout+0xc isp_done() at isp_done+0x140 isp_intr() at isp_intr+0x3eb8 isp_poll() at isp_poll+0x38 xpt_polled_action() at xpt_polled_action+0xc8 dashutdown() at dashutdown+0x16c boot() at boot+0x850 reboot() at reboot+0x64 syscall() at syscall+0x2b4 -- syscall (55, FreeBSD ELF64, reboot) %o7=0x1013e4 -- userland() at 0x40564948 user trace: trap %o7=0x1013e4 pc 0x40564948, sp 0x7fdffffe201 pc 0x100df0, sp 0x7fdffffe2c1 pc 0x40206954, sp 0x7fdffffe381 done (gdb) l *(0xc03f70a4) 0xc03f70a4 is in spinlock_exit (/usr/src/sys/sparc64/sparc64/machdep.c:232). 227 spinlock_exit(void) 228 { 229 struct thread *td; 230 231 td = curthread; 232 critical_exit(); 233 td->td_md.md_spinlock_count--; 234 if (td->td_md.md_spinlock_count == 0) 235 wrpr(pil, td->td_md.md_saved_pil, 0); 236 } (gdb) l *(callout_lock+0x20) 0xc0225000 is in callout_lock (/usr/src/sys/kern/kern_timeout.c:270). 265 { 266 struct callout_cpu *cc; 267 int cpu; 268 269 for (;;) { 270 cpu = c->c_cpu; 271 cc = CC_CPU(cpu); 272 CC_LOCK(cc); 273 if (cpu == c->c_cpu) 274 break; I had witness in my kernel when i reported this to scsi, i don't have that turned on right now, so perhaps this is why the other trace included _mtx_lock_spin_flags, it's not in the trace now but if i run the command you requested i get something non the less. (gdb) l *(_mtx_lock_spin_flags+0x5c) 0xc01ff2bc is in _mtx_lock_spin_flags (/usr/src/sys/kern/kern_mutex.c:225). 220 KASSERT((m->lock_object.lo_flags & LO_RECURSABLE) != 0, 221 ("mtx_lock_spin: recursed on non-recursive mutex %s @ %s:%d\n", 222 m->lock_object.lo_name, file, line)); 223 WITNESS_CHECKORDER(&m->lock_object, opts | LOP_NEWORDER | LOP_EXCLUSIVE, 224 file, line, NULL); 225 _get_spin_lock(m, curthread, opts, file, line); 226 LOCK_LOG_LOCK("LOCK", &m->lock_object, opts, m->mtx_recurse, file, 227 line); 228 WITNESS_LOCK(&m->lock_object, opts | LOP_EXCLUSIVE, file, line); 229 } Thanks for looking at this! Cheers, Florian