Commit ef0e3c26 authored by Henrik Kretzschmar's avatar Henrik Kretzschmar Committed by Mauro Carvalho Chehab

V4L/DVB (8748): V4L: fix return value of meye probe callback

The return vaule of the probe function should return -ENOMEM instead
of -EBUSY if video_device_alloc() fails.
Signed-off-by: default avatarHenrik Kretzschmar <henne@nachtwindheim.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent eda9e4e2
...@@ -1779,6 +1779,7 @@ static int __devinit meye_probe(struct pci_dev *pcidev, ...@@ -1779,6 +1779,7 @@ static int __devinit meye_probe(struct pci_dev *pcidev,
goto outnotdev; goto outnotdev;
} }
ret = -ENOMEM;
meye.mchip_dev = pcidev; meye.mchip_dev = pcidev;
meye.video_dev = video_device_alloc(); meye.video_dev = video_device_alloc();
if (!meye.video_dev) { if (!meye.video_dev) {
...@@ -1786,7 +1787,6 @@ static int __devinit meye_probe(struct pci_dev *pcidev, ...@@ -1786,7 +1787,6 @@ static int __devinit meye_probe(struct pci_dev *pcidev,
goto outnotdev; goto outnotdev;
} }
ret = -ENOMEM;
meye.grab_temp = vmalloc(MCHIP_NB_PAGES_MJPEG * PAGE_SIZE); meye.grab_temp = vmalloc(MCHIP_NB_PAGES_MJPEG * PAGE_SIZE);
if (!meye.grab_temp) { if (!meye.grab_temp) {
printk(KERN_ERR "meye: grab buffer allocation failed\n"); printk(KERN_ERR "meye: grab buffer allocation failed\n");
......
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