From owner-freebsd-current Tue Jul 16 11:26:23 2002 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 9E0C337B400 for ; Tue, 16 Jul 2002 11:26:20 -0700 (PDT) Received: from mail.speakeasy.net (mail14.speakeasy.net [216.254.0.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3409743E3B for ; Tue, 16 Jul 2002 11:26:20 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (qmail 5893 invoked from network); 16 Jul 2002 18:26:18 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail14.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 16 Jul 2002 18:26:18 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.11.6/8.11.6) with ESMTP id g6GIQH053683; Tue, 16 Jul 2002 14:26:17 -0400 (EDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.2 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <15668.23528.719956.574605@grasshopper.cs.duke.edu> Date: Tue, 16 Jul 2002 14:26:22 -0400 (EDT) From: John Baldwin To: Andrew Gallatin Subject: Re: VOP_GETATTR panic on Alpha Cc: current@freebsd.org, Andrew Kolchoogin Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 16-Jul-2002 Andrew Gallatin wrote: > > Andrew Kolchoogin writes: > > Hi! > > > > On Tue, Jul 16, 2002 at 02:45:11PM +0200, Dag-Erling Smorgrav wrote: > > > > > The following panic is 100% reproducable - it happens whenever I boot > > > a recent kernel on Alpha, just before init(8) starts getty(8) on the > > > console: > > sorry, kernel from today's sources at 17:38 works just fine. > > > > Yet another question about kernel core dumps: what should I do to get one?-) > > Why "panic" from debugger on i386 gives core dump and reboots the system > > and "panic" from debugger on Alpha does not? > > > > Because, as BDE says, that crashdumps work at all is mosty accidental. > > On alpha, a random kernel thread is waking up, and is unable to go > back to sleep because of the panicstr hack msleep: > > mtx_lock_spin(&sched_lock); > if (cold || panicstr) { > /* > * After a panic, or during autoconfiguration, > * just give interrupts a chance, then just return; > * don't run any other procs or panic below, > * in case this is the idle process and already asleep. > */ > if (mtx != NULL && priority & PDROP) > mtx_unlock(mtx); > mtx_unlock_spin(&sched_lock); > return (0); > } > > > We need to somehow let only interrupt threads and the panic'ed process > run after a panic. I have no idea how to do this in a clean, > low-impact way. It's probably preemption. However, the problem may be that you can't switch to the ithread if you just turn preemption on for panics because the ithread may already be on the run queue, thus why your earlier patch may not have worked. Try to see if it works ok if you turn on preemption fully by making the second arg to ithread_schedule() be !cold. FWIW, I only have problems with preemption on alphas if I use SMP. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message