OSDN Git Service

android-x86/external-alsa-ucm-conf.git
3 years agocodecs/rt5640: Add hardware volume-control support
Hans de Goede [Mon, 8 Mar 2021 22:05:53 +0000 (23:05 +0100)]
codecs/rt5640: Add hardware volume-control support

Add hardware volume-control support for the rt5640 codec.

Note this commit does not add support for the (digital) master
ADC/DAC Volume / Mute controls. There are 2 of each, and which
one should be used depends on which AIF is being used.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5640: Unify capture volume for AIF1 and AIF2 recording paths
Hans de Goede [Mon, 8 Mar 2021 22:05:52 +0000 (23:05 +0100)]
codecs/rt5640: Unify capture volume for AIF1 and AIF2 recording paths

The rt5640 codec is sometimes used with AIF1 connected to the
SoC and sometimes with AIF2 connected to the SoC.

The rt5640 UCM configuration deals with this by accepting input from
and sending output to both AIFs, relying on the kernels DAPM framework to
disable parts of the graph which are connected to the unconnected AIF.

Before this commit codecs/rt5640/EnableSeq.conf was adding a +9dB
(digital) boost to recording going through the 'ADC' path to AIF1,
while not touching the 'Mono ADC' path to AIF2.

This was causing recordings on devices using AIF2 to be somewhat soft.

This commit unifies the record volume control settings for both paths by
only using the '[Mono ]ADC Capture Volume' control, which is present
in both paths and setting it to +9dB on both paths.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5640: Drop bogus 'DIG MIXL DAC L2 Switch' setting
Hans de Goede [Mon, 8 Mar 2021 22:05:51 +0000 (23:05 +0100)]
codecs/rt5640: Drop bogus 'DIG MIXL DAC L2 Switch' setting

The 'DIG MIXL DAC L2 Switch' path is only used for Digital Mixer Path
loopback, which we don't use. Drop it.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5640: Cleanup: Move 'SPK MIX' setup to main EnableSequene
Hans de Goede [Mon, 8 Mar 2021 22:05:50 +0000 (23:05 +0100)]
codecs/rt5640: Cleanup: Move 'SPK MIX' setup to main EnableSequene

Cleanup: no functional changes intended.

Do the 'SPK MIXL' / 'SPK MIXR' setup only once from the main
EnableSequene, like we do for the 'OUT MIXL' / 'OUT MIXR' setup
used by the headphones already.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5640: Cleanup: Initially disable all inputs and outputs
Hans de Goede [Mon, 8 Mar 2021 22:05:49 +0000 (23:05 +0100)]
codecs/rt5640: Cleanup: Initially disable all inputs and outputs

Cleanup: no functional changes intended.

Disable all inputs and outputs from the main EnableSequence.

This allows removing some weirdness from the individual input/output
EnableSequences where they were turning controls for other inputs/outputs
then themselves off.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5640: Cleanup: unify Stereo / Mono ADC handling
Hans de Goede [Mon, 8 Mar 2021 22:05:48 +0000 (23:05 +0100)]
codecs/rt5640: Cleanup: unify Stereo / Mono ADC handling

Cleanup: no functional changes intended.

The rt5640 codec is sometimes used with AIF1 connected to the SoC
and sometimes with AIF2 connected to the SoC.

The rt5640 UCM configuration deals with this by accepting input from
and sending output to both AIFs, relying on the kernels DAPM framework to
disable parts of the graph which are connected to the unconnected AIF.

On the output side we solve this by enabling both the IF1_DAC and
IF2_DAC data inputs to the digital 'Stereo DAC MIX' mixer.

On the input side handling this is somewhat more complicated, the
"Digital Mixer Path" leading to the IF1_ADC and IF2_ADC outputs
are entirely separate paths. To solve this we enable the active
input (DMIC or ADC) in both the Stereo ADC (connected to IF1_ADC)
and the Mono ADC (IF2_ADC) paths.

So far we've not been entirely consistent in our handling of
the Stereo ADC vs Mono ADC paths, this commit cleans this up:

1. Set the 'Mono ADC Capture Switch' to on once from EnableSeq.conf,
   like we do for the 'ADC Capture Switch' instead of toggling it on/off
   from the individual input Enable/Disable sequences.

2. Group all the 'Mono ADC ...' mixer cset calls together with their
   stereo ADC counterparts.

3. Explicitly select DMIC L/R 1 for the Mono ADC L/R 2 Mux input, instead
   of relying on this being the default.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/es8316: Add hardware volume-control support
Hans de Goede [Sun, 7 Mar 2021 20:03:08 +0000 (21:03 +0100)]
codecs/es8316: Add hardware volume-control support

Add hardware volume-control support for the es8316 codec.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/es8316: Fix 'HP Mixer Volume' setting
Hans de Goede [Sun, 7 Mar 2021 20:03:07 +0000 (21:03 +0100)]
codecs/es8316: Fix 'HP Mixer Volume' setting

The 'HP Mixer Volume' control is interesting in that it has a hole
in its range which should not be used (described in the tlv table),
valid values are 0-4 and 8-11

I assume that the "Set HP mixer vol to -6 dB (4/7) louder does not work"
comment which this patch changes comes from attempts to use values in
that hole in the range (also notice the wrong max value in the comment).

Setting the HP mixer to -6 dB causes the sound to be significantly
softer then under Windows. This commit fixes this by initializing the
HP mixer control to 11 / 0 dB.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/es8316: Fix capture settings
Hans de Goede [Sun, 7 Mar 2021 20:03:06 +0000 (21:03 +0100)]
codecs/es8316: Fix capture settings

