video/fbdev/wm8505fb: Delete an error message for a failed memory allocation in wm850...
authorMarkus Elfring <elfring@users.sourceforge.net>
Fri, 29 Dec 2017 18:48:43 +0000 (19:48 +0100)
committerBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Fri, 29 Dec 2017 18:48:43 +0000 (19:48 +0100)
Omit an extra message for a memory allocation failure in this function
(please note that there can be only one wm8505fb device in the system).

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Cc: Tony Prisk <linux@prisktech.co.nz>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
drivers/video/fbdev/wm8505fb.c

index 253ffe9baab2b7a5515b8237d81379f41f0ce394..8f0d5379861d1e038e530ed0e2e36b5a2b5e363e 100644 (file)
@@ -276,10 +276,8 @@ static int wm8505fb_probe(struct platform_device *pdev)
 
        fbi = devm_kzalloc(&pdev->dev, sizeof(struct wm8505fb_info) +
                        sizeof(u32) * 16, GFP_KERNEL);
-       if (!fbi) {
-               dev_err(&pdev->dev, "Failed to initialize framebuffer device\n");
+       if (!fbi)
                return -ENOMEM;
-       }
 
        strcpy(fbi->fb.fix.id, DRIVER_NAME);