mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/7] drm/bridge: cdns-dsi: Fix the color-shift issue
@ 2024-05-11 15:30 Aradhya Bhatia
  2024-05-11 15:30 ` [PATCH 1/7] drm/tidss: Add CRTC mode_fixup Aradhya Bhatia
                   ` (6 more replies)
  0 siblings, 7 replies; 22+ messages in thread
From: Aradhya Bhatia @ 2024-05-11 15:30 UTC (permalink / raw)
  To: Tomi Valkeinen, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Jyri Sarha, Thomas Zimmermann,
	David Airlie, Daniel Vetter
  Cc: DRI Development List, Linux Kernel List, Sam Ravnborg,
	Thierry Reding, Kieran Bingham, Boris Brezillon, Nishanth Menon,
	Vignesh Raghavendra, Praneeth Bajjuri, Udit Kumar,
	Devarsh Thakkar, Jayesh Choudhary, Jai Luthra, Aradhya Bhatia

Hello all,

This series provides some crucial fixes and improvements for the Cadence's DSI
TX (cdns-dsi) controller found commonly in Texas Instruments' J7 family of SoCs
as well as in AM62P.

The cdns-dsi bridge consumes the crtc_* timing parameters for programming the
timing parameters. A patch has been added in tidss to make sure the crtc_*
timings get populated.

It further adds support for "early_enable" and "late_disable" DRM bridge hooks.
These hooks are same as the existing "(pre_)enable" and "(post_)disable" hooks,
except that the early_enable hook gets called before the CRTC is even enabled in
the display pipeline and the late_disable hook gets called after the CRTC is
disabled.
The cdns-dsi controller requires to be enabled before the previous entity
enables its stream[0]. It's a strict requirement which, if not followed, causes
the colors to "shift" on the display. Since the previous entity is TIDSS in this
case, which gets enabled via the tidss_crtc hooks, early_enable/late_disable API
in the cdns-dsi bridge is the way to solve the issue.
The early_enable/late_disable APIs also help with the OLDI TXes available on the
AM62/AM62P SoCs, which will be a part of separate series.

This spec also requires the Clock and Data Lanes be ready before the DSI TX
enables its stream[0]. A patch has been added to make the code wait for that to
happen. Going ahead with further DSI (and DSS configuration), while the lanes
are not ready, has been found as another reason for shift in colors.

All these patches have been tested on TI's vendor tree kernel with more devices,
but for the mainline, these patches have been tested with J721E based
BeagleboneAI64 along with a RaspberryPi 7" DSI panel. The extra patches can be
found in the "next_dsi_finals-v1-test_rpi" branch of my github fork[1] for
anyone who would like to test them.

Thanks,
Aradhya


[0]: Section 12.6.5.7.3: Start-up Procesure [For DSI TX controller]
     in TDA4VM Technical Reference Manual https://www.ti.com/lit/zip/spruil1

[1]: https://github.com/aradhya07/linux-ab/tree/next_dsi_finals-v1-test_rpi


Aradhya Bhatia (7):
  drm/tidss: Add CRTC mode_fixup
  drm/bridge: cdns-dsi: Fix minor bugs
  drm/bridge: cdns-dsi: Wait for Clk and Data Lanes to be ready
  drm/bridge: cdns-dsi: Reset the DCS write FIFO
  drm/bridge: cdns-dsi: Support atomic bridge APIs
  drm/bridge: Introduce early_enable and late disable
  drm/bridge: cdns-dsi: Implement early_enable and late_disable

 .../gpu/drm/bridge/cadence/cdns-dsi-core.c    | 91 ++++++++++++++-----
 drivers/gpu/drm/drm_atomic_helper.c           | 67 ++++++++++++++
 drivers/gpu/drm/drm_bridge.c                  | 84 +++++++++++++++++
 drivers/gpu/drm/tidss/tidss_crtc.c            | 11 +++
 include/drm/drm_bridge.h                      | 73 +++++++++++++++
 5 files changed, 303 insertions(+), 23 deletions(-)


base-commit: 75fa778d74b786a1608d55d655d42b480a6fa8bd
-- 
2.34.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2024-05-30  9:44 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-11 15:30 [PATCH 0/7] drm/bridge: cdns-dsi: Fix the color-shift issue Aradhya Bhatia
2024-05-11 15:30 ` [PATCH 1/7] drm/tidss: Add CRTC mode_fixup Aradhya Bhatia
2024-05-16  8:10   ` Maxime Ripard
2024-05-16 11:03     ` Aradhya Bhatia
2024-05-21 13:18       ` Maxime Ripard
2024-05-30  9:39         ` Aradhya Bhatia
2024-05-11 15:30 ` [PATCH 2/7] drm/bridge: cdns-dsi: Fix minor bugs Aradhya Bhatia
2024-05-16  8:11   ` Maxime Ripard
2024-05-16  9:41     ` Aradhya Bhatia
2024-05-11 15:30 ` [PATCH 3/7] drm/bridge: cdns-dsi: Wait for Clk and Data Lanes to be ready Aradhya Bhatia
2024-05-22 10:23   ` [EXTERNAL] " Dominik Haller
2024-05-11 15:30 ` [PATCH 4/7] drm/bridge: cdns-dsi: Reset the DCS write FIFO Aradhya Bhatia
2024-05-11 15:30 ` [PATCH 5/7] drm/bridge: cdns-dsi: Support atomic bridge APIs Aradhya Bhatia
2024-05-21 20:20   ` Markus Elfring
2024-05-11 15:30 ` [PATCH 6/7] drm/bridge: Introduce early_enable and late disable Aradhya Bhatia
2024-05-16  8:22   ` Maxime Ripard
2024-05-16  9:40     ` Aradhya Bhatia
2024-05-21 13:15       ` Maxime Ripard
2024-05-24 11:08         ` Aradhya Bhatia
2024-05-28 11:43           ` Maxime Ripard
2024-05-30  9:43             ` Aradhya Bhatia
2024-05-11 15:30 ` [PATCH 7/7] drm/bridge: cdns-dsi: Implement early_enable and late_disable Aradhya Bhatia

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®