Fix the following issues with the capture settings:

1. Disable ALC / Auto Level Control, it tries to always get an
   input signal even when the user is not talking into the mic
   leading to it cranking up the volume till there is noise at
   the same level as the user talking.

2. The 'ADC PGA Gain Volume' volume control is not the main
   'ADC vol' control, it is the mic amplifier control and
   setting it to 10 sets it to 24dB not 0dB.
   Adjust the comment and set it to 7 which is 16dB which
   gives a good microphone signal strength without introducing
   too much noise (with 'ADC Capture Volume' set to 0dB).

3. There actually is a main 'ADC vol' control which goes from -96 to 0dB
   which is simply called the 'ADC Capture Volume' and when disabling ALC
   it defaults to -96 dB. Add a line setting it to 0dB.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2/conf.d: add symlinks for Qualcomm cards
Dmitry Baryshkov [Fri, 5 Feb 2021 17:45:40 +0000 (20:45 +0300)]
ucm2/conf.d: add symlinks for Qualcomm cards

Add ucm2/conf.d symlinks for all defined Qualcomm sound cards.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: Separate the configuration lookups (hw based) from the configuration tree
Jaroslav Kysela [Wed, 3 Feb 2021 16:13:01 +0000 (17:13 +0100)]
ucm2: Separate the configuration lookups (hw based) from the configuration tree

Introduce ucm2/conf.d/ tree with symlinks to the real hardware configurations.
In this way, we do not rely to create the configuration paths based on
simple driver / device identification, but we can store the configurations
more logically to make the maintenance (code reuse, multiple changes)
more easy.

This commit keeps the older lookup paths active, but they will be
turned off in the next release.

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/70
BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/76
BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/78
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobytcr-wm5102: Add new UCM profile for BYT boards with a WM5102 codec
Hans de Goede [Tue, 9 Feb 2021 19:08:59 +0000 (20:08 +0100)]
bytcr-wm5102: Add new UCM profile for BYT boards with a WM5102 codec

Add new UCM profile for BYT boards with a WM5102 codec. This has been
tested with both the SST and the SOF driver on a
Lenovo Yoga Tablet 2 1051L.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/rt5672: Remove Intel SST specific HeadsetMic workaround
Hans de Goede [Tue, 9 Feb 2021 21:01:01 +0000 (22:01 +0100)]
codecs/rt5672: Remove Intel SST specific HeadsetMic workaround

There used to be an issue with the HeadsetMic on BYT devices with
a rt5672 codec only being recorded on the left channel, while the
right channel recorded silence.

The ucm2/codecs/rt5672/HeadsetMic.conf contains a workaround for
this which changes the SST record-stream demuxer settings to
use "slot 0" for both the left and right channels when recording
from the HeadsetMic.

There are 2 problems with this workaround:

1. It uses SST specific mixer settings causing things to break
when using the SOF driver.

2. Files under uc2m/codecs should be architecture agnostic and should
not depend on platform dependent mixer settings such as the SST driver
mixer settings.

The problem which the workaround used to work around has since been
fixed in the kernel by switching the wire format from TDM/DSP A to I2S:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0ceb8a36d023d4bb4ffca3474a452fb1dfaa0ef2

This fix has landed in 5.8 and has been backported to all recent
stable kernel releases.

Since this is fixed in the kernel now, we can drop the workaround,
fixing the 2 problems mentioned above.

This was tested on a ThinkPad 8 tablet, which is the same device as
where the HeadsetMic problem was originally noticed.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-soundwire: add support for dmics
Pierre-Louis Bossart [Thu, 21 Jan 2021 20:44:05 +0000 (14:44 -0600)]
sof-soundwire: add support for dmics

the pinmux allows for SoundWire to be used on e.g. link0 and link1,
and the rest of the pins can be assigned for dmic usages.

We currently don't track this capability which means users don't see a
capture device, e.g. on HP Spectre x360.

The sof_sdw machine driver was modified to report the cfg-dmics
string, possible values are 0..4.

BugLink: https://github.com/thesofproject/linux/issues/2700
BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/75
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: update handling of cfg-dmics strings
Pierre-Louis Bossart [Thu, 21 Jan 2021 20:38:26 +0000 (14:38 -0600)]
sof-hda-dsp: update handling of cfg-dmics strings

Existing platforms can have 1,2,3 or 4 microphones. The SOF firmware
will generate 2 or 4 channels. Since by default CaptureChannels is 2,
we need to add the case for cfg-dmics = 3.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtnau8824: Add support for using the SOF driver
Hans de Goede [Wed, 16 Dec 2020 15:38:38 +0000 (16:38 +0100)]
chtnau8824: Add support for using the SOF driver

The old (and currently the default) SST driver uses TDM 4 slots 24 bit
as wire format to the codec. Where as the new SOF driver uses standard
I2S 2 channel 24 bit.

Normally this should not impact the UCM settings, but on the NAU8824
the "DAC Right Channel Source" mixer setting must be set to 1 when
using TDM 4 slots and to 0 when using I2S 2 channel mode.

Getting this wrong (in either case) results in the right channel not
outputting any sound.

This commit introduces a RightOutputChannel variable which gets
set to 0/1 depending on the driver and then uses that for the
"DAC Right Channel Source" mixer setting so that we do the right
thing depending on the driver.

