summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRon Mercer <ron.mercer@qlogic.com>2009-03-11 11:55:42 +0000
committerDavid S. Miller <davem@davemloft.net>2009-03-13 11:27:24 -0700
commit6612a6344aba8ba7b5af67cd006453bfedbb2967 (patch)
treed923174dabd09639ef4d9032d179aa596ae692a9
parenta7a655f22c75f48e0afe8b86be03ecd70bd68b07 (diff)
downloadblackbird-op-linux-6612a6344aba8ba7b5af67cd006453bfedbb2967.tar.gz
blackbird-op-linux-6612a6344aba8ba7b5af67cd006453bfedbb2967.zip
qlge: bugfix: Move netif_napi_del() to common call point.
Moving netif_napi_del() up the call chain so it will get called from all exit points. Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/qlge/qlge_main.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c
index 54d54ea03d49..00c37c0f8a90 100644
--- a/drivers/net/qlge/qlge_main.c
+++ b/drivers/net/qlge/qlge_main.c
@@ -3163,6 +3163,11 @@ static int ql_adapter_down(struct ql_adapter *qdev)
ql_tx_ring_clean(qdev);
+ /* Call netif_napi_del() from common point.
+ */
+ for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
+ netif_napi_del(&qdev->rx_ring[i].napi);
+
spin_lock(&qdev->hw_lock);
status = ql_adapter_reset(qdev);
if (status)
@@ -3867,7 +3872,7 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
{
struct net_device *ndev = pci_get_drvdata(pdev);
struct ql_adapter *qdev = netdev_priv(ndev);
- int err, i;
+ int err;
netif_device_detach(ndev);
@@ -3877,9 +3882,6 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
return err;
}
- for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
- netif_napi_del(&qdev->rx_ring[i].napi);
-
err = pci_save_state(pdev);
if (err)
return err;
OpenPOWER on IntegriCloud