Commit 7824acd9 authored by Yongjian Xu's avatar Yongjian Xu Committed by David S. Miller

qlcnic: Fix return value in qlcnic_probe()

If the check of adapter fails and goes into the 'else' branch, the
return value 'err' should not still be zero.
Signed-off-by: default avatarYongjian Xu <xuyongjiande@gmail.com>
Acked-by: default avatarShahed Shaikh <shahed.shaikh@qlogic.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 0f113b81
......@@ -2605,6 +2605,7 @@ qlcnic_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
} else {
dev_err(&pdev->dev,
"%s: failed. Please Reboot\n", __func__);
err = -ENODEV;
goto err_out_free_hw;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment