Skip to content

Commit

Permalink
qlcnic: Fix error code in probe
Browse files Browse the repository at this point in the history
[ Upstream commit 0d52848 ]

Return -EINVAL if we can't find the correct device.  Currently it
returns success.

Fixes: 1315918 ("qlcnic: 83xx base driver")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/X9nHbMqEyI/xPfGd@mwanda
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Dan Carpenter authored and gregkh committed Dec 30, 2020
1 parent c16e42c commit 372f06c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
Expand Up @@ -2509,6 +2509,7 @@ qlcnic_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
qlcnic_sriov_vf_register_map(ahw);
break;
default:
err = -EINVAL;
goto err_out_free_hw_res;
}

Expand Down

0 comments on commit 372f06c

Please sign in to comment.