diff options
author | Francois Romieu <romieu@fr.zoreil.com> | 2006-12-18 01:03:15 +0300 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-12-27 00:24:11 +0300 |
commit | d15e9c4d9a75702b30e00cdf95c71c88e3f3f51e (patch) | |
tree | e7ba1469eac6f732a7d2b9debc7713d8173dc0a2 /drivers/net/b44.c | |
parent | 79f3d3996f06ee339c6f173e573826eccd3914ab (diff) | |
download | linux-d15e9c4d9a75702b30e00cdf95c71c88e3f3f51e.tar.xz |
netpoll: drivers must not enable IRQ unconditionally in their NAPI handler
net/core/netpoll.c::netpoll_send_skb() calls the poll handler when
it is available. As netconsole can be used from almost any context,
IRQ must not be enabled blindly in the NAPI handler of a driver which
supports netpoll.
b57bd06655a028aba7b92e1c19c2093e7fcfb341 fixed the issue for the
8139too.c driver.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/b44.c')
-rw-r--r-- | drivers/net/b44.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/b44.c b/drivers/net/b44.c index 474a4e3438db..5eb2ec68393f 100644 --- a/drivers/net/b44.c +++ b/drivers/net/b44.c @@ -879,12 +879,14 @@ static int b44_poll(struct net_device *netdev, int *budget) } if (bp->istat & ISTAT_ERRORS) { - spin_lock_irq(&bp->lock); + unsigned long flags; + + spin_lock_irqsave(&bp->lock, flags); b44_halt(bp); b44_init_rings(bp); b44_init_hw(bp, 1); netif_wake_queue(bp->dev); - spin_unlock_irq(&bp->lock); + spin_unlock_irqrestore(&bp->lock, flags); done = 1; } |