Message ID | f92f41b1-d4fa-4ffa-8c19-af4eb0d2d8cf@users.sourceforge.net (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Sunday, January 07, 2018 12:58:47 PM SF Markus Elfring wrote: > From: Markus Elfring <elfring@users.sourceforge.net> > Date: Sun, 7 Jan 2018 12:34:22 +0100 > > 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 <elfring@users.sourceforge.net> Patch queued for 4.17, thanks. Best regards, -- Bartlomiej Zolnierkiewicz Samsung R&D Institute Poland Samsung Electronics
diff --git a/drivers/video/fbdev/stifb.c b/drivers/video/fbdev/stifb.c index 511a594889af..dec8efb4f256 100644 --- a/drivers/video/fbdev/stifb.c +++ b/drivers/video/fbdev/stifb.c @@ -1126,10 +1126,8 @@ static int __init stifb_init_fb(struct sti_struct *sti, int bpp_pref) int bpp, xres, yres; fb = kzalloc(sizeof(*fb), GFP_ATOMIC); - if (!fb) { - printk(KERN_ERR "stifb: Could not allocate stifb structure\n"); + if (!fb) return -ENOMEM; - } info = &fb->info;