From owner-freebsd-hackers@FreeBSD.ORG Fri Sep 30 16:33:12 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 451A616A41F for ; Fri, 30 Sep 2005 16:33:12 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (vc4-2-0-87.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4267443D69 for ; Fri, 30 Sep 2005 16:33:08 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (localhost.village.org [127.0.0.1] (may be forged)) by harmony.bsdimp.com (8.13.3/8.13.3) with ESMTP id j8UGUasw050700; Fri, 30 Sep 2005 10:30:36 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Fri, 30 Sep 2005 10:31:18 -0600 (MDT) Message-Id: <20050930.103118.121221639.imp@bsdimp.com> To: kerndev@yahoo.com From: "M. Warner Losh" In-Reply-To: <20050930010434.67727.qmail@web35003.mail.mud.yahoo.com> References: <20050930010434.67727.qmail@web35003.mail.mud.yahoo.com> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (harmony.bsdimp.com [127.0.0.1]); Fri, 30 Sep 2005 10:30:37 -0600 (MDT) Cc: hackers@freebsd.org Subject: Re: using fast interrupts with em(4) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Sep 2005 16:33:12 -0000 In message: <20050930010434.67727.qmail@web35003.mail.mud.yahoo.com> Kernel Dev writes: : Hello All. For a project, I am looking into making the em(4) driver use fast interrupts. Has someone done this or are there other driver references that could help me in this? : : I understand that the main problems are: : : 1. Sharing of interrupts. : 2. Blocking (memory and mutexes). : : Are there any other issues I might have missed? You can share fast interrupts, but it isn't a good idea... You can't block in a fast interrupt. You must use spin locks. You cannot call anything that will sleep in a fast interrupt. Ideally, you'd not modify anything that isn't covered by your own spin locks, leaving that for a taskqueue or similar queueing strategy. Warner