diff mbox series

[v2] ASoC: atmel: ATMEL drivers depend on HAS_DMA

Message ID 20210628211158.30273-1-rdunlap@infradead.org
State New
Headers show
Series [v2] ASoC: atmel: ATMEL drivers depend on HAS_DMA | expand

Commit Message

Randy Dunlap June 28, 2021, 9:11 p.m. UTC
On a config (such as arch/sh/) which does not set HAS_DMA when MMU
is not set, several ATMEL ASoC drivers select symbols that cause
kconfig warnings. There is one "depends on HAS_DMA" here but several
more are needed to prevent kconfig warnings since 'select' does not
recognize any dependencies.

Fix the following kconfig warnings:

WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_PDC
  Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
  Selected by [m]:
  - SND_ATMEL_SOC_SSC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m]
  - SND_ATMEL_SOC_SSC_PDC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]

WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_PDC
  Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
  Selected by [m]:
  - SND_AT91_SOC_SAM9G20_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]

WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC
  Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
  Selected by [m]:
  - SND_ATMEL_SOC_SSC_DMA [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]

WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_DMA
  Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
  Selected by [m]:
  - SND_ATMEL_SOC_WM8904 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && I2C [=m]
  - SND_AT91_SOC_SAM9X5_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]

Fixes: 3951e4aae2ce ("ASoC: atmel-pcm: dma support based on pcm dmaengine")
Fixes: 18291410557f ("ASoC: atmel: enable SOC_SSC_PDC and SOC_SSC_DMA in Kconfig")
Fixes: 061981ff8cc8 ("ASoC: atmel: properly select dma driver state")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Codrin Ciubotariu <codrin.ciubotariu@microchip.com>
Cc: alsa-devel@alsa-project.org
Cc: Liam Girdwood <lgirdwood@gmail.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com>
---
v2: rebase & resend;
    drop Cc: to Bo Shen <voice.shen@atmel.com> # bounced

 sound/soc/atmel/Kconfig |    6 ++++++
 1 file changed, 6 insertions(+)

Comments

Codrin Ciubotariu July 7, 2021, 4:40 p.m. UTC | #1
On 29.06.2021 00:11, Randy Dunlap wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe

> 

> On a config (such as arch/sh/) which does not set HAS_DMA when MMU

> is not set, several ATMEL ASoC drivers select symbols that cause

> kconfig warnings. There is one "depends on HAS_DMA" here but several

> more are needed to prevent kconfig warnings since 'select' does not

> recognize any dependencies.

> 

> Fix the following kconfig warnings:

> 

> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_PDC

>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]

>    Selected by [m]:

>    - SND_ATMEL_SOC_SSC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m]

>    - SND_ATMEL_SOC_SSC_PDC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]

> 

> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_PDC

>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]

>    Selected by [m]:

>    - SND_AT91_SOC_SAM9G20_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]

> 

> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC

>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]

>    Selected by [m]:

>    - SND_ATMEL_SOC_SSC_DMA [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]

> 

> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_DMA

>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]

>    Selected by [m]:

>    - SND_ATMEL_SOC_WM8904 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && I2C [=m]

>    - SND_AT91_SOC_SAM9X5_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]


Hi Randy,

Sorry about my delayed response. I think it would be better to just 
remove HAS_DMA from SND_ATMEL_SOC_PDC, since it seems to compile fine 
without it. This should fix all the problems...

Thanks and best regards,
Codrin
Alexandre Belloni July 7, 2021, 7:42 p.m. UTC | #2
On 07/07/2021 16:40:34+0000, Codrin.Ciubotariu@microchip.com wrote:
> On 29.06.2021 00:11, Randy Dunlap wrote:
> > EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> > 
> > On a config (such as arch/sh/) which does not set HAS_DMA when MMU
> > is not set, several ATMEL ASoC drivers select symbols that cause
> > kconfig warnings. There is one "depends on HAS_DMA" here but several
> > more are needed to prevent kconfig warnings since 'select' does not
> > recognize any dependencies.
> > 
> > Fix the following kconfig warnings:
> > 
> > WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_PDC
> >    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
> >    Selected by [m]:
> >    - SND_ATMEL_SOC_SSC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m]
> >    - SND_ATMEL_SOC_SSC_PDC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]
> > 
> > WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_PDC
> >    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
> >    Selected by [m]:
> >    - SND_AT91_SOC_SAM9G20_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]
> > 
> > WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC
> >    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
> >    Selected by [m]:
> >    - SND_ATMEL_SOC_SSC_DMA [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]
> > 
> > WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_DMA
> >    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
> >    Selected by [m]:
> >    - SND_ATMEL_SOC_WM8904 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && I2C [=m]
> >    - SND_AT91_SOC_SAM9X5_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]
> 
> Hi Randy,
> 
> Sorry about my delayed response. I think it would be better to just 
> remove HAS_DMA from SND_ATMEL_SOC_PDC, since it seems to compile fine 
> without it. This should fix all the problems...
> 

