mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-07 18:40:10 +00:00
drm: rp1: rp1-dsi: Don't enable clock until all lanes in stopstate
Ensure receiver has a chance to see all lanes static in LP11 state before the clock lane transitions to HS mode, rather than starting it immediately. Signed-off-by: Nick Hollinghurst <nick.hollinghurst@raspberrypi.com>
This commit is contained in:
@@ -1434,7 +1434,7 @@ void rp1dsi_dsi_setup(struct rp1_dsi *dsi, struct drm_display_mode const *mode)
|
|||||||
if (timeout == 0)
|
if (timeout == 0)
|
||||||
drm_err(dsi->drm, "RP1DSI: Time out waiting for PLL\n");
|
drm_err(dsi->drm, "RP1DSI: Time out waiting for PLL\n");
|
||||||
|
|
||||||
DSI_WRITE(DSI_LPCLK_CTRL, 0x1); /* configure the requesthsclk */
|
DSI_WRITE(DSI_LPCLK_CTRL, 0x0); /* clock off (start in LP11) */
|
||||||
DSI_WRITE(DSI_PHY_TST_CTRL0, 0x2);
|
DSI_WRITE(DSI_PHY_TST_CTRL0, 0x2);
|
||||||
DSI_WRITE(DSI_PCKHDL_CFG, 1 << 2); /* allow bus turnaround */
|
DSI_WRITE(DSI_PCKHDL_CFG, 1 << 2); /* allow bus turnaround */
|
||||||
DSI_WRITE(DSI_PWR_UP, 0x1); /* power up */
|
DSI_WRITE(DSI_PWR_UP, 0x1); /* power up */
|
||||||
@@ -1458,6 +1458,10 @@ void rp1dsi_dsi_setup(struct rp1_dsi *dsi, struct drm_display_mode const *mode)
|
|||||||
if (timeout == 0)
|
if (timeout == 0)
|
||||||
drm_err(dsi->drm, "RP1DSI: Time out waiting for lanes (%x %x)\n",
|
drm_err(dsi->drm, "RP1DSI: Time out waiting for lanes (%x %x)\n",
|
||||||
mask, DSI_READ(DSI_PHY_STATUS));
|
mask, DSI_READ(DSI_PHY_STATUS));
|
||||||
|
|
||||||
|
usleep_range(5, 10);
|
||||||
|
DSI_WRITE(DSI_LPCLK_CTRL, 0x1); /* continuous clock */
|
||||||
|
usleep_range(5, 10);
|
||||||
}
|
}
|
||||||
|
|
||||||
void rp1dsi_dsi_send(struct rp1_dsi *dsi, u32 hdr, int len, const u8 *buf)
|
void rp1dsi_dsi_send(struct rp1_dsi *dsi, u32 hdr, int len, const u8 *buf)
|
||||||
|
|||||||
Reference in New Issue
Block a user