mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 23:20:51 +07:00
[media] media: pci: meye: set error code on failures
The value of return variable ret is 0 on some error paths, for example, when pci_resource_start() returns a NULL pointer. 0 means no error in this context, which is contrary to the fact. This patch fixes the bug. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=189011 Signed-off-by: Pan Bian <bianpan2016@163.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
This commit is contained in:
parent
d54a90c4c1
commit
2ce899423c
@ -1659,6 +1659,7 @@ static int meye_probe(struct pci_dev *pcidev, const struct pci_device_id *ent)
|
||||
goto outenabledev;
|
||||
}
|
||||
|
||||
ret = -EIO;
|
||||
mchip_adr = pci_resource_start(meye.mchip_dev,0);
|
||||
if (!mchip_adr) {
|
||||
v4l2_err(v4l2_dev, "meye: mchip has no device base address\n");
|
||||
|
Loading…
Reference in New Issue
Block a user