linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: amd: rt5682: fix soundwire dependencies
@ 2020-05-27 13:41 Arnd Bergmann
  2020-05-27 13:47 ` Mark Brown
  0 siblings, 1 reply; 3+ messages in thread
From: Arnd Bergmann @ 2020-05-27 13:41 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Akshu Agrawal, Arnd Bergmann
  Cc: Jaroslav Kysela, Takashi Iwai, Vijendar Mukunda, alsa-devel,
	linux-kernel

A built-in SND_SOC_AMD_RV_RT5682_MACH driver can not select
SND_SOC_RT5682 when that is linking against a modular soundwire
layer:

WARNING: unmet direct dependencies detected for SND_SOC_RT5682
  Depends on [m]: SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && (I2C [=y] || SOUNDWIRE [=m]) && (SOUNDWIRE [=m] || !SOUNDWIRE [=m]) && (I2C [=y] || !I2C [=y])
  Selected by [y]:
  - SND_SOC_AMD_RV_RT5682_MACH [=y] && SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && SND_SOC_AMD_ACP3x [=y] && I2C [=y] && CROS_EC [=y]
  Selected by [m]:
  - SND_SOC_RT5682_SDW [=m] && SOUND [=y] && !UML && SND [=y] && SND_SOC [=y] && SOUNDWIRE [=m] && (I2C [=y] || !I2C [=y])

This one is a bit awkward because the AMD driver itself has no interest
in soundwire, but I could not come up with a cleaner workaround so far.

Maybe the SND_SOC_RT5682 driver itself can be reworked so that
the common part depends on neither soundwire nor i2c and the two
bus specific options can be loadable modules when the common part
is built-in.

Fixes: 6b8e4e7db3cd ("ASoC: amd: Add machine driver for Raven based platform")
Fixes: fd443a20c2f0 ("ASoC: rt5682: fix I2C/Soundwire dependencies")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 sound/soc/amd/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/amd/Kconfig b/sound/soc/amd/Kconfig
index 77ffdb41bee5..878cf97b050e 100644
--- a/sound/soc/amd/Kconfig
+++ b/sound/soc/amd/Kconfig
@@ -34,6 +34,7 @@ config SND_SOC_AMD_RV_RT5682_MACH
 	select SND_SOC_CROS_EC_CODEC
 	select I2C_CROS_EC_TUNNEL
 	depends on SND_SOC_AMD_ACP3x && I2C && CROS_EC
+	depends on SOUNDWIRE || !SOUNDWIRE
 	help
 	 This option enables machine driver for RT5682 and MAX9835.
 
-- 
2.26.2


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

* Re: [PATCH] ASoC: amd: rt5682: fix soundwire dependencies
  2020-05-27 13:41 [PATCH] ASoC: amd: rt5682: fix soundwire dependencies Arnd Bergmann
@ 2020-05-27 13:47 ` Mark Brown
  2020-05-27 15:59   ` Arnd Bergmann
  0 siblings, 1 reply; 3+ messages in thread
From: Mark Brown @ 2020-05-27 13:47 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Liam Girdwood, Akshu Agrawal, Jaroslav Kysela, Takashi Iwai,
	Vijendar Mukunda, alsa-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 301 bytes --]

On Wed, May 27, 2020 at 03:41:26PM +0200, Arnd Bergmann wrote:

> Maybe the SND_SOC_RT5682 driver itself can be reworked so that
> the common part depends on neither soundwire nor i2c and the two
> bus specific options can be loadable modules when the common part
> is built-in.

Yes, please do that.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

* Re: [PATCH] ASoC: amd: rt5682: fix soundwire dependencies
  2020-05-27 13:47 ` Mark Brown
@ 2020-05-27 15:59   ` Arnd Bergmann
  0 siblings, 0 replies; 3+ messages in thread
From: Arnd Bergmann @ 2020-05-27 15:59 UTC (permalink / raw)
  To: Mark Brown
  Cc: Liam Girdwood, Akshu Agrawal, Jaroslav Kysela, Takashi Iwai,
	Vijendar Mukunda, ALSA Development Mailing List, linux-kernel

On Wed, May 27, 2020 at 3:47 PM Mark Brown <broonie@kernel.org> wrote:
>
> On Wed, May 27, 2020 at 03:41:26PM +0200, Arnd Bergmann wrote:
>
> > Maybe the SND_SOC_RT5682 driver itself can be reworked so that
> > the common part depends on neither soundwire nor i2c and the two
> > bus specific options can be loadable modules when the common part
> > is built-in.
>
> Yes, please do that.

It took me longer than I thought it would, but I have a patch now.
I'll send it after it passes more randconfig builds to ensure it covers
all corner cases.

      Arnd

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

end of thread, other threads:[~2020-05-27 15:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-27 13:41 [PATCH] ASoC: amd: rt5682: fix soundwire dependencies Arnd Bergmann
2020-05-27 13:47 ` Mark Brown
2020-05-27 15:59   ` Arnd Bergmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).