diff mbox

[4/5] radeon_backlight: Return directly after a failed kmalloc() in radeonfb_bl_init()

Message ID 3c7e74d9-0be1-cbfd-4070-d60904c55696@users.sourceforge.net (mailing list archive)
State New, archived
Headers show

Commit Message

SF Markus Elfring Nov. 27, 2017, 9:27 p.m. UTC
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Mon, 27 Nov 2017 21:50:28 +0100

Return directly after a call of the function "kmalloc" failed
at the beginning.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
 drivers/video/fbdev/aty/radeon_backlight.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/drivers/video/fbdev/aty/radeon_backlight.c b/drivers/video/fbdev/aty/radeon_backlight.c
index c5e0e3557cc2..7f7ed6f72ddb 100644
--- a/drivers/video/fbdev/aty/radeon_backlight.c
+++ b/drivers/video/fbdev/aty/radeon_backlight.c
@@ -145,7 +145,7 @@  void radeonfb_bl_init(struct radeonfb_info *rinfo)
 
 	pdata = kmalloc(sizeof(*pdata), GFP_KERNEL);
 	if (!pdata)
-		goto error;
+		return;
 
 	snprintf(name, sizeof(name), "radeonbl%d", rinfo->info->node);