I bet this is correct since m32r is gone.
Randy Dunlap July 7, 2021, 9:43 p.m. UTC | #3
On 7/7/21 12:42 PM, Alexandre Belloni wrote:
> On 07/07/2021 16:40:34+0000, Codrin.Ciubotariu@microchip.com wrote:
>> On 29.06.2021 00:11, Randy Dunlap wrote:
>>> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>>>
>>> On a config (such as arch/sh/) which does not set HAS_DMA when MMU
>>> is not set, several ATMEL ASoC drivers select symbols that cause
>>> kconfig warnings. There is one "depends on HAS_DMA" here but several
>>> more are needed to prevent kconfig warnings since 'select' does not
>>> recognize any dependencies.
>>>
>>> Fix the following kconfig warnings:
>>>
>>> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_PDC
>>>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
>>>    Selected by [m]:
>>>    - SND_ATMEL_SOC_SSC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m]
>>>    - SND_ATMEL_SOC_SSC_PDC [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]
>>>
>>> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_PDC
>>>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
>>>    Selected by [m]:
>>>    - SND_AT91_SOC_SAM9G20_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]
>>>
>>> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC
>>>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && HAS_DMA [=n]
>>>    Selected by [m]:
>>>    - SND_ATMEL_SOC_SSC_DMA [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m]
>>>
>>> WARNING: unmet direct dependencies detected for SND_ATMEL_SOC_SSC_DMA
>>>    Depends on [n]: SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && ATMEL_SSC [=m] && HAS_DMA [=n]
>>>    Selected by [m]:
>>>    - SND_ATMEL_SOC_WM8904 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && I2C [=m]
>>>    - SND_AT91_SOC_SAM9X5_WM8731 [=m] && SOUND [=m] && !UML && SND [=m] && SND_SOC [=m] && SND_ATMEL_SOC [=m] && (ARCH_AT91 || COMPILE_TEST [=y]) && ATMEL_SSC [=m] && SND_SOC_I2C_AND_SPI [=m]
>>
>> Hi Randy,
>>
>> Sorry about my delayed response. I think it would be better to just 
>> remove HAS_DMA from SND_ATMEL_SOC_PDC, since it seems to compile fine 
>> without it. This should fix all the problems...
>>
> 
> I bet this is correct since m32r is gone.

Yes, that builds for me with no problems.
I'll submit that patch soon.

Thanks.
diff mbox series

Patch

--- linux-next-20210628.orig/sound/soc/atmel/Kconfig
+++ linux-next-20210628/sound/soc/atmel/Kconfig
@@ -19,12 +19,14 @@  config SND_ATMEL_SOC_DMA
 
 config SND_ATMEL_SOC_SSC
 	tristate
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_DMA
 	select SND_ATMEL_SOC_PDC
 
 config SND_ATMEL_SOC_SSC_PDC
 	tristate "SoC PCM DAI support for AT91 SSC controller using PDC"
 	depends on ATMEL_SSC
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_PDC
 	select SND_ATMEL_SOC_SSC
 	help
@@ -34,6 +36,7 @@  config SND_ATMEL_SOC_SSC_PDC
 config SND_ATMEL_SOC_SSC_DMA
 	tristate "SoC PCM DAI support for AT91 SSC controller using DMA"
 	depends on ATMEL_SSC
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_DMA
 	select SND_ATMEL_SOC_SSC
 	help
@@ -44,6 +47,7 @@  config SND_AT91_SOC_SAM9G20_WM8731
 	tristate "SoC Audio support for WM8731-based At91sam9g20 evaluation board"
 	depends on ARCH_AT91 || COMPILE_TEST
 	depends on ATMEL_SSC && SND_SOC_I2C_AND_SPI
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_SSC_PDC
 	select SND_SOC_WM8731
 	help
@@ -54,6 +58,7 @@  config SND_ATMEL_SOC_WM8904
 	tristate "Atmel ASoC driver for boards using WM8904 codec"
 	depends on ARCH_AT91 || COMPILE_TEST
 	depends on ATMEL_SSC && I2C
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_SSC_DMA
 	select SND_SOC_WM8904
 	help
@@ -64,6 +69,7 @@  config SND_AT91_SOC_SAM9X5_WM8731
 	tristate "SoC Audio support for WM8731-based at91sam9x5 board"
 	depends on ARCH_AT91 || COMPILE_TEST
 	depends on ATMEL_SSC && SND_SOC_I2C_AND_SPI
+	depends on HAS_DMA
 	select SND_ATMEL_SOC_SSC_DMA
 	select SND_SOC_WM8731
 	help