diff options
author | David S. Miller <davem@davemloft.net> | 2008-06-13 23:52:39 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-06-13 23:52:39 -0400 |
commit | 4ae127d1b6c71f9240dd4245f240e6dd8fc98014 (patch) | |
tree | b7aa27b3e0c655f4613fe2146cb57d7f69e421f6 /drivers/net/bnx2.c | |
parent | 875ec4333b99144e2589e900a0bcd2c25c757b27 (diff) | |
parent | 7775c9753b94fe429dc4323360d6502c95e0dd6e (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
drivers/net/smc911x.c
Diffstat (limited to 'drivers/net/bnx2.c')
-rw-r--r-- | drivers/net/bnx2.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c index b32d22762b9b..2c52d2c7c495 100644 --- a/drivers/net/bnx2.c +++ b/drivers/net/bnx2.c | |||
@@ -5664,14 +5664,12 @@ bnx2_reset_task(struct work_struct *work) | |||
5664 | if (!netif_running(bp->dev)) | 5664 | if (!netif_running(bp->dev)) |
5665 | return; | 5665 | return; |
5666 | 5666 | ||
5667 | bp->in_reset_task = 1; | ||
5668 | bnx2_netif_stop(bp); | 5667 | bnx2_netif_stop(bp); |
5669 | 5668 | ||
5670 | bnx2_init_nic(bp, 1); | 5669 | bnx2_init_nic(bp, 1); |
5671 | 5670 | ||
5672 | atomic_set(&bp->intr_sem, 1); | 5671 | atomic_set(&bp->intr_sem, 1); |
5673 | bnx2_netif_start(bp); | 5672 | bnx2_netif_start(bp); |
5674 | bp->in_reset_task = 0; | ||
5675 | } | 5673 | } |
5676 | 5674 | ||
5677 | static void | 5675 | static void |
@@ -5847,12 +5845,7 @@ bnx2_close(struct net_device *dev) | |||
5847 | struct bnx2 *bp = netdev_priv(dev); | 5845 | struct bnx2 *bp = netdev_priv(dev); |
5848 | u32 reset_code; | 5846 | u32 reset_code; |
5849 | 5847 | ||
5850 | /* Calling flush_scheduled_work() may deadlock because | 5848 | cancel_work_sync(&bp->reset_task); |
5851 | * linkwatch_event() may be on the workqueue and it will try to get | ||
5852 | * the rtnl_lock which we are holding. | ||
5853 | */ | ||
5854 | while (bp->in_reset_task) | ||
5855 | msleep(1); | ||
5856 | 5849 | ||
5857 | bnx2_disable_int_sync(bp); | 5850 | bnx2_disable_int_sync(bp); |
5858 | bnx2_napi_disable(bp); | 5851 | bnx2_napi_disable(bp); |