This has been tested on the following devices:

Medion E2215T:    Stereo speakers, analog mic
Medion E2228T:    Stereo speakers, stereo digital mics
Cube iWork 8 Air: Mono speaker, analog mic

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agokblrt5660: Fix file permissions
Takashi Iwai [Thu, 21 Jan 2021 10:15:02 +0000 (11:15 +0100)]
kblrt5660: Fix file permissions

The exec bit was set wrongly on those files.  Fix them.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
3 years agochtnau8824: Add a SST define/variable
Hans de Goede [Wed, 16 Dec 2020 15:38:37 +0000 (16:38 +0100)]
chtnau8824: Add a SST define/variable

Add a SST define which gets set to "yes" when using the SST driver
and to "" when not using the SST driver;

And decide if platforms/bytcr/PlatformEnableSeq.conf should be included
or not based on this.

This is a preparation patch for adding SOF support.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoUSB-Audio: fix indentation in Gigabyte-Aorus-Master-Main-Audio-HiFi.conf
Jaroslav Kysela [Fri, 15 Jan 2021 13:55:53 +0000 (14:55 +0100)]
USB-Audio: fix indentation in Gigabyte-Aorus-Master-Main-Audio-HiFi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoUSB-Audio/ALC1220: fix indentation for Speaker device
Jaroslav Kysela [Fri, 15 Jan 2021 13:03:35 +0000 (14:03 +0100)]
USB-Audio/ALC1220: fix indentation for Speaker device

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoUSB-Audio/ALC1220: Bump analog Speaker priority over S/PDIF
Marijn Suijten [Thu, 14 Jan 2021 13:11:50 +0000 (14:11 +0100)]
USB-Audio/ALC1220: Bump analog Speaker priority over S/PDIF

The `S/PDIF` port does not have any jack sensing, and with a priority
higher than the `Speakers` it will always be selected by default instead
of the `Speakers` even if unplugged.

Swapping the priorities around allows analog `Speakers` to be selected
first, _if_ they are plugged in. Otherwise `S/PDIF` is used.

Signed-off-by: Marijn Suijten <marijns95@gmail.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: add initial configuration for TRX40 Gigabyte Aorus Master Audio
Jaroslav Kysela [Thu, 14 Jan 2021 10:03:56 +0000 (11:03 +0100)]
ucm2: add initial configuration for TRX40 Gigabyte Aorus Master Audio

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/25
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobytcr-rt5640: fix the execution order
Jaroslav Kysela [Thu, 14 Jan 2021 17:31:24 +0000 (18:31 +0100)]
bytcr-rt5640: fix the execution order

The includes must be run _after_ defines. The Include directives
have precedence. Put everything to If compound.

Fixes: bdd05ac339 ("bytcr-rt5640: Add support for devices without speakers and/or an internal mic")
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agort5640: Move standard DAC setup to EnableSeq.conf
Hans de Goede [Sat, 9 Jan 2021 21:02:52 +0000 (22:02 +0100)]
rt5640: Move standard DAC setup to EnableSeq.conf

No matter which output is used, we always need to setup the standard
DAC config. Move this to the shared EnableSeq.conf to avoid having
to duplicate it in various places.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobytcr-rt5640: Add support for devices without speakers and/or an internal mic
Hans de Goede [Sat, 9 Jan 2021 21:02:51 +0000 (22:02 +0100)]
bytcr-rt5640: Add support for devices without speakers and/or an internal mic

There are kernel patches pending upstream for the bytcr-rt5640 machine-driver
to support devices without speakers and/or an internal mic.

Since the UCM profile already conditionally loads the speaker and
internal-mic codec include files, these will simply get skipped in this
case, so this almost works with the current UCM profile without changes.

The only troublesome part is the ConflictingDevice sections in the codec
HeadPhones.conf and HeadsetMic.conf files, which refer to resp. a "Speaker"
and a "Mic" device. Without any of the speaker or mic codec conf files
being included there will not by any "Speaker" / "Mic" devices leading
to an error while parsing the HeadPhones.conf / HeadsetMic.conf files.

This commit makes the ConflictingDevice section conditional, fixing this.

Cc: Rasmus Porsager <rasmus@beat.dk>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtrt5645: Enable Internal MIC of ECS EF20EA
Jian-Hong Pan [Tue, 15 Dec 2020 08:54:03 +0000 (16:54 +0800)]
chtrt5645: Enable Internal MIC of ECS EF20EA

The ECS EF20EA uses a digital mic connected to the dmic2 pin, rather
then the default analog mic.

1 [chtrt5645      ]: chtrt5645 - chtrt5645
                     Standard-EF20EA-1.0

Add a card long name match for this, so that the right config is used.

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/68
Signed-off-by: Jian-Hong Pan <jhp@endlessos.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoHDA-Intel/HiFi-dual: Add BootSequence and disable playback channels in verb init
Jaroslav Kysela [Wed, 16 Dec 2020 07:55:04 +0000 (08:55 +0100)]
HDA-Intel/HiFi-dual: Add BootSequence and disable playback channels in verb init

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/48
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoHDA-Intel/HiFi-dual: Add EnableSequence and DisableSequence for Speaker and Headphones
Kai-Heng Feng [Thu, 27 Aug 2020 13:18:13 +0000 (21:18 +0800)]
HDA-Intel/HiFi-dual: Add EnableSequence and DisableSequence for Speaker and Headphones

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/48
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: Set Master Playback Switch on in the BootSequence
Hui Wang [Thu, 29 Oct 2020 05:34:02 +0000 (13:34 +0800)]
sof-hda-dsp: Set Master Playback Switch on in the BootSequence

