summaryrefslogtreecommitdiffstats
path: root/drivers/media/pci/meye
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2017-08-28 11:46:57 +0200
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2017-09-23 14:19:55 +0200
commitc38e8657a471e9af42b86009e5d3085031b41fda (patch)
treeb2bb818ff8b099ee5237da0ab3b9db680b520a0b /drivers/media/pci/meye
parentmedia: tc358743: add CEC support (diff)
downloadlinux-c38e8657a471e9af42b86009e5d3085031b41fda.tar.xz
linux-c38e8657a471e9af42b86009e5d3085031b41fda.zip
media: drivers: delete error messages for failed memory allocation
Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. [mchehab@s-opensource.com: fold several similar patches into one] Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/pci/meye')
-rw-r--r--drivers/media/pci/meye/meye.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/drivers/media/pci/meye/meye.c b/drivers/media/pci/meye/meye.c
index 49e047e4a81e..af9cd02fac0c 100644
--- a/drivers/media/pci/meye/meye.c
+++ b/drivers/media/pci/meye/meye.c
@@ -1626,23 +1626,18 @@ static int meye_probe(struct pci_dev *pcidev, const struct pci_device_id *ent)
meye.mchip_dev = pcidev;
meye.grab_temp = vmalloc(MCHIP_NB_PAGES_MJPEG * PAGE_SIZE);
- if (!meye.grab_temp) {
- v4l2_err(v4l2_dev, "grab buffer allocation failed\n");
+ if (!meye.grab_temp)
goto outvmalloc;
- }
spin_lock_init(&meye.grabq_lock);
if (kfifo_alloc(&meye.grabq, sizeof(int) * MEYE_MAX_BUFNBRS,
- GFP_KERNEL)) {
- v4l2_err(v4l2_dev, "fifo allocation failed\n");
+ GFP_KERNEL))
goto outkfifoalloc1;
- }
+
spin_lock_init(&meye.doneq_lock);
if (kfifo_alloc(&meye.doneq, sizeof(int) * MEYE_MAX_BUFNBRS,
- GFP_KERNEL)) {
- v4l2_err(v4l2_dev, "fifo allocation failed\n");
+ GFP_KERNEL))
goto outkfifoalloc2;
- }
meye.vdev = meye_template;
meye.vdev.v4l2_dev = &meye.v4l2_dev;