aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/qlcnic/qlcnic_main.c
diff options
context:
space:
mode:
authorAmit Kumar Salecha <amit.salecha@qlogic.com>2011-06-22 02:52:21 +0000
committerDavid S. Miller <davem@davemloft.net>2011-06-24 01:17:07 -0700
commitc55ad8e56b983f03589b38b4504b5d1f41161ff8 (patch)
tree3c89665e2aa76803010d37dfae47bf55ef419618 /drivers/net/qlcnic/qlcnic_main.c
parentqlcnic: fix initial number of msix entries in adapter. (diff)
downloadlinux-dev-c55ad8e56b983f03589b38b4504b5d1f41161ff8.tar.xz
linux-dev-c55ad8e56b983f03589b38b4504b5d1f41161ff8.zip
qlcnic: fix default operating state of interface
Currently interface shows status as RUNNING, even if there is no link. To fix this, netif_carrier_off should be called qlcnic_open(). Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r--drivers/net/qlcnic/qlcnic_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/qlcnic/qlcnic_main.c b/drivers/net/qlcnic/qlcnic_main.c
index a050746a5129..5dcb853224c9 100644
--- a/drivers/net/qlcnic/qlcnic_main.c
+++ b/drivers/net/qlcnic/qlcnic_main.c
@@ -1485,8 +1485,6 @@ qlcnic_setup_netdev(struct qlcnic_adapter *adapter,
netdev->irq = adapter->msix_entries[0].vector;
- netif_carrier_off(netdev);
-
err = register_netdev(netdev);
if (err) {
dev_err(&pdev->dev, "failed to register net device\n");
@@ -1816,6 +1814,8 @@ static int qlcnic_open(struct net_device *netdev)
struct qlcnic_adapter *adapter = netdev_priv(netdev);
int err;
+ netif_carrier_off(netdev);
+
err = qlcnic_attach(adapter);
if (err)
return err;