]> git.itanic.dy.fi Git - linux-stable/commit
ASoC: Intel: bytcht_es8316: Determine quirks/routing with codec-dev ACPI DSM
authorHans de Goede <hdegoede@redhat.com>
Sat, 2 Dec 2023 12:39:46 +0000 (13:39 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 4 Dec 2023 17:20:31 +0000 (17:20 +0000)
commit7650862f4e72d2533356ec001b8ea8d5839aced0
tree3c075604bb6ca2f985d4d621757c801ce4972834
parente8acf91a4013202934313f3c2968e6962daaffff
ASoC: Intel: bytcht_es8316: Determine quirks/routing with codec-dev ACPI DSM

Add support for querying the same ACPI Device-Specific-Method (DSM) as
Windows uses to determine things like speaker and mic routing.

This avoids the need to add DMI quirks for each new ESS8316 tablet model.

This has been tested on the following devices:

1. Chuwi Hi12 CHT with stereo speakers and IN2-mic-map,
   this avoids the need to add a DMI quirk for this model.

2. Nanote UMPC-01 CHT with stereo speakers and IN1-mic-map,
   the existing DMI quirk is still necessary because of a bug
   in the DSM return values for the speakers (it returns mono).

3. Onda V80 plus CHT with mono speaker and IN1-mic-map,
   DSM set quirks match the previously used defaults.

4. GP-electronic T701 BYT with mono speaker and IN2-mic-map,
   DSM set quirks match the previously used defaults.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20231202123946.54347-5-hdegoede@redhat.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/boards/bytcht_es8316.c