Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Mar 2003 10:02:08 +0100 (CET)
From:      Harti Brandt <brandt@fokus.fraunhofer.de>
To:        Jonathan Lemon <jlemon@flugsvamp.com>
Cc:        net@freebsd.org
Subject:   Re: mallocing from if_start
Message-ID:  <20030313100006.J641@beagle.fokus.fraunhofer.de>
In-Reply-To: <200303121801.h2CI1lmT013659@mail.flugsvamp.com>
References:  <200303121801.h2CI1lmT013659@mail.flugsvamp.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 12 Mar 2003, Jonathan Lemon wrote:

JL>In article <local.mail.freebsd-net/20030312181454.V641@beagle.fokus.fraunhofer.de> 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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030313100006.J641>