1 // SPDX-License-Identifier: GPL-2.0-only 1 // SPDX-License-Identifier: GPL-2.0-only 2 /* 2 /* 3 * soc-acpi-intel-cnl-match.c - tables and sup 3 * soc-acpi-intel-cnl-match.c - tables and support for CNL ACPI enumeration. 4 * 4 * 5 * Copyright (c) 2018, Intel Corporation. 5 * Copyright (c) 2018, Intel Corporation. 6 * 6 * 7 */ 7 */ 8 8 9 #include <sound/soc-acpi.h> 9 #include <sound/soc-acpi.h> 10 #include <sound/soc-acpi-intel-match.h> 10 #include <sound/soc-acpi-intel-match.h> >> 11 #include "../skylake/skl.h" 11 #include "soc-acpi-intel-sdw-mockup-match.h" 12 #include "soc-acpi-intel-sdw-mockup-match.h" 12 13 13 static const struct snd_soc_acpi_codecs essx_8 14 static const struct snd_soc_acpi_codecs essx_83x6 = { 14 .num_codecs = 3, 15 .num_codecs = 3, 15 .codecs = { "ESSX8316", "ESSX8326", "E 16 .codecs = { "ESSX8316", "ESSX8326", "ESSX8336"}, 16 }; 17 }; 17 18 >> 19 static struct skl_machine_pdata cnl_pdata = { >> 20 .use_tplg_pcm = true, >> 21 }; >> 22 18 struct snd_soc_acpi_mach snd_soc_acpi_intel_cn 23 struct snd_soc_acpi_mach snd_soc_acpi_intel_cnl_machines[] = { 19 { 24 { 20 .id = "INT34C2", 25 .id = "INT34C2", 21 .drv_name = "cnl_rt274", 26 .drv_name = "cnl_rt274", 22 .fw_filename = "intel/dsp_fw_c 27 .fw_filename = "intel/dsp_fw_cnl.bin", >> 28 .pdata = &cnl_pdata, 23 .sof_tplg_filename = "sof-cnl- 29 .sof_tplg_filename = "sof-cnl-rt274.tplg", 24 }, 30 }, 25 { 31 { 26 .comp_ids = &essx_83x6, 32 .comp_ids = &essx_83x6, 27 .drv_name = "sof-essx8336", 33 .drv_name = "sof-essx8336", 28 /* cnl and cml are identical * 34 /* cnl and cml are identical */ 29 .sof_tplg_filename = "sof-cml- 35 .sof_tplg_filename = "sof-cml-es8336", /* the tplg suffix is added at run time */ 30 .tplg_quirk_mask = SND_SOC_ACP 36 .tplg_quirk_mask = SND_SOC_ACPI_TPLG_INTEL_SSP_NUMBER | 31 SND_SO 37 SND_SOC_ACPI_TPLG_INTEL_SSP_MSB | 32 SND_SO 38 SND_SOC_ACPI_TPLG_INTEL_DMIC_NUMBER, 33 }, 39 }, 34 {}, 40 {}, 35 }; 41 }; 36 EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_cnl_machi 42 EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_cnl_machines); 37 43 38 static const struct snd_soc_acpi_endpoint sing 44 static const struct snd_soc_acpi_endpoint single_endpoint = { 39 .num = 0, 45 .num = 0, 40 .aggregated = 0, 46 .aggregated = 0, 41 .group_position = 0, 47 .group_position = 0, 42 .group_id = 0, 48 .group_id = 0, 43 }; 49 }; 44 50 45 static const struct snd_soc_acpi_adr_device rt 51 static const struct snd_soc_acpi_adr_device rt5682_2_adr[] = { 46 { 52 { 47 .adr = 0x000220025D568200ull, 53 .adr = 0x000220025D568200ull, 48 .num_endpoints = 1, 54 .num_endpoints = 1, 49 .endpoints = &single_endpoint, 55 .endpoints = &single_endpoint, 50 .name_prefix = "rt5682" 56 .name_prefix = "rt5682" 51 } 57 } 52 }; 58 }; 53 59 54 static const struct snd_soc_acpi_link_adr up_e 60 static const struct snd_soc_acpi_link_adr up_extreme_rt5682_2[] = { 55 { 61 { 56 .mask = BIT(2), 62 .mask = BIT(2), 57 .num_adr = ARRAY_SIZE(rt5682_2 63 .num_adr = ARRAY_SIZE(rt5682_2_adr), 58 .adr_d = rt5682_2_adr, 64 .adr_d = rt5682_2_adr, 59 }, 65 }, 60 {} 66 {} 61 }; 67 }; 62 68 63 struct snd_soc_acpi_mach snd_soc_acpi_intel_cn 69 struct snd_soc_acpi_mach snd_soc_acpi_intel_cnl_sdw_machines[] = { 64 { 70 { 65 .link_mask = BIT(2), 71 .link_mask = BIT(2), 66 .links = up_extreme_rt5682_2, 72 .links = up_extreme_rt5682_2, 67 .drv_name = "sof_sdw", 73 .drv_name = "sof_sdw", 68 .sof_tplg_filename = "sof-cnl- 74 .sof_tplg_filename = "sof-cnl-rt5682-sdw2.tplg" 69 }, 75 }, 70 { 76 { 71 .link_mask = GENMASK(3, 0), 77 .link_mask = GENMASK(3, 0), 72 .links = sdw_mockup_headset_2a 78 .links = sdw_mockup_headset_2amps_mic, 73 .drv_name = "sof_sdw", 79 .drv_name = "sof_sdw", 74 .sof_tplg_filename = "sof-cml- 80 .sof_tplg_filename = "sof-cml-rt711-rt1308-rt715.tplg", 75 }, 81 }, 76 { 82 { 77 .link_mask = BIT(0) | BIT(1) | 83 .link_mask = BIT(0) | BIT(1) | BIT(3), 78 .links = sdw_mockup_headset_1a 84 .links = sdw_mockup_headset_1amp_mic, 79 .drv_name = "sof_sdw", 85 .drv_name = "sof_sdw", 80 .sof_tplg_filename = "sof-cml- 86 .sof_tplg_filename = "sof-cml-rt711-rt1308-mono-rt715.tplg", 81 }, 87 }, 82 {} 88 {} 83 }; 89 }; 84 EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_cnl_sdw_m 90 EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_cnl_sdw_machines); 85 91
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.