aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/e100.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/net/e100.c b/drivers/net/e100.c
index 1b68dd5a49b6..0f2837ebaab8 100644
--- a/drivers/net/e100.c
+++ b/drivers/net/e100.c
@@ -539,6 +539,7 @@ struct nic {
539 struct timer_list watchdog; 539 struct timer_list watchdog;
540 struct timer_list blink_timer; 540 struct timer_list blink_timer;
541 struct mii_if_info mii; 541 struct mii_if_info mii;
542 struct work_struct tx_timeout_task;
542 enum loopback loopback; 543 enum loopback loopback;
543 544
544 struct mem *mem; 545 struct mem *mem;
@@ -1716,6 +1717,15 @@ static void e100_tx_timeout(struct net_device *netdev)
1716{ 1717{
1717 struct nic *nic = netdev_priv(netdev); 1718 struct nic *nic = netdev_priv(netdev);
1718 1719
1720 /* Reset outside of interrupt context, to avoid request_irq
1721 * in interrupt context */
1722 schedule_work(&nic->tx_timeout_task);
1723}
1724
1725static void e100_tx_timeout_task(struct net_device *netdev)
1726{
1727 struct nic *nic = netdev_priv(netdev);
1728
1719 DPRINTK(TX_ERR, DEBUG, "scb.status=0x%02X\n", 1729 DPRINTK(TX_ERR, DEBUG, "scb.status=0x%02X\n",
1720 readb(&nic->csr->scb.status)); 1730 readb(&nic->csr->scb.status));
1721 e100_down(netdev_priv(netdev)); 1731 e100_down(netdev_priv(netdev));
@@ -2240,6 +2250,9 @@ static int __devinit e100_probe(struct pci_dev *pdev,
2240 nic->blink_timer.function = e100_blink_led; 2250 nic->blink_timer.function = e100_blink_led;
2241 nic->blink_timer.data = (unsigned long)nic; 2251 nic->blink_timer.data = (unsigned long)nic;
2242 2252
2253 INIT_WORK(&nic->tx_timeout_task,
2254 (void (*)(void *))e100_tx_timeout_task, netdev);
2255
2243 if((err = e100_alloc(nic))) { 2256 if((err = e100_alloc(nic))) {
2244 DPRINTK(PROBE, ERR, "Cannot alloc driver memory, aborting.\n"); 2257 DPRINTK(PROBE, ERR, "Cannot alloc driver memory, aborting.\n");
2245 goto err_out_iounmap; 2258 goto err_out_iounmap;