1313#include <linux/soundwire/sdw.h>
1414#include <linux/soundwire/sdw_type.h>
1515#include <linux/soundwire/sdw_intel.h>
16+ #include <sound/core.h>
1617#include <sound/soc-acpi.h>
1718#include "sof_sdw_common.h"
1819#include "../../codecs/rt711.h"
@@ -748,9 +749,36 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = {
748749 },
749750 .driver_data = (void * )(SOC_SDW_PCH_DMIC ),
750751 },
752+ {
753+ .callback = sof_sdw_quirk_cb ,
754+ .matches = {
755+ DMI_MATCH (DMI_SYS_VENDOR , "Google" ),
756+ DMI_MATCH (DMI_PRODUCT_NAME , "Fatcat" ),
757+ },
758+ .driver_data = (void * )(SOC_SDW_PCH_DMIC |
759+ SOF_BT_OFFLOAD_SSP (2 ) |
760+ SOF_SSP_BT_OFFLOAD_PRESENT ),
761+ },
762+ {}
763+ };
764+
765+ static const struct snd_pci_quirk sof_sdw_ssid_quirk_table [] = {
766+ SND_PCI_QUIRK (0x1043 , 0x1e13 , "ASUS Zenbook S14" , SOC_SDW_CODEC_MIC ),
751767 {}
752768};
753769
770+ static void sof_sdw_check_ssid_quirk (const struct snd_soc_acpi_mach * mach )
771+ {
772+ const struct snd_pci_quirk * quirk_entry ;
773+
774+ quirk_entry = snd_pci_quirk_lookup_id (mach -> mach_params .subsystem_vendor ,
775+ mach -> mach_params .subsystem_device ,
776+ sof_sdw_ssid_quirk_table );
777+
778+ if (quirk_entry )
779+ sof_sdw_quirk = quirk_entry -> value ;
780+ }
781+
754782static struct snd_soc_dai_link_component platform_component [] = {
755783 {
756784 /* name might be overridden during probe */
@@ -1278,6 +1306,13 @@ static int mc_probe(struct platform_device *pdev)
12781306
12791307 snd_soc_card_set_drvdata (card , ctx );
12801308
1309+ if (mach -> mach_params .subsystem_id_set ) {
1310+ snd_soc_card_set_pci_ssid (card ,
1311+ mach -> mach_params .subsystem_vendor ,
1312+ mach -> mach_params .subsystem_device );
1313+ sof_sdw_check_ssid_quirk (mach );
1314+ }
1315+
12811316 dmi_check_system (sof_sdw_quirk_table );
12821317
12831318 if (quirk_override != -1 ) {
@@ -1293,12 +1328,6 @@ static int mc_probe(struct platform_device *pdev)
12931328 for (i = 0 ; i < ctx -> codec_info_list_count ; i ++ )
12941329 codec_info_list [i ].amp_num = 0 ;
12951330
1296- if (mach -> mach_params .subsystem_id_set ) {
1297- snd_soc_card_set_pci_ssid (card ,
1298- mach -> mach_params .subsystem_vendor ,
1299- mach -> mach_params .subsystem_device );
1300- }
1301-
13021331 ret = sof_card_dai_links_create (card );
13031332 if (ret < 0 )
13041333 return ret ;
0 commit comments