[PATCH] ASoC: sam9g20ek: Disable capture unless building with microphone input
Without modification the AT91SAM9G20-EK has no capture support, none of the inputs of the CODEC are wired to anything to useful and there are no paths supporting loopback. Since the audio is clocked from the CODEC and the DAPM inputs are marked as unusable this means that capture will fail to transfer any data as the ADC path can't be powered up.
Flag this in the device description so apps don't see unusable capture support, guarded with the existing optional define for mic input.
Signed-off-by: Mark Brown broonie@kernel.org --- sound/soc/atmel/sam9g20_wm8731.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c index 1430642c8433..785b9d01d8af 100644 --- a/sound/soc/atmel/sam9g20_wm8731.c +++ b/sound/soc/atmel/sam9g20_wm8731.c @@ -98,6 +98,9 @@ static struct snd_soc_dai_link at91sam9g20ek_dai = { .init = at91sam9g20ek_wm8731_init, .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBP_CFP, +#ifndef ENABLE_MIC_INPUT + .playback_only = true, +#endif SND_SOC_DAILINK_REG(pcm), };
--- base-commit: cac85e4616b1cf4a90844b952b49b9cbc4562530 change-id: 20230225-asoc-sam9g20ek-f4e775205d8c
Best regards,
On 25.02.2023 23:48, Mark Brown wrote:
EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
Without modification the AT91SAM9G20-EK has no capture support, none of the inputs of the CODEC are wired to anything to useful and there are no paths supporting loopback. Since the audio is clocked from the CODEC and the DAPM inputs are marked as unusable this means that capture will fail to transfer any data as the ADC path can't be powered up.
Flag this in the device description so apps don't see unusable capture support, guarded with the existing optional define for mic input.
Signed-off-by: Mark Brown broonie@kernel.org
Reviewed-by: Claudiu Beznea claudiu.beznea@microchip.com
sound/soc/atmel/sam9g20_wm8731.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c index 1430642c8433..785b9d01d8af 100644 --- a/sound/soc/atmel/sam9g20_wm8731.c +++ b/sound/soc/atmel/sam9g20_wm8731.c @@ -98,6 +98,9 @@ static struct snd_soc_dai_link at91sam9g20ek_dai = { .init = at91sam9g20ek_wm8731_init, .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBP_CFP, +#ifndef ENABLE_MIC_INPUT
.playback_only = true,
+#endif SND_SOC_DAILINK_REG(pcm), };
base-commit: cac85e4616b1cf4a90844b952b49b9cbc4562530 change-id: 20230225-asoc-sam9g20ek-f4e775205d8c
Best regards,
Mark Brown broonie@kernel.org
On Sat, 25 Feb 2023 21:48:13 +0000, Mark Brown wrote:
Without modification the AT91SAM9G20-EK has no capture support, none of the inputs of the CODEC are wired to anything to useful and there are no paths supporting loopback. Since the audio is clocked from the CODEC and the DAPM inputs are marked as unusable this means that capture will fail to transfer any data as the ADC path can't be powered up.
Flag this in the device description so apps don't see unusable capture support, guarded with the existing optional define for mic input.
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: sam9g20ek: Disable capture unless building with microphone input commit: c769fb6bcc485d752d492064a9005525a8d5fa24
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
participants (2)
-
Claudiu.Beznea@microchip.com
-
Mark Brown