]> git.alsa-project.org Git - alsa-ucm-conf.git/commitdiff
bytcr-rt5640: Fix DMIC1 not working when connected over AIF2
authorHans de Goede <hdegoede@redhat.com>
Mon, 8 Jun 2020 20:21:40 +0000 (22:21 +0200)
committerJaroslav Kysela <perex@perex.cz>
Tue, 9 Jun 2020 08:48:55 +0000 (10:48 +0200)
The RT5640 codec has 2 ADC-s which are caled the Stereo ADC and the
Mono ADC (even though the mono ADC seems to be stereo too?). The Stereo
ADC is connected to the AIF1 interface of the codec and the Mono ADC
to the AIF2 interface.

Almost all X86 BYT/CHT design use the AIF1 interface, but a few models
use the AIF2 interface. For this reason the IN?-InternalMic.conf bits
not only select/enable the microphone input on the Stereo ADC, but
also on the Mono ADC, so that the analog mic. inputs also work in devices
using the AIF2 interface.

Before this commit DigitalMics.conf was only setting up the DMIC input
on the Stereo ADC and not on the Mono ADC, causing DMIC1 to not work
when connected over AIF2.

This commit adds selecting / enabling DMIC1 on the Mono ADC.
This fixes the internal microphone not working on the Toshiba Encore WT10A.

Note that for devices which use the AIF1 interface this is a no-op since
the AIF1 interface is not connected to anything, there is no complete
chain so DAPM will not enable any of the elements in the chain.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
ucm2/codecs/rt5640/DigitalMics.conf

index 503c4a9cd7bf9efaca568b84d641c01125ba615e..fdd412f5e323145efca3cc83c2bb7cbb21a0ce50 100644 (file)
@@ -6,6 +6,9 @@ SectionDevice."Mic" {
        ]
 
        EnableSequence [
+               cset "name='Mono ADC MIXL ADC2 Switch' on"
+               cset "name='Mono ADC MIXR ADC2 Switch' on"
+               cset "name='Mono ADC Capture Switch' on"
                cset "name='Stereo ADC MIXL ADC2 Switch' on"
                cset "name='Stereo ADC MIXR ADC2 Switch' on"
                cset "name='Internal Mic Switch' on"
@@ -13,6 +16,9 @@ SectionDevice."Mic" {
        ]
 
        DisableSequence [
+               cset "name='Mono ADC MIXL ADC2 Switch' off"
+               cset "name='Mono ADC MIXR ADC2 Switch' off"
+               cset "name='Mono ADC Capture Switch' off"
                cset "name='Stereo ADC MIXL ADC2 Switch' off"
                cset "name='Stereo ADC MIXR ADC2 Switch' off"
                cset "name='Internal Mic Switch' off"