Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1732165

[PATCH 4/8] [media] ttusb_dec: Delete an error message for a failed memory allocation in ttusb_dec_probe()

From SF Markus Elfring <elfring@users.sourceforge.net>
Newsgroups linux.kernel
Subject [PATCH 4/8] [media] ttusb_dec: Delete an error message for a failed memory allocation in ttusb_dec_probe()
Date 2017-09-14 12:40 +0200
Message-ID <upzIR-3Oe-17@gated-at.bofh.it> (permalink)
References <upzIR-3Oe-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Markus Elfring <elfring@users.sourceforge.net>
Date: Wed, 13 Sep 2017 20:10:39 +0200

Omit an extra message for a memory allocation failure in this function.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
 drivers/media/usb/ttusb-dec/ttusb_dec.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/media/usb/ttusb-dec/ttusb_dec.c b/drivers/media/usb/ttusb-dec/ttusb_dec.c
index 76070da3b7c7..26d637684b30 100644
--- a/drivers/media/usb/ttusb-dec/ttusb_dec.c
+++ b/drivers/media/usb/ttusb-dec/ttusb_dec.c
@@ -1659,10 +1659,8 @@ static int ttusb_dec_probe(struct usb_interface *intf,
 	udev = interface_to_usbdev(intf);
 
 	dec = kzalloc(sizeof(*dec), GFP_KERNEL);
-	if (!dec) {
-		printk("%s: couldn't allocate memory.\n", __func__);
+	if (!dec)
 		return -ENOMEM;
-	}
 
 	usb_set_intfdata(intf, (void *)dec);
 
-- 
2.14.1

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH 4/8] [media] ttusb_dec: Delete an error message for a failed  memory allocation in ttusb_dec_probe() SF Markus Elfring <elfring@users.sourceforge.net> - 2017-09-14 12:40 +0200

csiph-web