mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v3 0/8] ASoC: SDCA: Qualcomm Tambora (WCD9378) SDCA codec support
@ 2026-09-15 16:56 Srinivas Kandagatla
  2026-09-15 16:56 ` [PATCH v3 1/8] ASoC: SDCA: allow building without ACPI Srinivas Kandagatla
                   ` (7 more replies)
  0 siblings, 8 replies; 16+ messages in thread
From: Srinivas Kandagatla @ 2026-09-15 16:56 UTC (permalink / raw)
  To: Mark Brown
  Cc: Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
	Pierre-Louis Bossart, Charles Keepax, Maciej Strozek, Bard Liao,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, patches,
	linux-sound, linux-arm-msm, devicetree, linux-kernel,
	Srinivas Kandagatla

This series extends the SDCA class driver to work on DT / non-ACPI
platforms via a codec-provided static topology, and adds the Qualcomm
WCD9378 (Tambora) codec as the first user driven in SDCA / compute
mode. Tested on the Snapdragon X2 Elite Glymur CRD.

Patches 1-6 extend the SDCA class helpers:

  - Kconfig gate to build the class without ACPI enabled.
  - PM helpers keyed on a codec-embedded struct sdca_class_drv, so
    codec drivers can build their own dev_pm_ops.
  - Class SoundWire probe/remove exposed as library functions
    callable from codec-specific SDW slave drivers.
  - class_ops with a populate_function hook so codec drivers can
    supply the SDCA function payload from static tables on DT /
    non-DisCo platforms.
  - Class function driver registers SDCA_FUNCTION_TYPE_SIMPLE_JACK,
    and resolves sound-dai cells by entity index.
  - sdca_apply_default_control_classifiers() applies the same
    is_volatile / has_reset flags that the DisCo/ACPI parser would.

Note:
None of these are functional changes in sdca core, all of these are
helper functions to allow non-ACPI users to use sdca core.

Patches 7-8 add the WCD9378 SDCA / compute-mode codec:

  - dt-bindings for the SoundWire slave in compute mode.
  - Codec driver split across wcd9378-sdw.c (SoundWire plumbing)
    and wcd9378-sdca.c (SDCA topology + class_ops), sharing a
    wcd9378-sdca.h header. A future mobile-mode driver can plug
    into the same module by adding its own files.

Testing: HPH playback and headset-mic capture confirmed on the
Snapdragon X2 Elite Glymur CRD. Will test it on Lenovo T14s. 

Jack detection is not wired up in this series.

Changes since v2 [1]:

  - Un-export sdca_class_pm_ops and per-op wrappers; keep them
    static and let codecs compose their own dev_pm_ops.
  - Drop the exported sdca_class_read_prop() helper; codecs
    open-code the four lines locally.
  - class_function: check the codec-provided ops hook first, fall
    back to sdca_parse_function() only when a firmware node is
    present.
  - Rename sdca_class_hw_ops to sdca_class_ops; populate_function
    does no bus I/O.
  - Drop the hw_init callback; codec users moved bring-up into
    their own SoundWire probe.
  - wcd9378-sdca: MIC_BIAS fixed at 2.75 V via the init_table;
    drop stale qcom,micbias2-microvolt reference from the commit
    message.
  - Rebased on b-next-20260911.

[1] https://lore.kernel.org/all/20260907083727.733705-1-srinivas.kandagatla@oss.qualcomm.com/

Srinivas Kandagatla (8):
  ASoC: SDCA: allow building without ACPI
  ASoC: SDCA: export PM helpers keyed on sdca_class_drv
  ASoC: SDCA: expose class SoundWire probe/remove as library
  ASoC: SDCA: add class_ops with populate_function
  ASoC: SDCA: class_function: xlate sound-dai cell by entity index
  ASoC: SDCA: add sdca_apply_default_control_classifiers() helper
  dt-bindings: sound: qcom: add Tambora WCD9378 SDCA codec
  ASoC: codecs: add Qualcomm Tambora (WCD9378) SDCA codec

 .../bindings/sound/qcom,wcd9378-sdw.yaml      |   91 ++
 include/sound/sdca.h                          |   23 +-
 include/sound/sdca_class.h                    |   70 ++
 include/sound/sdca_function.h                 |    2 +
 sound/soc/codecs/Kconfig                      |   11 +
 sound/soc/codecs/Makefile                     |    2 +
 sound/soc/codecs/wcd9378-sdca.c               | 1005 +++++++++++++++++
 sound/soc/codecs/wcd9378-sdca.h               |   20 +
 sound/soc/codecs/wcd9378-sdw.c                |   52 +
 sound/soc/sdca/Kconfig                        |    6 +-
 sound/soc/sdca/sdca_class.c                   |  148 ++-
 sound/soc/sdca/sdca_class.h                   |   35 -
 sound/soc/sdca/sdca_class_function.c          |   45 +-
 sound/soc/sdca/sdca_device.c                  |    4 +
 sound/soc/sdca/sdca_functions.c               |   31 +
 15 files changed, 1474 insertions(+), 71 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/sound/qcom,wcd9378-sdw.yaml
 create mode 100644 include/sound/sdca_class.h
 create mode 100644 sound/soc/codecs/wcd9378-sdca.c
 create mode 100644 sound/soc/codecs/wcd9378-sdca.h
 create mode 100644 sound/soc/codecs/wcd9378-sdw.c
 delete mode 100644 sound/soc/sdca/sdca_class.h

--
2.53.0


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

end of thread, other threads:[~2026-09-16 16:30 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-15 16:56 [PATCH v3 0/8] ASoC: SDCA: Qualcomm Tambora (WCD9378) SDCA codec support Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 1/8] ASoC: SDCA: allow building without ACPI Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 2/8] ASoC: SDCA: export PM helpers keyed on sdca_class_drv Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 3/8] ASoC: SDCA: expose class SoundWire probe/remove as library Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 4/8] ASoC: SDCA: add class_ops with populate_function Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 5/8] ASoC: SDCA: class_function: xlate sound-dai cell by entity index Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 6/8] ASoC: SDCA: add sdca_apply_default_control_classifiers() helper Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 7/8] dt-bindings: sound: qcom: add Tambora WCD9378 SDCA codec Srinivas Kandagatla
2026-09-15 21:57   ` Rob Herring (Arm)
2026-09-16  6:53   ` Krzysztof Kozlowski
2026-09-16 16:30     ` Srinivas Kandagatla
2026-09-15 16:56 ` [PATCH v3 8/8] ASoC: codecs: add Qualcomm Tambora (WCD9378) " Srinivas Kandagatla
2026-09-15 17:22   ` Uwe Kleine-König
2026-09-15 22:30     ` Srinivas Kandagatla
2026-09-15 18:46   ` Mark Brown
2026-09-15 20:55     ` Srinivas Kandagatla

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®