Skip to content

Commit

Permalink
qlcnic: fix default operating state of interface
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Amit Kumar Salecha authored and David S. Miller committed Jun 24, 2011
1 parent 5f6ec29 commit c55ad8e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/qlcnic/qlcnic_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -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");
Expand Down Expand Up @@ -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;
Expand Down

0 comments on commit c55ad8e

Please sign in to comment.