Skip to content

Commit

Permalink
[PATCH] lockdep: annotate 8390.c disable_irq()
Browse files Browse the repository at this point in the history
8390.c knows that ei_local->page_lock can only be used by an irq context that
it disabled - and can hence take the ->page_lock without disabling hardirqs.
Teach lockdep about this.

Has no effect on non-lockdep kernels.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: Arjan van de Ven <arjan@linux.intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Ingo Molnar authored and Linus Torvalds committed Jul 3, 2006
1 parent 933a2ef commit e745165
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/8390.c
Original file line number Diff line number Diff line change
Expand Up @@ -249,15 +249,15 @@ void ei_tx_timeout(struct net_device *dev)

/* Ugly but a reset can be slow, yet must be protected */

disable_irq_nosync(dev->irq);
disable_irq_nosync_lockdep(dev->irq);
spin_lock(&ei_local->page_lock);

/* Try to restart the card. Perhaps the user has fixed something. */
ei_reset_8390(dev);
NS8390_init(dev, 1);

spin_unlock(&ei_local->page_lock);
enable_irq(dev->irq);
enable_irq_lockdep(dev->irq);
netif_wake_queue(dev);
}

Expand Down

0 comments on commit e745165

Please sign in to comment.