Otherwise, the audio output will be muted by default if there is no
/var/lib/alsa/asound.state. I have experienced this issue When newly
install an OS.

Signed-off-by: Hui Wang <hui.wang@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agort715: init: setup ADC07 to a proper volume
Libin Yang [Thu, 19 Nov 2020 12:01:30 +0000 (20:01 +0800)]
rt715: init: setup ADC07 to a proper volume

This patch initiates 'rt715 ADC 07 Capture Volume' to a proper volume.

Signed-off-by: Libin Yang <libin.yang@intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtnau8824: Boost analog mic volumes a bit
Hans de Goede [Sun, 6 Dec 2020 12:47:18 +0000 (13:47 +0100)]
chtnau8824: Boost analog mic volumes a bit

Both Mic1 (internal analog mic) and Mic2 (headset mic) are a bit soft
with the current settings, boost their volumes a bit.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtnau8824: Add support for laptops using stereo DMICs
Hans de Goede [Sun, 6 Dec 2020 12:47:17 +0000 (13:47 +0100)]
chtnau8824: Add support for laptops using stereo DMICs

The Medion E2228T uses a NAU8824 codec combined with stereo
DMICs, add support for this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtnau8824: Fix mono speaker config not working
Hans de Goede [Sun, 6 Dec 2020 12:47:16 +0000 (13:47 +0100)]
chtnau8824: Fix mono speaker config not working

Fix the Speaker define / var being changed from "Speaker" to "MonoSpeaker"
not having any effect because the variable gets expanded before the if
making the change is interpreted.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoRevert "ucm2: HDA/acp - add Capture simple mixer element to the ACP Mic device"
Jaroslav Kysela [Mon, 7 Dec 2020 08:33:30 +0000 (09:33 +0100)]
Revert "ucm2: HDA/acp - add Capture simple mixer element to the ACP Mic device"

This reverts commit 3320b1ac804595d6c145c1ad7af85917182a3c98.

This solution does not work. The mute state is shared between
the HDA and AMD ACP in PA, so it may cause the security issue, if
the users do not set the mute manually.

BugLink: https://github.com/alsa-project/alsa-ucm-conf/issues/64
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-soundwire: use the codecs/hda/hdmi.conf macro
Jaroslav Kysela [Mon, 16 Nov 2020 10:48:05 +0000 (11:48 +0100)]
sof-soundwire: use the codecs/hda/hdmi.conf macro

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocodecs/hda/hdmi.conf - add DisplayPort to the device description (Comment)
Jaroslav Kysela [Mon, 2 Nov 2020 17:15:14 +0000 (18:15 +0100)]
codecs/hda/hdmi.conf - add DisplayPort to the device description (Comment)

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agofix the ucm2/codecs/hda/hdmi.conf use
Jaroslav Kysela [Mon, 2 Nov 2020 15:44:51 +0000 (16:44 +0100)]
fix the ucm2/codecs/hda/hdmi.conf use

The mentioned commit (dcef48f13d) removed the index for the IEC958 on/off
control which made the HDMI 2+ outputs silent.

Fixes: dcef48f13d ("HDA-Intel: add support for AMD acp microphone devices")
BugLink: https://github.com/alsa-project/alsa-lib/issues/95
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: HDA-Intel - add error section when the HDA model is not supported
Jaroslav Kysela [Thu, 15 Oct 2020 11:34:05 +0000 (13:34 +0200)]
ucm2: HDA-Intel - add error section when the HDA model is not supported

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobdw-rt5677: add SOF support
Joseph Burt [Thu, 17 Sep 2020 18:36:10 +0000 (18:36 +0000)]
bdw-rt5677: add SOF support

Completes 898602208888da63d758ff3c293b5ad2ec6e6c19

Signed-off-by: Joseph Burt <caseorum@gmail.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: USB-Audio: Add CaptureMixerElem for Lenovo ThinkStation P620
Kai-Heng Feng [Mon, 14 Sep 2020 13:00:36 +0000 (21:00 +0800)]
ucm2: USB-Audio: Add CaptureMixerElem for Lenovo ThinkStation P620

The Switch and Volume mixer start to work after device firmware update.
Add MixerElem to support them.

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm.conf: The module name may not be available when the driver in built-in.
Jaroslav Kysela [Tue, 29 Sep 2020 15:31:34 +0000 (17:31 +0200)]
ucm.conf: The module name may not be available when the driver in built-in.

BugLink: https://github.com/alsa-project/alsa-ucm-conf/issues/52
Fixes: d001c8de287f ("ucm.conf: add support for the kernel module name tree")

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: USB-Audio: Add support for Lenovo ThinkStation P620 Rear Audio
Kai-Heng Feng [Wed, 9 Sep 2020 09:10:41 +0000 (17:10 +0800)]
ucm2: USB-Audio: Add support for Lenovo ThinkStation P620 Rear Audio

Add proper PCM assignment to Lenovo ThinkStation P620 Rear Audio.

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: Qualcomm sdm845 fixes HDMI select card and HiFi set DigitalVol
Aníbal Limón [Mon, 31 Aug 2020 22:25:13 +0000 (17:25 -0500)]
ucm2: Qualcomm sdm845 fixes HDMI select card and HiFi set DigitalVol

Remove the duplicated PlaybackVolume entry.

