Commit 811174f4 authored by Dan Carpenter's avatar Dan Carpenter Committed by Tomi Valkeinen

OMAPDSS: pll: NULL dereference in error handling

The regulator_disable() doesn't accept NULL pointers.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
parent 1616cf01
...@@ -97,7 +97,8 @@ int dss_pll_enable(struct dss_pll *pll) ...@@ -97,7 +97,8 @@ int dss_pll_enable(struct dss_pll *pll)
return 0; return 0;
err_enable: err_enable:
regulator_disable(pll->regulator); if (pll->regulator)
regulator_disable(pll->regulator);
err_reg: err_reg:
clk_disable_unprepare(pll->clkin); clk_disable_unprepare(pll->clkin);
return r; return r;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment