Skip to contentSkip to conversation

ASoC: SOF: Intel: add build support for SoundWire

PATCH RESEND In review Bard Liao 4 participants 4 messages Aug 20, 2020

Subsystems (3)
lore
Share & tools
lore

Bard Liao

author maintainer
#0 lore raw

PATCH RESEND 1/1 ASoC: SOF: Intel: add build support for SoundWire

From: Pierre-Louis Bossart <[email protected]>

Select SoundWire capabilities on newer Intel platforms, starting with CannonLake/CoffeeLake/CometLake.

As done for HDaudio, the SoundWire link is an opt-in capability. We explicitly test for ACPI to avoid warnings on unmet dependencies on the SoundWire side.

---
 sound/soc/sof/intel/Kconfig | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)
sound/soc/sof/intel/Kconfig +29 -0
index 3aaf25e4f766..f644010cc568 100644
@@ -166,6 +166,7 @@ config SND_SOC_SOF_CANNONLAKE_SUPPORT
 config SND_SOC_SOF_CANNONLAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -181,6 +182,7 @@ config SND_SOC_SOF_COFFEELAKE_SUPPORT
 config SND_SOC_SOF_COFFEELAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -196,6 +198,7 @@ config SND_SOC_SOF_ICELAKE_SUPPORT
 config SND_SOC_SOF_ICELAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -203,6 +206,7 @@ config SND_SOC_SOF_ICELAKE
 config SND_SOC_SOF_COMETLAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -229,6 +233,7 @@ config SND_SOC_SOF_TIGERLAKE_SUPPORT
 config SND_SOC_SOF_TIGERLAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -244,6 +249,7 @@ config SND_SOC_SOF_ELKHARTLAKE_SUPPORT
 config SND_SOC_SOF_ELKHARTLAKE
 	tristate
 	select SND_SOC_SOF_HDA_COMMON
+	select SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
 	help
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
@@ -329,6 +335,29 @@ config SND_SOC_SOF_HDA
 	  This option is not user-selectable but automagically handled by
 	  'select' statements at a higher level
 
+config SND_SOC_SOF_INTEL_SOUNDWIRE_LINK
+	bool "SOF support for SoundWire"
+	depends on SOUNDWIRE && ACPI
+	help
+	  This adds support for SoundWire with Sound Open Firmware
+		  for Intel(R) platforms.
+	  Say Y if you want to enable SoundWire links with SOF.
+	  If unsure select "N".
+
+config SND_SOC_SOF_INTEL_SOUNDWIRE_LINK_BASELINE
+	tristate
+	select SND_SOC_SOF_INTEL_SOUNDWIRE if SND_SOC_SOF_INTEL_SOUNDWIRE_LINK
+	help
+	  This option is not user-selectable but automagically handled by
+	  'select' statements at a higher level
+
+config SND_SOC_SOF_INTEL_SOUNDWIRE
+	tristate
+	select SOUNDWIRE_INTEL
+	help
+	  This option is not user-selectable but automagically handled by
+	  'select' statements at a higher level
+
 endif ## SND_SOC_SOF_INTEL_PCI
 
 endif ## SND_SOC_SOF_INTEL_TOPLEVEL
Signature · 1 line
2.17.1
maintainer
#1 lore raw

Dne 19. 08. 20 v 14:44 Bard Liao napsal(a):

Quoted 8 lines

From: Pierre-Louis Bossart <[email protected]>

Select SoundWire capabilities on newer Intel platforms, starting with CannonLake/CoffeeLake/CometLake.

As done for HDaudio, the SoundWire link is an opt-in capability. We explicitly test for ACPI to avoid warnings on unmet dependencies on the SoundWire side.

Can we enable SDW/SOF also for the 5.8 stable kernel or some vital pieces are missing in 5.8?

If I am not wrong, it's a 5.9 patch, right?

Thank you,
Jaroslav

Signature · 2 lines
Jaroslav Kysela <[email protected]>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
#2 lore raw
Quoted 5 lines

Can we enable SDW/SOF also for the 5.8 stable kernel or some vital pieces are missing in 5.8?

If I am not wrong, it's a 5.9 patch, right?

I just tried with v5.8 stable and there are compilation issues due to missed dependencies between ASoC and SoundWire subsystems.

sound/soc/intel/boards/sof_sdw.c: In function ‘sdw_startup’:
sound/soc/intel/boards/sof_sdw.c:162:9: error: implicit declaration of function ‘sdw_startup_stream’; did you mean ‘sdw_enable_stream’? [-Werror=implicit-function-declaration]

  162 |  return sdw_startup_stream(substream);
      |         ^~~~~~~~~~~~~~~~~~
      |         sdw_enable_stream
sound/soc/intel/boards/sof_sdw.c: In function ‘sdw_shutdown’:
sound/soc/intel/boards/sof_sdw.c:167:2: error: implicit declaration of function ‘sdw_shutdown_stream’; did you mean ‘sdw_shutdown’? [-Werror=implicit-function-declaration]
  167 |  sdw_shutdown_stream(substream);
      |  ^~~~~~~~~~~~~~~~~~~
      |  sdw_shutdown

I also tried with plain vanilla v5.9-rc1, and I didn't see any issues. I think it'd be good to have this patch (and the other one with the namespace) be added to v5.9 indeed.

That said, this just adds compilation/build support. We are still missing PM patches that were merged by Vinod earlier this week, we submitted the multi-link patches and the last batch will be the bandwidth allocation.

UCM files + PulseAudio changes were shared earlier, so at this point 5.10 should hopefully be the first intercept where SoundWire 'just works'(tm) across kernel/userspace.

maintainer
#3 lore raw
In reply to Bard Liao
Quoted 6 lines · Bard Liao

Select SoundWire capabilities on newer Intel platforms, starting with CannonLake/CoffeeLake/CometLake.

As done for HDaudio, the SoundWire link is an opt-in capability. We explicitly test for ACPI to avoid warnings on unmet dependencies on the SoundWire side.

Applied to

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: SOF: Intel: add build support for SoundWire

      commit: 82cb71d68c22137099a0d34f1ecf00aecc951d6b

All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying to this mail.

Thanks,
Mark