Signed-off-by: Aníbal Limón <anibal.limon@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: Qualcomm sdm845 fixes HDMI select card and HiFi set DigitalVol
Aníbal Limón [Mon, 31 Aug 2020 22:25:13 +0000 (17:25 -0500)]
ucm2: Qualcomm sdm845 fixes HDMI select card and HiFi set DigitalVol

Signed-off-by: Aníbal Limón <anibal.limon@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoAdd support for Lenovo ThinkStation P620 Main Audio
Kai-Heng Feng [Thu, 20 Aug 2020 14:12:02 +0000 (22:12 +0800)]
Add support for Lenovo ThinkStation P620 Main Audio

This add support for its internal speaker and front headset.

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoHDA-Intel: only add the acp dmic to the sound card with analog codec
Hui Wang [Thu, 20 Aug 2020 03:25:24 +0000 (11:25 +0800)]
HDA-Intel: only add the acp dmic to the sound card with analog codec

Without this change, the acp dmic will be added to both Intel sound
card (with analog codec) and Nvidia Hdmi audio sound card.

Signed-off-by: Hui Wang <hui.wang@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: HDA/acp - add Capture simple mixer element to the ACP Mic device
Jaroslav Kysela [Tue, 1 Sep 2020 11:57:18 +0000 (13:57 +0200)]
ucm2: HDA/acp - add Capture simple mixer element to the ACP Mic device

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: module - rename rk3399-gru-sound.conf => snd_soc_rk3399_gru_sound.conf
Jaroslav Kysela [Wed, 19 Aug 2020 14:15:04 +0000 (16:15 +0200)]
ucm2: module - rename rk3399-gru-sound.conf => snd_soc_rk3399_gru_sound.conf

We are using the real kernel module name for the first level selection now.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoRevert "amd/renoir/acp: use the machine driver's name for top-level's conf"
Jaroslav Kysela [Wed, 19 Aug 2020 14:04:48 +0000 (16:04 +0200)]
Revert "amd/renoir/acp: use the machine driver's name for top-level's conf"

This reverts commit 35277f419b1dc0f8500d3ab4bceabf6cad05c76d.

We use the snd_acp3x_rn kernel module name again with the correct
sysfs lookup.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: ucm.conf - fix the fix the sysfs kernel module path
Jaroslav Kysela [Wed, 19 Aug 2020 14:03:48 +0000 (16:03 +0200)]
ucm2: ucm.conf - fix the fix the sysfs kernel module path

The idea was to use the kernel module name not the driver name which
may be different.

BugLink: https://github.com/alsa-project/alsa-lib/pull/79
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoRockchip/rk3399-gru-sound: remove zero PCM subdevice
Jaroslav Kysela [Tue, 18 Aug 2020 15:39:50 +0000 (17:39 +0200)]
Rockchip/rk3399-gru-sound: remove zero PCM subdevice

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoUSB-Audio: Dell-WD15-Dock: make input and output volume adjustable
Hui Wang [Mon, 17 Aug 2020 04:37:44 +0000 (12:37 +0800)]
USB-Audio: Dell-WD15-Dock: make input and output volume adjustable

Recently we found the input volume is too low for some specific
headset-mic, even we adjust the input volume to max from PA, we still
can't record the sound from that headset-mic. That is because we
change the input or output volume from PA, but the mixer's volume
is not changed, only PA's soft-volume is changed.

Checking the amixer controls for the sound card in the WD19, it
supports MixerElem, Volume and Switch, and checking the sound card in
the WD15, it doesn't have Volume and Switch for Headphone and Line,
So adding the volume and switch control in the ucm conditionally.

Signed-off-by: Hui Wang <hui.wang@canonical.com>
BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/47
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoHDA-Intel: HiFi-dual: Fix the Rear Mic's Jack name
Hui Wang [Mon, 17 Aug 2020 03:28:04 +0000 (11:28 +0800)]
HDA-Intel: HiFi-dual: Fix the Rear Mic's Jack name

On the LENOVO P520 (dual codecs machine), the Jack name of Rear Mic is
"Rear Mic Jack" instead of "Mic Jack".

Below is picked from alsa-info.txt on the LENOVO p520 machine:
control.18 {
iface CARD
name 'Rear Mic Jack'
value true
comment {
access read
type BOOLEAN
count 1
}
}

Signed-off-by: Hui Wang <hui.wang@canonical.com>
BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/46
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoCorrect conflicting mic in max98090
jacobopantoja [Thu, 6 Aug 2020 11:53:07 +0000 (13:53 +0200)]
Correct conflicting mic in max98090

'mic' was conflicting 'mic' instead of 'headset', thus preventing correct configuration regarding microphones.

With this corrected, introducing a headset enables 'headset' mic and disables internal 'mic', whereas releasing the headset disables 'headset' mic and enables internal 'mic'

BugLink: https://github.com/alsa-project/alsa-ucm-conf/pull/43
From: acobopantoja@gmail.com
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoamd/renoir/acp: Add Syntax 3 in the module/lib/Linked.conf
Hui Wang [Wed, 22 Jul 2020 06:25:15 +0000 (14:25 +0800)]
amd/renoir/acp: Add Syntax 3 in the module/lib/Linked.conf

Otherwise the alsalib will report:
parser.c: Syntax field not found in xxx.conf

