2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-21 03:33:59 +08:00

OMAPDSS: VENC: Check for errors from regulator_enable()

It is possible for regulator_enable() to fail and if it does fail that's
generally a bad sign for anything we try to do with the hardware afterwards
so check for and immediately return an error if regulator_enable() fails.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
This commit is contained in:
Mark Brown 2012-03-19 14:56:39 +00:00 committed by Tomi Valkeinen
parent 9c3d5eb71b
commit ec8741078d

View File

@ -443,7 +443,9 @@ static int venc_power_on(struct omap_dss_device *dssdev)
dispc_set_digit_size(dssdev->panel.timings.x_res,
dssdev->panel.timings.y_res/2);
regulator_enable(venc.vdda_dac_reg);
r = regulator_enable(venc.vdda_dac_reg);
if (r)
goto err;
if (dssdev->platform_enable)
dssdev->platform_enable(dssdev);