mirror of
https://github.com/torvalds/linux.git
synced 2026-07-28 10:09:10 +02:00
drm/bridge: tc358768: Add LP mode command support
Currently the driver ignores MIPI_DSI_MODE_LPM and always uses HS mode. Add code to enable HS mode in pre_enable() only if MIPI_DSI_MODE_LPM is not set, and always enable HS mode in enable() for video transmission. Tested-by: João Paulo Gonçalves <joao.goncalves@toradex.com> # Toradex Verdin AM62 Reviewed-by: Francesco Dolcini <francesco.dolcini@toradex.com> Link: https://patch.msgid.link/20260311-tc358768-v2-5-e75a99131bd5@ideasonboard.com Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
This commit is contained in:
parent
b8eed179f0
commit
2c7d48c75c
|
|
@ -1091,7 +1091,8 @@ static void tc358768_bridge_atomic_pre_enable(struct drm_bridge *bridge,
|
|||
/* Configure DSI_Control register */
|
||||
val = (dsi_dev->lanes - 1) << 1;
|
||||
|
||||
val |= TC358768_DSI_CONTROL_TXMD;
|
||||
if (!(dsi_dev->mode_flags & MIPI_DSI_MODE_LPM))
|
||||
val |= TC358768_DSI_CONTROL_TXMD;
|
||||
|
||||
if (!(dsi_dev->mode_flags & MIPI_DSI_CLOCK_NON_CONTINUOUS))
|
||||
val |= TC358768_DSI_CONTROL_HSCKMD;
|
||||
|
|
@ -1123,6 +1124,11 @@ static void tc358768_bridge_atomic_enable(struct drm_bridge *bridge,
|
|||
return;
|
||||
}
|
||||
|
||||
/* Enable HS mode for video TX */
|
||||
tc358768_confw_update_bits(priv, TC358768_DSI_CONTROL,
|
||||
TC358768_DSI_CONTROL_TXMD,
|
||||
TC358768_DSI_CONTROL_TXMD);
|
||||
|
||||
/* clear FrmStop and RstPtr */
|
||||
tc358768_update_bits(priv, TC358768_PP_MISC, 0x3 << 14, 0);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user