MLK-17389: drm/panel: rm67191: Fix power on/off logic
authorRobert Chiras <robert.chiras@nxp.com>
Mon, 22 Jan 2018 08:16:03 +0000 (10:16 +0200)
committerNitin Garg <nitin.garg@nxp.com>
Tue, 20 Mar 2018 19:53:49 +0000 (14:53 -0500)
commit4ef2b3cf59705ec5953b6ca043985d9e1d44cc0e
tree88cb1a56837499d0643cefba6030ca5357e8718c
parent28508548c664d5b7663be2a182cd3105b6edbd2a
MLK-17389: drm/panel: rm67191: Fix power on/off logic

On remove, the panel driver was only calling rad_panel_disable, which
only updates the brightness. During a reboot, the panel may remain
powered which will cause the whole screen to be bright white (sometimes
flashing).
This patch also calls the rad_panel_unprepare, which puts the panel to
sleep and also sets the DSI_EN gpio to LOW (which is the proper power
off sequence).
While powering on the sleeps are too high, so reduce them according to
the sample driver received from vendor.
Also, fixed the reading of display-timings property: this property is
optional, but will dump some error messages into the console log by
directly calling of_get_videomode() when this property is missing. To
avoid the error messages, first check if we really have this property
first.

Signed-off-by: Robert Chiras <robert.chiras@nxp.com>
drivers/gpu/drm/panel/panel-raydium-rm67191.c