aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tulip/timer.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/tulip/timer.c')
-rw-r--r--drivers/net/tulip/timer.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/drivers/net/tulip/timer.c b/drivers/net/tulip/timer.c
index f75bc5ecd73c..066e5d6bcbd8 100644
--- a/drivers/net/tulip/timer.c
+++ b/drivers/net/tulip/timer.c
@@ -18,13 +18,14 @@
18#include "tulip.h" 18#include "tulip.h"
19 19
20 20
21void tulip_timer(unsigned long data) 21void tulip_media_task(void *data)
22{ 22{
23 struct net_device *dev = (struct net_device *)data; 23 struct net_device *dev = data;
24 struct tulip_private *tp = netdev_priv(dev); 24 struct tulip_private *tp = netdev_priv(dev);
25 void __iomem *ioaddr = tp->base_addr; 25 void __iomem *ioaddr = tp->base_addr;
26 u32 csr12 = ioread32(ioaddr + CSR12); 26 u32 csr12 = ioread32(ioaddr + CSR12);
27 int next_tick = 2*HZ; 27 int next_tick = 2*HZ;
28 unsigned long flags;
28 29
29 if (tulip_debug > 2) { 30 if (tulip_debug > 2) {
30 printk(KERN_DEBUG "%s: Media selection tick, %s, status %8.8x mode" 31 printk(KERN_DEBUG "%s: Media selection tick, %s, status %8.8x mode"
@@ -126,6 +127,15 @@ void tulip_timer(unsigned long data)
126 } 127 }
127 break; 128 break;
128 } 129 }
130
131
132 spin_lock_irqsave(&tp->lock, flags);
133 if (tp->timeout_recovery) {
134 tulip_tx_timeout_complete(tp, ioaddr);
135 tp->timeout_recovery = 0;
136 }
137 spin_unlock_irqrestore(&tp->lock, flags);
138
129 /* mod_timer synchronizes us with potential add_timer calls 139 /* mod_timer synchronizes us with potential add_timer calls
130 * from interrupts. 140 * from interrupts.
131 */ 141 */