diff options
author | Rajesh Borundia <rajesh.borundia@qlogic.com> | 2014-08-04 11:51:17 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-08-05 16:23:26 -0700 |
commit | bf63014f108aaff49e4382b7adc7d0a2b6365744 (patch) | |
tree | 0744c8ac82eb3e415cde847308f68fe17b66ee2e /drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c | |
parent | a0eaf75c03712b491b7a840b5836c8f1e2a09277 (diff) | |
download | talos-obmc-linux-bf63014f108aaff49e4382b7adc7d0a2b6365744.tar.gz talos-obmc-linux-bf63014f108aaff49e4382b7adc7d0a2b6365744.zip |
qlcnic: Set driver version before registering netdev
o Earlier, set_drv_version was getting called after register_netdev.
This was resulting in a race between set_drv_version and FLR called
from open(). Moving set_drv_version before register_netdev avoids
the race.
o Log response code in error message on CDRP failure.
Signed-off-by: Rajesh Borundia <rajesh.borundia@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c')
-rw-r--r-- | drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c index 4fc186713b66..158e1d9f255f 100644 --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c @@ -2623,13 +2623,13 @@ qlcnic_probe(struct pci_dev *pdev, const struct pci_device_id *ent) if (err) goto err_out_disable_mbx_intr; + if (adapter->portnum == 0) + qlcnic_set_drv_version(adapter); + err = qlcnic_setup_netdev(adapter, netdev, pci_using_dac); if (err) goto err_out_disable_mbx_intr; - if (adapter->portnum == 0) - qlcnic_set_drv_version(adapter); - pci_set_drvdata(pdev, adapter); if (qlcnic_82xx_check(adapter)) |