Signed-off-by: Hui Wang <hui.wang@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoamd/renoir/acp: use the machine driver's name for top-level's conf
Hui Wang [Tue, 21 Jul 2020 08:51:00 +0000 (16:51 +0800)]
amd/renoir/acp: use the machine driver's name for top-level's conf

On the machines with amd renoir audio, the /sys/class/sound/card2/
device/driver links to /sys/bus/platform/drivers/acp_pdm_mach.

Signed-off-by: Hui Wang <hui.wang@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: Add config for Rockchip/rk3399-gru-sound
Alper Nebi Yasak [Wed, 8 Jul 2020 20:09:19 +0000 (23:09 +0300)]
ucm2: Add config for Rockchip/rk3399-gru-sound

This is the internal card for a number of ChromeOS devices based on the
Gru board. Config is taken from ChromeOS sources [1] and modified to
mostly look like Rockchip/max98090. Tested on a Samsung Chromebook Plus
(rk3399-gru-kevin) running Linux 5.7+.

[1] https://chromium.googlesource.com/chromiumos/overlays/board-overlays/+/75cf7da335c11469956c84ddfa4e2ca73b268441/overlay-kevin/chromeos-base/chromeos-bsp-kevin/files/audio-config/ucm-config/rk3399-gru-sound

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoupdate ucm2/README.md - more kernel module lookup clarifications
Jaroslav Kysela [Tue, 18 Aug 2020 14:00:31 +0000 (16:00 +0200)]
update ucm2/README.md - more kernel module lookup clarifications

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agohda hdmi: add HDMI4,HDMI5,HDMI6 devices
Jaroslav Kysela [Mon, 6 Jul 2020 14:47:57 +0000 (16:47 +0200)]
hda hdmi: add HDMI4,HDMI5,HDMI6 devices

- fix the duplicate index value in the comment section
- change priorities

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: use sof-hda-dsp/Hdmi.conf
Libin Yang [Wed, 1 Jul 2020 05:51:58 +0000 (01:51 -0400)]
sof-hda-dsp: use sof-hda-dsp/Hdmi.conf

sof-hda-dsp should use sof-hda-dsp/Hdmi.conf, not HDA-Intel/Hdmi.conf.
HDA-Intel/Hdmi.conf is for legacy HDA.

Signed-off-by: Libin Yang <libin.yang@intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: fixup typo in Hdmi.conf
Libin Yang [Wed, 1 Jul 2020 05:50:06 +0000 (01:50 -0400)]
sof-hda-dsp: fixup typo in Hdmi.conf

It should be  "/codecs/hda/hdmi.conf" instead of "/codec/hda/hdmi.conf"

Signed-off-by: Libin Yang <libin.yang@intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoDB820c: Correctly move DB820c to Qualcomm/apq8096
Srinivas Kandagatla [Tue, 30 Jun 2020 11:24:57 +0000 (12:24 +0100)]
DB820c: Correctly move DB820c to Qualcomm/apq8096

DB820c belongs to APQ8096 SoC, so it should be moved to ucm2/apq8096
folder rather than apq8016.

So correctly move it to apq8096 to reflect the correct SoC.

Fixes: 73c105b4707b ("DB820c/DB845c: move to Qualcomm/ tree")
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtrt5645: Restore stereo sound output when switching from MonoSpeaker to Headphones
Hans de Goede [Sun, 28 Jun 2020 17:44:21 +0000 (19:44 +0200)]
chtrt5645: Restore stereo sound output when switching from MonoSpeaker to Headphones

Commit fe3b0bdc2f43 ("chtrt5645: merge all possible configurations to
HiFi.conf") missed the part of the removed HiFi-mono-speaker-analog-mic.conf
file which restores stereo mixing (instead of mixing left + right to the
left DAC mixer output) when switching from the mono speaker setup to the
headphones output.

This was causing both left and right channels to only be played on the
left ear of the headphones. This commit fixes this.

Fixes: fe3b0bdc2f43 ("chtrt5645: merge all possible configurations to HiFi.conf")
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocht-bsw-rt5672: Boost ADC volume a bit
Hans de Goede [Sun, 28 Jun 2020 17:44:20 +0000 (19:44 +0200)]
cht-bsw-rt5672: Boost ADC volume a bit

Both the DMICs and the headset mic are quite soft, even with the 20 dB
IN1 boost we already congfigure for the headset.

This commit sets the ADC Boost gain (range 0-3) to 1 = 12 dB, which makes
the volume a lot better. The next step of the ADC Boost gain setting is
24 dB which is a bit too much.

This has been tested with both the builtin DMIC and with a headset mic
on the following devices:

Lenovo Miix 2 10
Lenovo Thinkpad 8
Lenovo Thinkpad 10 (gen 1)

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocht-bsw-rt5672: Add Lenovo ThinkPad 10 specific configuration
Hans de Goede [Sun, 28 Jun 2020 17:44:19 +0000 (19:44 +0200)]
cht-bsw-rt5672: Add Lenovo ThinkPad 10 specific configuration

The Lenovo ThinkPad 10 (first gen) has stereo speakers and the stereo
DMICs in the top-edge of the tablet are connected to DMIC1.

Add a RegexMatch for this, so that users do not have to select the right
settings manually.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocht-bsw-rt5672: Add Lenovo Miix 2 10 specific configuration
Hans de Goede [Sun, 28 Jun 2020 17:44:18 +0000 (19:44 +0200)]
cht-bsw-rt5672: Add Lenovo Miix 2 10 specific configuration

By default the cht-bsw-rt5672 config lets the user figure out if a device
has a Mono spaker or Stereo speakers and which DMIC input is used.

Since this is not very user-friendly we do regex matches on the DMI derived
longname to automaticaly select the right options (and to only advertise
those options).

This commit adds support for automatically selecting the right options
on the Lenovo Miix 2 10 tablet. Since this is the first device for which
we do longname matching using a DMIC on DMIC1, this also fixes a fixme :)

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoFix invalid "Regex" Type in various Condition blocks
Hans de Goede [Sun, 28 Jun 2020 17:44:17 +0000 (19:44 +0200)]
Fix invalid "Regex" Type in various Condition blocks

