backlight: max8925_bl: Fix error handling path
Properly unregister a previously registered backlight device object in error handling of max8925_backlight_probe. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
This commit is contained in:
Родитель
beb0a43f39
Коммит
146e10a8c4
|
@ -162,6 +162,7 @@ static int __devinit max8925_backlight_probe(struct platform_device *pdev)
|
||||||
backlight_update_status(bl);
|
backlight_update_status(bl);
|
||||||
return 0;
|
return 0;
|
||||||
out:
|
out:
|
||||||
|
backlight_device_unregister(bl);
|
||||||
kfree(data);
|
kfree(data);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче