aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRon Mercer <ron.mercer@qlogic.com>2009-03-11 07:55:42 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-13 14:27:24 -0400
commit6612a6344aba8ba7b5af67cd006453bfedbb2967 (patch)
treed923174dabd09639ef4d9032d179aa596ae692a9
parenta7a655f22c75f48e0afe8b86be03ecd70bd68b07 (diff)
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)
3163 3163
3164 ql_tx_ring_clean(qdev); 3164 ql_tx_ring_clean(qdev);
3165 3165
3166 /* Call netif_napi_del() from common point.
3167 */
3168 for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
3169 netif_napi_del(&qdev->rx_ring[i].napi);
3170
3166 spin_lock(&qdev->hw_lock); 3171 spin_lock(&qdev->hw_lock);
3167 status = ql_adapter_reset(qdev); 3172 status = ql_adapter_reset(qdev);
3168 if (status) 3173 if (status)
@@ -3867,7 +3872,7 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
3867{ 3872{
3868 struct net_device *ndev = pci_get_drvdata(pdev); 3873 struct net_device *ndev = pci_get_drvdata(pdev);
3869 struct ql_adapter *qdev = netdev_priv(ndev); 3874 struct ql_adapter *qdev = netdev_priv(ndev);
3870 int err, i; 3875 int err;
3871 3876
3872 netif_device_detach(ndev); 3877 netif_device_detach(ndev);
3873 3878
@@ -3877,9 +3882,6 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
3877 return err; 3882 return err;
3878 } 3883 }
3879 3884
3880 for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
3881 netif_napi_del(&qdev->rx_ring[i].napi);
3882
3883 err = pci_save_state(pdev); 3885 err = pci_save_state(pdev);
3884 if (err) 3886 if (err)
3885 return err; 3887 return err;