Regex is not a valid Condition type, using it leads to errors like these:

ALSA lib ucm_cond.c:300:(if_eval) unknown If.Condition.Type
ALSA lib main.c:983:(snd_use_case_mgr_open) error: failed to import cht-bsw-rt5672 use case configuration -22
alsaucm: error failed to open sound card cht-bsw-rt5672: Invalid argument

Replacing it with "RegexMatch" fixes this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoSDP4430: Move to OMAP/abe-twl6040/SDP4430 tree
Jaroslav Kysela [Thu, 25 Jun 2020 15:43:40 +0000 (17:43 +0200)]
SDP4430: Move to OMAP/abe-twl6040/SDP4430 tree

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoGoogleNyan: move to Tegra/max98090
Jaroslav Kysela [Thu, 25 Jun 2020 15:32:40 +0000 (17:32 +0200)]
GoogleNyan: move to Tegra/max98090

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoPandaboard(ES): move to OMAP/abe-twl6040 tree
Jaroslav Kysela [Thu, 25 Jun 2020 15:09:56 +0000 (17:09 +0200)]
Pandaboard(ES): move to OMAP/abe-twl6040 tree

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoVEYRON-I2C: move to Rockchip/max98090 tree
Jaroslav Kysela [Thu, 25 Jun 2020 15:05:25 +0000 (17:05 +0200)]
VEYRON-I2C: move to Rockchip/max98090 tree

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoPAZ00/tegraalc5632: move to Tegra/alc5632 tree
Jaroslav Kysela [Thu, 25 Jun 2020 15:01:05 +0000 (17:01 +0200)]
PAZ00/tegraalc5632: move to Tegra/alc5632 tree

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoDB820c/DB845c: move to Qualcomm/ tree
Jaroslav Kysela [Thu, 25 Jun 2020 14:55:42 +0000 (16:55 +0200)]
DB820c/DB845c: move to Qualcomm/ tree

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoDB410c: move to Qualcomm/apq8016-sbc
Jaroslav Kysela [Thu, 25 Jun 2020 14:39:01 +0000 (16:39 +0200)]
DB410c: move to Qualcomm/apq8016-sbc

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoDAISY-I2S: move to Samsung/snow/snow.conf
Jaroslav Kysela [Thu, 25 Jun 2020 14:06:37 +0000 (16:06 +0200)]
DAISY-I2S: move to Samsung/snow/snow.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoHDA-Intel: add support for AMD acp microphone devices
Jaroslav Kysela [Wed, 24 Jun 2020 11:39:07 +0000 (13:39 +0200)]
HDA-Intel: add support for AMD acp microphone devices

- move the generic HDA code from sof-hda-dsp to HDA-Intel
- add generic codecs/hda/hdmi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: fix the device order (Hdmi devices)
Jaroslav Kysela [Wed, 24 Jun 2020 10:34:13 +0000 (12:34 +0200)]
sof-hda-dsp: fix the device order (Hdmi devices)

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-soundwire: rewrite for 'syntax 3'
Jaroslav Kysela [Wed, 24 Jun 2020 10:24:45 +0000 (12:24 +0200)]
sof-soundwire: rewrite for 'syntax 3'

The codec/ sequences must not have the platform specific checks.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-soundwire: cleanups recommended by the ucm-validator
Jaroslav Kysela [Wed, 24 Jun 2020 09:15:42 +0000 (11:15 +0200)]
sof-soundwire: cleanups recommended by the ucm-validator

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-soundwire: initial UCM2 version
Pierre-Louis Bossart [Mon, 16 Mar 2020 21:42:11 +0000 (16:42 -0500)]
sof-soundwire: initial UCM2 version

Add support for sof-soundwire driver, with conditional inclusion of
sections for RT700, RT711, RT5682, RT1308, RT715.

Signed-off-by: Libin Yang <libin.yang@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobroadwell-rt286: add SOF support
Pierre-Louis Bossart [Tue, 9 Jun 2020 01:15:32 +0000 (20:15 -0500)]
broadwell-rt286: add SOF support

Include legacy configuration using SOF driver name and card check

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobdw-rt5677: add support for legacy and SOF drivers
Pierre-Louis Bossart [Tue, 9 Jun 2020 01:09:04 +0000 (20:09 -0500)]
bdw-rt5677: add support for legacy and SOF drivers

Use inclusion mechanism defined for Baytrail and reuse same configuration.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: make the boot init optional for all controls
Jaroslav Kysela [Wed, 24 Jun 2020 08:39:42 +0000 (10:39 +0200)]
sof-hda-dsp: make the boot init optional for all controls

Also don't initialize "Auto-Mute Mode" in the HiFi verb.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: add initial kcontrol values
Libin Yang [Thu, 21 May 2020 07:45:16 +0000 (03:45 -0400)]
sof-hda-dsp: add initial kcontrol values

