drm/panel: simple: fix loader protect

Change-Id: I5b9bb5e35cc74389b6500f85c48dfed911c21181
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
Signed-off-by: Guochun Huang <hero.huang@rock-chips.com>
This commit is contained in:
Wyon Bi
2018-04-16 10:28:21 +08:00
committed by Tao Huang
parent 37a6461623
commit 63fcb9a771

View File

@@ -547,6 +547,7 @@ static int panel_simple_regulator_disable(struct drm_panel *panel)
static int panel_simple_loader_protect(struct drm_panel *panel, bool on)
{
struct panel_simple *p = to_panel_simple(panel);
int err;
if (on) {
@@ -556,8 +557,11 @@ static int panel_simple_loader_protect(struct drm_panel *panel, bool on)
err);
return err;
}
p->prepared = true;
p->enabled = true;
} else {
panel_simple_regulator_disable(panel);
/* do nothing */
}
return 0;