aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRon Mercer <ron.mercer@qlogic.com>2009-03-09 06:59:26 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-10 07:43:56 -0400
commit6b318cb36813d03dd20f80e63c37176a55edae30 (patch)
treeca65ede4be9fc06406c4c815e3b7053260820a71
parent39a28bc480bff0f778d043877aff2fd16ad5f769 (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 f7f104ab5ffb..ce826da6f165 100644
--- a/drivers/net/qlge/qlge_main.c
+++ b/drivers/net/qlge/qlge_main.c
@@ -3236,6 +3236,11 @@ static int ql_adapter_down(struct ql_adapter *qdev)
3236 3236
3237 ql_tx_ring_clean(qdev); 3237 ql_tx_ring_clean(qdev);
3238 3238
3239 /* Call netif_napi_del() from common point.
3240 */
3241 for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
3242 netif_napi_del(&qdev->rx_ring[i].napi);
3243
3239 ql_free_rx_buffers(qdev); 3244 ql_free_rx_buffers(qdev);
3240 spin_lock(&qdev->hw_lock); 3245 spin_lock(&qdev->hw_lock);
3241 status = ql_adapter_reset(qdev); 3246 status = ql_adapter_reset(qdev);
@@ -3964,7 +3969,7 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
3964{ 3969{
3965 struct net_device *ndev = pci_get_drvdata(pdev); 3970 struct net_device *ndev = pci_get_drvdata(pdev);
3966 struct ql_adapter *qdev = netdev_priv(ndev); 3971 struct ql_adapter *qdev = netdev_priv(ndev);
3967 int err, i; 3972 int err;
3968 3973
3969 netif_device_detach(ndev); 3974 netif_device_detach(ndev);
3970 3975
@@ -3974,9 +3979,6 @@ static int qlge_suspend(struct pci_dev *pdev, pm_message_t state)
3974 return err; 3979 return err;
3975 } 3980 }
3976 3981
3977 for (i = qdev->rss_ring_first_cq_id; i < qdev->rx_ring_count; i++)
3978 netif_napi_del(&qdev->rx_ring[i].napi);
3979
3980 err = pci_save_state(pdev); 3982 err = pci_save_state(pdev);
3981 if (err) 3983 if (err)
3982 return err; 3984 return err;