Signed-off-by: Mark Zhang <markz@xxxxxxxxxx> --- drivers/gpu/drm/panel/panel-sharp-lq101r1sx01.c | 26 +++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/drivers/gpu/drm/panel/panel-sharp-lq101r1sx01.c b/drivers/gpu/drm/panel/panel-sharp-lq101r1sx01.c index 654575607864..a0a7c80f23d6 100644 --- a/drivers/gpu/drm/panel/panel-sharp-lq101r1sx01.c +++ b/drivers/gpu/drm/panel/panel-sharp-lq101r1sx01.c @@ -90,6 +90,18 @@ static __maybe_unused int sharp_panel_read(struct sharp_panel *sharp, return err; } +static int sharp_panel_idle(struct drm_panel *panel) +{ + struct sharp_panel *sharp = to_sharp_panel(panel); + int err = 0; + + err = mipi_dsi_dcs_enter_idle_mode(sharp->link1); + if (err < 0) + dev_err(panel->dev, "failed to enter idle: %d\n", err); + + return err; +} + static int sharp_panel_disable(struct drm_panel *panel) { struct sharp_panel *sharp = to_sharp_panel(panel); @@ -168,6 +180,18 @@ static int sharp_setup_symmetrical_split(struct mipi_dsi_device *left, return 0; } +static int sharp_panel_busy(struct drm_panel *panel) +{ + struct sharp_panel *sharp = to_sharp_panel(panel); + int err = 0; + + err = mipi_dsi_dcs_exit_idle_mode(sharp->link1); + if (err < 0) + dev_err(panel->dev, "failed to exit idle: %d\n", err); + + return err; +} + static int sharp_panel_prepare(struct drm_panel *panel) { struct sharp_panel *sharp = to_sharp_panel(panel); @@ -324,6 +348,8 @@ static int sharp_panel_get_modes(struct drm_panel *panel) } static const struct drm_panel_funcs sharp_panel_funcs = { + .idle = sharp_panel_idle, + .busy = sharp_panel_busy, .disable = sharp_panel_disable, .unprepare = sharp_panel_unprepare, .prepare = sharp_panel_prepare, -- 2.1.4 _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/dri-devel