From 3e70b256a6b6a549bdbbd5d70895ff8147c7cf7d Mon Sep 17 00:00:00 2001 From: Markus Elfring Date: Tue, 29 Aug 2017 07:40:07 -0300 Subject: [media] media: imon: delete an error message for a failed memory allocation Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: Sean Young Signed-off-by: Mauro Carvalho Chehab --- drivers/media/rc/imon.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers/media/rc') diff --git a/drivers/media/rc/imon.c b/drivers/media/rc/imon.c index b93dc6e..188cf1b 100644 --- a/drivers/media/rc/imon.c +++ b/drivers/media/rc/imon.c @@ -2311,10 +2311,9 @@ static struct imon_context *imon_init_intf0(struct usb_interface *intf, int ret = -ENOMEM; ictx = kzalloc(sizeof(struct imon_context), GFP_KERNEL); - if (!ictx) { - dev_err(dev, "%s: kzalloc failed for context", __func__); + if (!ictx) goto exit; - } + rx_urb = usb_alloc_urb(0, GFP_KERNEL); if (!rx_urb) goto rx_urb_alloc_failed; -- cgit v1.1