ia64/xen-unstable
changeset 329:79e370880245
bitkeeper revision 1.146 (3e761a8bG8D0sHIrqHKpkx1hSuhB1A)
tg3.c:
Fix for new tg3 driver.
tg3.c:
Fix for new tg3 driver.
author | kaf24@scramble.cl.cam.ac.uk |
---|---|
date | Mon Mar 17 18:57:15 2003 +0000 (2003-03-17) |
parents | 47f6cdee5a9b |
children | 74c24fb522be dfa523958767 |
files | xen/drivers/net/tg3.c |
line diff
1.1 --- a/xen/drivers/net/tg3.c Mon Mar 17 18:25:34 2003 +0000 1.2 +++ b/xen/drivers/net/tg3.c Mon Mar 17 18:57:15 2003 +0000 1.3 @@ -2075,10 +2075,11 @@ static int tg3_poll(struct net_device *n 1.4 { 1.5 struct tg3 *tp = netdev->priv; 1.6 struct tg3_hw_status *sblk = tp->hw_status; 1.7 + int done; 1.8 +#ifdef NAPI 1.9 unsigned long flags; 1.10 - int done; 1.11 - 1.12 spin_lock_irqsave(&tp->lock, flags); 1.13 +#endif 1.14 1.15 /* handle link change and other phy events */ 1.16 if (!(tp->tg3_flags & 1.17 @@ -2098,7 +2099,9 @@ static int tg3_poll(struct net_device *n 1.18 spin_unlock(&tp->tx_lock); 1.19 } 1.20 1.21 +#ifdef NAPI 1.22 spin_unlock_irqrestore(&tp->lock, flags); 1.23 +#endif 1.24 1.25 /* run RX thread, within the bounds set by NAPI. 1.26 * All RX "locking" is done by ensuring outside