From owner-freebsd-net Thu Mar 13 1: 2:13 2003 Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A429737B401 for ; Thu, 13 Mar 2003 01:02:12 -0800 (PST) Received: from mailhub.fokus.fraunhofer.de (mailhub.fokus.fraunhofer.de [193.174.154.14]) by mx1.FreeBSD.org (Postfix) with ESMTP id 780DD43FD7 for ; Thu, 13 Mar 2003 01:02:11 -0800 (PST) (envelope-from brandt@fokus.fraunhofer.de) Received: from beagle (beagle [193.175.132.100]) by mailhub.fokus.fraunhofer.de (8.11.6/8.11.6) with ESMTP id h2D928M23199; Thu, 13 Mar 2003 10:02:08 +0100 (MET) Date: Thu, 13 Mar 2003 10:02:08 +0100 (CET) From: Harti Brandt To: Jonathan Lemon Cc: net@freebsd.org Subject: Re: mallocing from if_start In-Reply-To: <200303121801.h2CI1lmT013659@mail.flugsvamp.com> Message-ID: <20030313100006.J641@beagle.fokus.fraunhofer.de> References: <200303121801.h2CI1lmT013659@mail.flugsvamp.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Wed, 12 Mar 2003, Jonathan Lemon wrote: JL>In article you write: JL>> JL>>Hi all, JL>> JL>>I was under the impression that the if_start function is NOT called from JL>>an interrupt context, so I should be able to call uma_zalloc_arg(..., JL>>M_WAITOK) there. I get however JL>> JL>>Mar 12 18:12:49 catssrv kernel: malloc() of "en dma maps" with the JL>>following non-sleepablelocks held: JL>>Mar 12 18:12:49 catssrv kernel: exclusive sleep mutex netisr lock r = 0 JL>>(0xc022d9c0) locked @ /usr/src/sys/net/netisr.c:209 JL>> JL>>I'm wrong with my assumption? JL> JL>if_start() can be called from interrupt context from the bridging, JL>fast-forwarding, (and now) direct dispatch codepaths. That being JL>said, the message can be ignored, I'll rework things to use a gate JL>instead of a mutex, although this seems to be catching some hidden bugs. Is there a fast method to get rid of exactly this one warning until you rework the code? It really makes debugging and testing a driver very hard. I'm working on mutexifying the driver so I need witness. harti -- harti brandt, http://www.fokus.fraunhofer.de/research/cc/cats/employees/hartmut.brandt/private brandt@fokus.fraunhofer.de, harti@freebsd.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message