]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
ASoC: ti: fix davinci_mcasp_probe dependencies
authorArnd Bergmann <arnd@arndb.de>
Mon, 4 Mar 2019 20:30:50 +0000 (21:30 +0100)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 13 Aug 2019 12:11:36 +0000 (14:11 +0200)
BugLink: https://bugs.launchpad.net/bugs/1837517
[ Upstream commit 7d7b25d05ef1c5a1a9320190e1eeb55534847558 ]

The SND_SOC_DAVINCI_MCASP driver can use either edma or sdma as
a back-end, and it takes the presence of the respective dma engine
drivers in the configuration as an indication to which ones should be
built. However, this is flawed in multiple ways:

- With CONFIG_TI_EDMA=m and CONFIG_SND_SOC_DAVINCI_MCASP=y,
  is enabled as =m, and we get a link error:
  sound/soc/ti/davinci-mcasp.o: In function `davinci_mcasp_probe':
  davinci-mcasp.c:(.text+0x930): undefined reference to `edma_pcm_platform_register'

- When CONFIG_SND_SOC_DAVINCI_MCASP=m has already been selected by
  another driver, the same link error appears even if CONFIG_TI_EDMA
  is disabled

There are possibly other issues here, but it seems that the only reasonable
solution is to always build both SND_SOC_TI_EDMA_PCM and
SND_SOC_TI_SDMA_PCM as a dependency here. Both are fairly small and
do not have any other compile-time dependencies, so the cost is
very small, and makes the configuration stage much more consistent.

Fixes: f2055e145f29 ("ASoC: ti: Merge davinci and omap directories")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
sound/soc/ti/Kconfig

index 4bf3c15d4e514edce7e22e4d8167d8cba3681127..ee7c202c69b777476929cf697761d2eb93e299b4 100644 (file)
@@ -21,8 +21,8 @@ config SND_SOC_DAVINCI_ASP
 
 config SND_SOC_DAVINCI_MCASP
        tristate "Multichannel Audio Serial Port (McASP) support"
-       select SND_SOC_TI_EDMA_PCM if TI_EDMA
-       select SND_SOC_TI_SDMA_PCM if DMA_OMAP
+       select SND_SOC_TI_EDMA_PCM
+       select SND_SOC_TI_SDMA_PCM
        help
          Say Y or M here if you want to have support for McASP IP found in
          various Texas Instruments SoCs like: