qlcnic: Fix error code in probe
[ Upstream commit 0d52848632a357948028eab67ff9b7cc0c12a0fb ]
Return -EINVAL if we can't find the correct device. Currently it
returns success.
Fixes: 13159183ec
("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>
This commit is contained in:

committed by
Greg Kroah-Hartman

parent
98c9b3aeff
commit
466587ce57
@@ -2492,6 +2492,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;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user