On Wed, Apr 04, 2007 at 10:10:07PM +0000, Stephen Hemminger wrote:
>
> > > Yes, you're right.  Perhaps we should get the rtnl first before
> > > tg3_full_lock(), or turn irq_sync into an atomic counter that allows
> > > nesting.
> 
> When you start reinventing windows locks or the BKL, you know
> you are going down the wrong path

Actually, I think what Michael's suggesting is quite different.
This would be a simple counter that tells the IRQ handlers to
not process any events.  So this isn't really a lock as such.

FWIW I think the counter sounds better than using the RTNL since
with the latter you'd have to figure out whether you're in an
RTNL context or not (e.g., tg3_suspend would also need to grab it).

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <[EMAIL PROTECTED]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to