This patch adds the initial values of sof-hda-dsp card.

Signed-off-by: Libin Yang <libin.yang@intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: make Headphone Playback Switch conditional
Kai Vehmanen [Thu, 11 Jun 2020 14:46:07 +0000 (17:46 +0300)]
sof-hda-dsp: make Headphone Playback Switch conditional

The Headphone Playback Switch control is not present in all
HDA codecs. Allow the Headphones definition to work also on
such systems.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm.conf: add support for the kernel module name tree
Jaroslav Kysela [Mon, 22 Jun 2020 15:52:54 +0000 (17:52 +0200)]
ucm.conf: add support for the kernel module name tree

It seems that some ASoC drivers (mainly created from the DT tree)
does not offer any good identification for the common part.
This change adds the sysfs kernel module name lookup to
module/<KernelModuleName>.conf .

Also, modularize V1, V2Name, V2Module blocks. The V1 compatibility
is turned off by default now.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtnau8824: merge all possible configurations to HiFi.conf
Jaroslav Kysela [Mon, 22 Jun 2020 15:51:09 +0000 (17:51 +0200)]
chtnau8824: merge all possible configurations to HiFi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agocht-bsw-rt5672: merge all possible configurations to HiFi.conf
Jaroslav Kysela [Tue, 16 Jun 2020 11:40:21 +0000 (13:40 +0200)]
cht-bsw-rt5672: merge all possible configurations to HiFi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtrt5645: merge all possible configurations to HiFi.conf
Jaroslav Kysela [Tue, 16 Jun 2020 09:33:01 +0000 (11:33 +0200)]
chtrt5645: merge all possible configurations to HiFi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: use Include (Syntax 3)
Jaroslav Kysela [Fri, 5 Jun 2020 16:20:58 +0000 (18:20 +0200)]
ucm2: use Include (Syntax 3)

Instead the unconditional include, use the Include configuration
directive which can load some files when evaluated (on demand only).

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agosof-hda-dsp: don't fail if Auto-Mute control is not present
Kai Vehmanen [Wed, 10 Jun 2020 14:14:16 +0000 (17:14 +0300)]
sof-hda-dsp: don't fail if Auto-Mute control is not present

The "Auto-Mute Mode" control is not present in all HDA codecs.
The generic SOF HDA UCM file should be robust enough to handle
these cases as well.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtrt5645: Add ASUSTeKCOMPUTERINC.-T101HA-1.0.conf symlink to chtrt5645-dmic1.conf
Hans de Goede [Mon, 8 Jun 2020 20:21:42 +0000 (22:21 +0200)]
chtrt5645: Add ASUSTeKCOMPUTERINC.-T101HA-1.0.conf symlink to chtrt5645-dmic1.conf

The Asus T101HA uses a digital mic connected to the dmic1 pin, rather then
the default analog mic on in2 (just like the Asus T100HA).

Add a long name symlink to chtrt5645-dmic1.conf for this, so that
the right config is used.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobytcr-rt5651: Fix high noise level + soft input on DMIC
Hans de Goede [Mon, 8 Jun 2020 20:21:41 +0000 (22:21 +0200)]
bytcr-rt5651: Fix high noise level + soft input on DMIC

The DMIC needs to have the DMIC ASRC enabled, otherwise capturing audio
from it results in mostly capturing noise + the actual recorded voice
very soft in the background of the noise.

This has been tested on a Point of View P1006W v1.0 tablet, which is the
only RT5651 X86 device using a DMIC that I am aware of.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agobytcr-rt5640: Fix DMIC1 not working when connected over AIF2
Hans de Goede [Mon, 8 Jun 2020 20:21:40 +0000 (22:21 +0200)]
bytcr-rt5640: Fix DMIC1 not working when connected over AIF2

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>
3 years agoucm2: fix more indentation issues
Jaroslav Kysela [Fri, 5 Jun 2020 17:01:32 +0000 (19:01 +0200)]
ucm2: fix more indentation issues

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: DB845c: Add ucm for DB845c board
Srinivas Kandagatla [Thu, 5 Mar 2020 13:32:22 +0000 (13:32 +0000)]
ucm2: DB845c: Add ucm for DB845c board

DB845c board by default has two WSA881x speakers and HDMI
audio connections.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: codecs: wsa881x: add codec sequences
Srinivas Kandagatla [Thu, 5 Mar 2020 13:31:12 +0000 (13:31 +0000)]
ucm2: codecs: wsa881x: add codec sequences

Add default, enable/disable codec sequence for wsa881x codec

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: codecs: wcd934x: Add Codec sequences.
Srinivas Kandagatla [Thu, 5 Mar 2020 13:29:44 +0000 (13:29 +0000)]
ucm2: codecs: wcd934x: Add Codec sequences.

Add WCD934x codec sequences to be used by other platforms like DB845c
and Lenovo YOGA C630

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agochtmax98090: add generic chtmax98090.conf and move Quawks init to the generic HiFi...
Jaroslav Kysela [Fri, 29 May 2020 13:48:36 +0000 (15:48 +0200)]
chtmax98090: add generic chtmax98090.conf and move Quawks init to the generic HiFi.conf

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
3 years agoucm2: chtmax98090: add generic HiFi.conf and SOF support
Pierre-Louis Bossart [Thu, 28 May 2020 22:59:01 +0000 (17:59 -0500)]
ucm2: chtmax98090: add generic HiFi.conf and SOF support

Tested on Cyan Chromebook with both SOF and SST drivers.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>