public inbox for linux-rockchip@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH v7 0/3] Add HDMI audio on the rk3588 SoC
@ 2025-02-17 21:47 Detlev Casanova
  2025-02-17 21:47 ` [PATCH v7 1/3] drm/bridge: synopsys: Add audio support for dw-hdmi-qp Detlev Casanova
                   ` (5 more replies)
  0 siblings, 6 replies; 17+ messages in thread
From: Detlev Casanova @ 2025-02-17 21:47 UTC (permalink / raw)
  To: linux-kernel
  Cc: Algea Cao, Heiko Stuebner, Geert Uytterhoeven, dri-devel,
	Niklas Cassel, Laurent Pinchart, Andrzej Hajda, kernel,
	David Airlie, Dragan Simic, Simona Vetter, Rob Herring,
	Detlev Casanova, Robert Foss, Sebastian Reichel, Jernej Skrabec,
	Sugar Zhang, linux-rockchip, Chen-Yu Tsai, FUKAUMI Naoki,
	devicetree, Conor Dooley, Jonas Karlman, Maarten Lankhorst,
	Maxime Ripard, Dmitry Baryshkov, Johan Jonker, linux-arm-kernel,
	Neil Armstrong, Alexey Charkov, Thomas Zimmermann,
	Krzysztof Kozlowski

To support HDMI audio on the rk3588 based devices, the generic HDMI
Codec framework is used in the dw-hdmi-qp DRM bridge driver.

The implementation is mainly based on the downstream driver, ported to the
generic HDMI Codec framework [1] recently merged in the master branch.
The parameters computation has been kept as is and the data stored in the
dw_hdmi_qp struct as been cleaned up.

The table for the N values has been edited to reflect N recommended values
as well as CTS recommended values.

The downstream kernel also implements a machine driver for HDMI audio but
it is doing exactly what the simple-audio-card driver does, so use that
instead in the RK3588 SoC device tree.

This adds HDMI audio support for both HDMI TX ports.

*** Dependencies ***

Based on Linus' master branch, but also needs Cristian's dts patches for HDMI1
support [2], which depends on Heiko's patchset for
phy-rockchip-samsung-hdptx [3]. Patches will apply without [3], but HDMI will
not work (at all).

[1]: https://lore.kernel.org/all/20241224-drm-bridge-hdmi-connector-v10-0-dc89577cd438@linaro.org
[2]: https://lore.kernel.org/linux-rockchip/20241211-rk3588-hdmi1-v2-0-02cdca22ff68@collabora.com
[3]: https://lore.kernel.org/lkml/20241206103401.1780416-3-heiko@sntech.de/

Changes since v6:
 - Fix arguments alignement (checkpatch --strict warnings)
 - Add hdmi1 audio support too
 - Move hdmi0_sound node under hdmi0_out_con

Changes since v5:
 - Simplify audio math computation for N
 - Move hdmi0-sound node up with other address-less nodes

Changes since v4:
 - Moved hdmi0_audio node the rk3588-base.dtsi
 - Enable hdmi0_audio in rk3588-rock-5b.dts

Changes since v3:
 - Renamed function to start with dw_hdmi_qp

Changes since v2:
 - Also clear the audio infoframe
 - Write AUDI_CONTENTS0 to its default value in case it gets overwritten.
 - Store tmds_char_rate in the dw_hdmi_qp struct in atomic_enable
 - Clear tmds_char_rate in atomic_disable and only write registers when
   tmds_char_rate is not 0.
 - Do not use connector_state duplicates

Changes since v1:
 - Remove useless audio_mutex (was used downstream for multiple drivers access
   to audio functions)
 - Let hdmi_codec build and setup audio infoframes
 - Only access audio registers when connector is connected
 - Rebased on master branch

Detlev Casanova (2):
  arm64: dts: rockchip: Add HDMI audio outputs for rk3588 SoC
  arm64: dts: rockchip: Enable HDMI audio outputs for Rock 5B

Sugar Zhang (1):
  drm/bridge: synopsys: Add audio support for dw-hdmi-qp

 arch/arm64/boot/dts/rockchip/rk3588-base.dtsi |  17 +
 .../arm64/boot/dts/rockchip/rk3588-extra.dtsi |  17 +
 .../boot/dts/rockchip/rk3588-rock-5b.dts      |  16 +
 drivers/gpu/drm/bridge/synopsys/dw-hdmi-qp.c  | 489 ++++++++++++++++++
 4 files changed, 539 insertions(+)

-- 
2.48.1


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

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

end of thread, other threads:[~2025-03-01 18:28 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-17 21:47 [PATCH v7 0/3] Add HDMI audio on the rk3588 SoC Detlev Casanova
2025-02-17 21:47 ` [PATCH v7 1/3] drm/bridge: synopsys: Add audio support for dw-hdmi-qp Detlev Casanova
2025-02-17 21:47 ` [PATCH v7 2/3] arm64: dts: rockchip: Add HDMI audio outputs for rk3588 SoC Detlev Casanova
2025-02-17 21:47 ` [PATCH v7 3/3] arm64: dts: rockchip: Enable HDMI audio outputs for Rock 5B Detlev Casanova
2025-02-20 11:16 ` [PATCH v7 0/3] Add HDMI audio on the rk3588 SoC Piotr Oniszczuk
2025-02-20 17:03   ` Detlev Casanova
2025-02-20 18:31     ` Piotr Oniszczuk
2025-02-21 11:42       ` Piotr Oniszczuk
2025-02-21 14:43         ` Detlev Casanova
2025-02-25  1:03           ` Kuninori Morimoto
2025-02-25  6:16             ` Kuninori Morimoto
2025-02-25 14:58               ` Detlev Casanova
2025-02-26  1:14                 ` Kuninori Morimoto
2025-03-01  9:11                 ` Piotr Oniszczuk
2025-03-01 18:27                   ` Heiko Stübner
2025-02-27 10:55 ` (subset) " Heiko Stuebner
2025-02-27 13:37 ` Heiko Stuebner

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