From owner-freebsd-current@FreeBSD.ORG Sat May 1 20:13:07 2004 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 C131716A4CE for ; Sat, 1 May 2004 20:13:07 -0700 (PDT) Received: from mailout2.pacific.net.au (mailout2.pacific.net.au [61.8.0.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0227B43D48 for ; Sat, 1 May 2004 20:13:07 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from mailproxy2.pacific.net.au (mailproxy2.pacific.net.au [61.8.0.87])i423Ct5v029861; Sun, 2 May 2004 13:12:55 +1000 Received: from gamplex.bde.org (katana.zip.com.au [61.8.7.246]) i423CqHW009383; Sun, 2 May 2004 13:12:53 +1000 Date: Sun, 2 May 2004 13:12:51 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: "M. Warner Losh" In-Reply-To: <20040501.162455.37300016.imp@bsdimp.com> Message-ID: <20040502130027.O1806@gamplex.bde.org> References: <20040426233925.Y5300@gamplex.bde.org> <20040430102504.477152ce.bm@malepartus.de> <20040501.162455.37300016.imp@bsdimp.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: bm@malepartus.de cc: freebsd-current@freebsd.org Subject: Re: sio: lots of silo overflows on Asus K8V with Moxa Smartio C104H/PCI 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: Sun, 02 May 2004 03:13:07 -0000 On Sat, 1 May 2004, M. Warner Losh wrote: > In message: <20040501140658.F19558@gamplex.bde.org> > Bruce Evans writes: > : Not using a fast interrupt handler may cause occasional silo overflows, > : but shouldn't cause many. The problem is mostly elsewhere (Giant locking > : for too long), but siointr() shouldn't use Giant locking. Try the following > : patch if you still have shared interrupts: > > Is the tty layer giant safe now? No, but siointr() doesn't go near the tty layer or almost any other layer. It uses pseudo-dma and schedules a SWI to transfer data between its buffers and the tty layer. Fast interrupt handlers cannot call other layers because they cannot reasonable lock other layers or vice versa. (Even the call to the scheduler to schedule a SWI in the current implementation is a layering violation.) SImilarly for all other fast interrupt handlers if they are attached as normal interrupt handlers without changing their locking. The requirements for them to act as fast interrupt handlers are stricter than those for INTR_MPSAFE normal interrupt handlers, so fast interrupt handlers are automatically INTR_MPSAFE when downgraded to normal ones. Bruce