summaryrefslogtreecommitdiffstats
path: root/drivers/video/backlight/88pm860x_bl.c
diff options
context:
space:
mode:
authorMartlin Ettl <ettl.martin@gmx.de>2012-07-05 17:58:46 +0100
committerJiri Kosina <jkosina@suse.cz>2012-07-09 16:20:11 +0200
commit9ea3c498962bc63748e92c31c874169ab0726324 (patch)
tree7cf0ecae900eb80fc06371300fbbf304fa01861b /drivers/video/backlight/88pm860x_bl.c
parent59f91e5dd0504dc0ebfaa0b6f3a55e6931f96266 (diff)
downloadlinux-9ea3c498962bc63748e92c31c874169ab0726324.tar.gz
linux-9ea3c498962bc63748e92c31c874169ab0726324.tar.bz2
linux-9ea3c498962bc63748e92c31c874169ab0726324.zip
backlight: fix memory leak on obscure error path
Dredged out of bugzilla Reported-by: Martlin Ettl <ettl.martin@gmx.de> Resolves-bug: https://bugzilla.kernel.org/show_bug.cgi?id=15492 Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/video/backlight/88pm860x_bl.c')
-rw-r--r--drivers/video/backlight/88pm860x_bl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/video/backlight/88pm860x_bl.c b/drivers/video/backlight/88pm860x_bl.c
index f49181c73113..f75da8758adc 100644
--- a/drivers/video/backlight/88pm860x_bl.c
+++ b/drivers/video/backlight/88pm860x_bl.c
@@ -228,6 +228,7 @@ static int pm860x_backlight_probe(struct platform_device *pdev)
data->port = pdata->flags;
if (data->port < 0) {
dev_err(&pdev->dev, "wrong platform data is assigned");
+ kfree(data);
return -EINVAL;
}