mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/3] ASoC: xlnx: spdif: switch to the common clock framework
@ 2026-11-17  8:57 Dhanunjanrao Katta
  2026-11-17  8:57 ` [PATCH 1/3] ASoC: dt-bindings: xlnx,spdif: describe AXI4-Stream and audio clocks Dhanunjanrao Katta
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Dhanunjanrao Katta @ 2026-11-17  8:57 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood, linux-sound
  Cc: Vincenzo Frascino, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Jaroslav Kysela, Takashi Iwai, Michal Simek,
	devicetree, linux-kernel, linux-arm-kernel, git,
	Dhanunjanrao Katta

The Xilinx SPDIF/AES3 IP is fed by three clocks, but the binding
described only two of them and the driver requested only one. The audio
clock frequency was instead passed as a plain number in the custom
"xlnx,aud_clk_i" property, and the driver relied on the firmware to
leave the audio and AXI4-Stream clocks running.

This series describes the third clock, requests the audio and
AXI4-Stream clocks through the common clock framework, and reads the
audio rate with clk_get_rate() so that the SPDIF divider follows the
rate actually in effect. A tidy-up of the register defines and of the
divider values comes first so that the clock change is easy to read.

Patch 1 describes the AXI4-Stream clock and selects its name from the IP
mode. The minimum clock count stays at two and "xlnx,aud_clk_i" is kept
as deprecated rather than removed, so that device trees written against
the earlier binding keep validating. "xlnx,spdif-mode" becomes required,
because the conditional that picks the clock name keys on it and would
otherwise also match when the property is absent.

Patch 2 names each register-field define after the register it belongs
to, prefixes the remaining driver constants, and replaces the bare
clock-divider values with an enum.

Patch 3 requests the audio clock and the mode-specific AXI4-Stream clock
through the common clock framework. The stream clock is requested as
optional so that existing two-clock device trees still probe, and a zero
audio rate is now rejected with a diagnostic instead of falling through
the divider switch. "xlnx,aud_clk_i" is no longer read.

Dhanunjanrao Katta (3):
  ASoC: dt-bindings: xlnx,spdif: describe AXI4-Stream and audio clocks
  ASoC: xlnx: spdif: namespace register macros and use a divider enum
  ASoC: xlnx: spdif: get clocks through the common clock framework

 .../devicetree/bindings/sound/xlnx,spdif.yaml |  54 +++++++--
 sound/soc/xilinx/xlnx_spdif.c                 | 108 +++++++++++-------
 2 files changed, 113 insertions(+), 49 deletions(-)


base-commit: 7cd6b1fd8f9c1fcb1da1b761d502649f50b9800f
-- 
2.34.1


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

end of thread, other threads:[~2026-11-17 10:06 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-17  8:57 [PATCH 0/3] ASoC: xlnx: spdif: switch to the common clock framework Dhanunjanrao Katta
2026-11-17  8:57 ` [PATCH 1/3] ASoC: dt-bindings: xlnx,spdif: describe AXI4-Stream and audio clocks Dhanunjanrao Katta
2026-11-17 10:06   ` Krzysztof Kozlowski
2026-11-17  8:57 ` [PATCH 2/3] ASoC: xlnx: spdif: namespace register macros and use a divider enum Dhanunjanrao Katta
2026-11-17  8:57 ` [PATCH 3/3] ASoC: xlnx: spdif: get clocks through the common clock framework Dhanunjanrao Katta

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®