aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cxgb3
diff options
context:
space:
mode:
authorDivy Le Ray <divy@chelsio.com>2007-11-16 14:21:50 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:04:07 -0500
commit67d92ab765a29cd18674b2b87e9f931782a245e3 (patch)
tree18771d60acd2808d35b6c579c2957cffd28691a7 /drivers/net/cxgb3
parent678771d6f5242573fe4eb9fc14f7479646d52cf6 (diff)
cxgb3 - Fix resources release.
Remove sysfs entries before unregistering the net devices. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/cxgb3')
-rw-r--r--drivers/net/cxgb3/cxgb3_main.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c
index d92da8fe4a50..9d14652ffdc3 100644
--- a/drivers/net/cxgb3/cxgb3_main.c
+++ b/drivers/net/cxgb3/cxgb3_main.c
@@ -2585,10 +2585,6 @@ static void __devexit remove_one(struct pci_dev *pdev)
2585 sysfs_remove_group(&adapter->port[0]->dev.kobj, 2585 sysfs_remove_group(&adapter->port[0]->dev.kobj,
2586 &cxgb3_attr_group); 2586 &cxgb3_attr_group);
2587 2587
2588 for_each_port(adapter, i)
2589 if (test_bit(i, &adapter->registered_device_map))
2590 unregister_netdev(adapter->port[i]);
2591
2592 if (is_offload(adapter)) { 2588 if (is_offload(adapter)) {
2593 cxgb3_adapter_unofld(adapter); 2589 cxgb3_adapter_unofld(adapter);
2594 if (test_bit(OFFLOAD_DEVMAP_BIT, 2590 if (test_bit(OFFLOAD_DEVMAP_BIT,
@@ -2596,6 +2592,10 @@ static void __devexit remove_one(struct pci_dev *pdev)
2596 offload_close(&adapter->tdev); 2592 offload_close(&adapter->tdev);
2597 } 2593 }
2598 2594
2595 for_each_port(adapter, i)
2596 if (test_bit(i, &adapter->registered_device_map))
2597 unregister_netdev(adapter->port[i]);
2598
2599 t3_free_sge_resources(adapter); 2599 t3_free_sge_resources(adapter);
2600 cxgb_disable_msi(adapter); 2600 cxgb_disable_msi(adapter);
2601 2601