summaryrefslogtreecommitdiff
path: root/sound/soc/intel
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-02-28 15:30:55 +0300
committerTakashi Iwai <tiwai@suse.de>2019-02-28 15:30:55 +0300
commit70395a96bd882d8dba669f99b5cec0008690accd (patch)
tree37f3a4c2cf35828f153f3ce59c3daa4f39241c32 /sound/soc/intel
parentf97a0944a72b26a2bece72516294e112a890f98a (diff)
parent3146089d235b304e665dc551472ae9cb9ab58572 (diff)
downloadlinux-70395a96bd882d8dba669f99b5cec0008690accd.tar.xz
Merge tag 'asoc-v5.1-2' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: More changes for v5.1 Another batch of changes for ASoC, no big core changes - it's mainly small fixes and improvements for individual drivers. - A big refresh and cleanup of the Samsung drivers, fixing a number of issues which allow the driver to be used with a wider range of userspaces. - Fixes for the Intel drivers to make them more standard so less likely to get bitten by core issues. - New driver for Cirrus Logic CS35L26.
Diffstat (limited to 'sound/soc/intel')
-rw-r--r--sound/soc/intel/boards/Kconfig1
-rw-r--r--sound/soc/intel/boards/bxt_da7219_max98357a.c101
-rw-r--r--sound/soc/intel/boards/bytcr_rt5651.c74
-rw-r--r--sound/soc/intel/boards/kbl_da7219_max98927.c203
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-bxt-match.c25
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-byt-match.c60
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-cht-match.c70
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-cnl-match.c5
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-glk-match.c10
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-hda-match.c2
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-hsw-bdw-match.c20
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-icl-match.c5
-rw-r--r--sound/soc/intel/common/soc-acpi-intel-kbl-match.c19
-rw-r--r--sound/soc/intel/skylake/skl-pcm.c1
14 files changed, 378 insertions, 218 deletions
diff --git a/sound/soc/intel/boards/Kconfig b/sound/soc/intel/boards/Kconfig
index 0a7e40d06395..12d6b73e9531 100644
--- a/sound/soc/intel/boards/Kconfig
+++ b/sound/soc/intel/boards/Kconfig
@@ -293,6 +293,7 @@ config SND_SOC_INTEL_KBL_DA7219_MAX98927_MACH
depends on MFD_INTEL_LPSS && I2C && ACPI
select SND_SOC_DA7219
select SND_SOC_MAX98927
+ select SND_SOC_MAX98373
select SND_SOC_DMIC
select SND_SOC_HDAC_HDMI
help
diff --git a/sound/soc/intel/boards/bxt_da7219_max98357a.c b/sound/soc/intel/boards/bxt_da7219_max98357a.c
index c00925f9da73..5cadb7f654f3 100644
--- a/sound/soc/intel/boards/bxt_da7219_max98357a.c
+++ b/sound/soc/intel/boards/bxt_da7219_max98357a.c
@@ -16,6 +16,8 @@
* GNU General Public License for more details.
*/
+#include <asm/cpu_device_id.h>
+#include <linux/input.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <sound/core.h>
@@ -49,6 +51,7 @@ struct bxt_card_private {
enum {
BXT_DPCM_AUDIO_PB = 0,
BXT_DPCM_AUDIO_CP,
+ BXT_DPCM_AUDIO_HS_PB,
BXT_DPCM_AUDIO_REF_CP,
BXT_DPCM_AUDIO_DMIC_CP,
BXT_DPCM_AUDIO_HDMI1_PB,
@@ -103,7 +106,7 @@ static const struct snd_soc_dapm_widget broxton_widgets[] = {
platform_clock_control, SND_SOC_DAPM_POST_PMD|SND_SOC_DAPM_PRE_PMU),
};
-static const struct snd_soc_dapm_route broxton_map[] = {
+static const struct snd_soc_dapm_route audio_map[] = {
/* HP jack connectors - unknown if we have jack detection */
{"Headphone Jack", NULL, "HPL"},
{"Headphone Jack", NULL, "HPR"},
@@ -118,15 +121,6 @@ static const struct snd_soc_dapm_route broxton_map[] = {
{"DMic", NULL, "SoC DMIC"},
/* CODEC BE connections */
- {"HiFi Playback", NULL, "ssp5 Tx"},
- {"ssp5 Tx", NULL, "codec0_out"},
-
- {"Playback", NULL, "ssp1 Tx"},
- {"ssp1 Tx", NULL, "codec1_out"},
-
- {"codec0_in", NULL, "ssp1 Rx"},
- {"ssp1 Rx", NULL, "Capture"},
-
{"HDMI1", NULL, "hif5-0 Output"},
{"HDMI2", NULL, "hif6-0 Output"},
{"HDMI2", NULL, "hif7-0 Output"},
@@ -146,6 +140,28 @@ static const struct snd_soc_dapm_route broxton_map[] = {
{ "Headset Mic", NULL, "Platform Clock" },
};
+static const struct snd_soc_dapm_route broxton_map[] = {
+ {"HiFi Playback", NULL, "ssp5 Tx"},
+ {"ssp5 Tx", NULL, "codec0_out"},
+
+ {"Playback", NULL, "ssp1 Tx"},
+ {"ssp1 Tx", NULL, "codec1_out"},
+
+ {"codec0_in", NULL, "ssp1 Rx"},
+ {"ssp1 Rx", NULL, "Capture"},
+};
+
+static const struct snd_soc_dapm_route gemini_map[] = {
+ {"HiFi Playback", NULL, "ssp1 Tx"},
+ {"ssp1 Tx", NULL, "codec0_out"},
+
+ {"Playback", NULL, "ssp2 Tx"},
+ {"ssp2 Tx", NULL, "codec1_out"},
+
+ {"codec0_in", NULL, "ssp2 Rx"},
+ {"ssp2 Rx", NULL, "Capture"},
+};
+
static int broxton_ssp_fixup(struct snd_soc_pcm_runtime *rtd,
struct snd_pcm_hw_params *params)
{
@@ -193,6 +209,12 @@ static int broxton_da7219_codec_init(struct snd_soc_pcm_runtime *rtd)
return ret;
}
+ snd_jack_set_key(broxton_headset.jack, SND_JACK_BTN_0, KEY_PLAYPAUSE);
+ snd_jack_set_key(broxton_headset.jack, SND_JACK_BTN_1, KEY_VOLUMEUP);
+ snd_jack_set_key(broxton_headset.jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN);
+ snd_jack_set_key(broxton_headset.jack, SND_JACK_BTN_3,
+ KEY_VOICECOMMAND);
+
da7219_aad_jack_det(component, &broxton_headset);
snd_soc_dapm_ignore_suspend(&rtd->card->dapm, "SoC DMIC");
@@ -384,6 +406,20 @@ static struct snd_soc_dai_link broxton_dais[] = {
.dpcm_capture = 1,
.ops = &broxton_da7219_fe_ops,
},
+ [BXT_DPCM_AUDIO_HS_PB] = {
+ .name = "Bxt Audio Headset Playback",
+ .stream_name = "Headset Playback",
+ .cpu_dai_name = "System Pin2",
+ .platform_name = "0000:00:0e.0",
+ .dynamic = 1,
+ .codec_name = "snd-soc-dummy",
+ .codec_dai_name = "snd-soc-dummy-dai",
+ .nonatomic = 1,
+ .trigger = {
+ SND_SOC_DPCM_TRIGGER_POST, SND_SOC_DPCM_TRIGGER_POST},
+ .dpcm_playback = 1,
+ .ops = &broxton_da7219_fe_ops,
+ },
[BXT_DPCM_AUDIO_REF_CP] =
{
.name = "Bxt Audio Reference cap",
@@ -532,6 +568,11 @@ static struct snd_soc_dai_link broxton_dais[] = {
},
};
+static const struct x86_cpu_id glk_ids[] = {
+ { X86_VENDOR_INTEL, 6, 0x7A }, /* Geminilake CPU_ID */
+ {}
+};
+
#define NAME_SIZE 32
static int bxt_card_late_probe(struct snd_soc_card *card)
{
@@ -541,6 +582,13 @@ static int bxt_card_late_probe(struct snd_soc_card *card)
int err, i = 0;
char jack_name[NAME_SIZE];
+ if (x86_match_cpu(glk_ids))
+ snd_soc_dapm_add_routes(&card->dapm, gemini_map,
+ ARRAY_SIZE(gemini_map));
+ else
+ snd_soc_dapm_add_routes(&card->dapm, broxton_map,
+ ARRAY_SIZE(broxton_map));
+
list_for_each_entry(pcm, &ctx->hdmi_pcm_list, head) {
component = pcm->codec_dai->component;
snprintf(jack_name, sizeof(jack_name),
@@ -576,8 +624,8 @@ static struct snd_soc_card broxton_audio_card = {
.num_controls = ARRAY_SIZE(broxton_controls),
.dapm_widgets = broxton_widgets,
.num_dapm_widgets = ARRAY_SIZE(broxton_widgets),
- .dapm_routes = broxton_map,
- .num_dapm_routes = ARRAY_SIZE(broxton_map),
+ .dapm_routes = audio_map,
+ .num_dapm_routes = ARRAY_SIZE(audio_map),
.fully_routed = true,
.late_probe = bxt_card_late_probe,
};
@@ -597,6 +645,26 @@ static int broxton_audio_probe(struct platform_device *pdev)
broxton_audio_card.dev = &pdev->dev;
snd_soc_card_set_drvdata(&broxton_audio_card, ctx);
+ if (x86_match_cpu(glk_ids)) {
+ unsigned int i;
+
+ broxton_audio_card.name = "glkda7219max";
+ /* Fixup the SSP entries for geminilake */
+ for (i = 0; i < ARRAY_SIZE(broxton_dais); i++) {
+ /* MAXIM_CODEC is connected to SSP1. */
+ if (!strcmp(broxton_dais[i].codec_dai_name,
+ BXT_MAXIM_CODEC_DAI)) {
+ broxton_dais[i].name = "SSP1-Codec";
+ broxton_dais[i].cpu_dai_name = "SSP1 Pin";
+ }
+ /* DIALOG_CODE is connected to SSP2 */
+ else if (!strcmp(broxton_dais[i].codec_dai_name,
+ BXT_DIALOG_CODEC_DAI)) {
+ broxton_dais[i].name = "SSP2-Codec";
+ broxton_dais[i].cpu_dai_name = "SSP2 Pin";
+ }
+ }
+ }
/* override plaform name, if required */
mach = (&pdev->dev)->platform_data;
@@ -610,12 +678,19 @@ static int broxton_audio_probe(struct platform_device *pdev)
return devm_snd_soc_register_card(&pdev->dev, &broxton_audio_card);
}
+static const struct platform_device_id bxt_board_ids[] = {
+ { .name = "bxt_da7219_max98357a" },
+ { .name = "glk_da7219_max98357a" },
+ { }
+};
+
static struct platform_driver broxton_audio = {
.probe = broxton_audio_probe,
.driver = {
.name = "bxt_da7219_max98357a",
.pm = &snd_soc_pm_ops,
},
+ .id_table = bxt_board_ids,
};
module_platform_driver(broxton_audio)
@@ -625,5 +700,7 @@ MODULE_AUTHOR("Sathyanarayana Nujella <sathyanarayana.nujella@intel.com>");
MODULE_AUTHOR("Rohit Ainapure <rohit.m.ainapure@intel.com>");
MODULE_AUTHOR("Harsha Priya <harshapriya.n@intel.com>");
MODULE_AUTHOR("Conrad Cooke <conrad.cooke@intel.com>");
+MODULE_AUTHOR("Naveen Manohar <naveen.m@intel.com>");
MODULE_LICENSE("GPL v2");
MODULE_ALIAS("platform:bxt_da7219_max98357a");
+MODULE_ALIAS("platform:glk_da7219_max98357a");
diff --git a/sound/soc/intel/boards/bytcr_rt5651.c b/sound/soc/intel/boards/bytcr_rt5651.c
index c3b7732929cc..b0a4d297176e 100644
--- a/sound/soc/intel/boards/bytcr_rt5651.c
+++ b/sound/soc/intel/boards/bytcr_rt5651.c
@@ -844,74 +844,18 @@ static const struct x86_cpu_id cherrytrail_cpu_ids[] = {
{}
};
-static const struct acpi_gpio_params first_gpio = { 0, 0, false };
-static const struct acpi_gpio_params second_gpio = { 1, 0, false };
+static const struct acpi_gpio_params ext_amp_enable_gpios = { 0, 0, false };
-static const struct acpi_gpio_mapping byt_rt5651_amp_en_first[] = {
- { "ext-amp-enable-gpios", &first_gpio, 1 },
- { },
-};
-
-static const struct acpi_gpio_mapping byt_rt5651_amp_en_second[] = {
- { "ext-amp-enable-gpios", &second_gpio, 1 },
+static const struct acpi_gpio_mapping cht_rt5651_gpios[] = {
+ /*
+ * Some boards have I2cSerialBusV2, GpioIo, GpioInt as ACPI resources,
+ * other boards may have I2cSerialBusV2, GpioInt, GpioIo instead.
+ * We want the GpioIo one for the ext-amp-enable-gpio.
+ */
+ { "ext-amp-enable-gpios", &ext_amp_enable_gpios, 1, ACPI_GPIO_QUIRK_ONLY_GPIOIO },
{ },
};
-/*
- * Some boards have I2cSerialBusV2, GpioIo, GpioInt as ACPI resources, other
- * boards may have I2cSerialBusV2, GpioInt, GpioIo instead. We want the
- * GpioIo one for the ext-amp-enable-gpio and both count for the index in
- * acpi_gpio_params index. So we have 2 different mappings and the code
- * below figures out which one to use.
- */
-struct byt_rt5651_acpi_resource_data {
- int gpio_count;
- int gpio_int_idx;
-};
-
-static int snd_byt_rt5651_acpi_resource(struct acpi_resource *ares, void *arg)
-{
- struct byt_rt5651_acpi_resource_data *data = arg;
-
- if (ares->type != ACPI_RESOURCE_TYPE_GPIO)
- return 0;
-
- if (ares->data.gpio.connection_type == ACPI_RESOURCE_GPIO_TYPE_INT)
- data->gpio_int_idx = data->gpio_count;
-
- data->gpio_count++;
- return 0;
-}
-
-static void snd_byt_rt5651_mc_pick_amp_en_gpio_mapping(struct device *codec)
-{
- struct byt_rt5651_acpi_resource_data data = { 0, -1 };
- LIST_HEAD(resources);
- int ret;
-
- ret = acpi_dev_get_resources(ACPI_COMPANION(codec), &resources,
- snd_byt_rt5651_acpi_resource, &data);
- if (ret < 0) {
- dev_warn(codec, "Failed to get ACPI resources, not adding external amplifier GPIO mapping\n");
- return;
- }
-
- /* All info we need is gathered during the walk */
- acpi_dev_free_resource_list(&resources);
-
- switch (data.gpio_int_idx) {
- case 0:
- byt_rt5651_gpios = byt_rt5651_amp_en_second;
- break;
- case 1:
- byt_rt5651_gpios = byt_rt5651_amp_en_first;
- break;
- default:
- dev_warn(codec, "Unknown GpioInt index %d, not adding external amplifier GPIO mapping\n",
- data.gpio_int_idx);
- }
-}
-
struct acpi_chan_package { /* ACPICA seems to require 64 bit integers */
u64 aif_value; /* 1: AIF1, 2: AIF2 */
u64 mclock_value; /* usually 25MHz (0x17d7940), ignored */
@@ -1038,7 +982,7 @@ static int snd_byt_rt5651_mc_probe(struct platform_device *pdev)
/* Cherry Trail devices use an external amplifier enable gpio */
if (x86_match_cpu(cherrytrail_cpu_ids) && !byt_rt5651_gpios)
- snd_byt_rt5651_mc_pick_amp_en_gpio_mapping(codec_dev);
+ byt_rt5651_gpios = cht_rt5651_gpios;
if (byt_rt5651_gpios) {
devm_acpi_dev_add_driver_gpios(codec_dev, byt_rt5651_gpios);
diff --git a/sound/soc/intel/boards/kbl_da7219_max98927.c b/sound/soc/intel/boards/kbl_da7219_max98927.c
index 6dd5c69671b3..2768a572d065 100644
--- a/sound/soc/intel/boards/kbl_da7219_max98927.c
+++ b/sound/soc/intel/boards/kbl_da7219_max98927.c
@@ -2,7 +2,7 @@
// Copyright(c) 2018 Intel Corporation.
/*
- * Intel Kabylake I2S Machine Driver with MAX98927 & DA7219 Codecs
+ * Intel Kabylake I2S Machine Driver with MAX98927, MAX98373 & DA7219 Codecs
*
* Modified from:
* Intel Kabylake I2S Machine driver supporting MAX98927 and
@@ -24,8 +24,14 @@
#define KBL_DIALOG_CODEC_DAI "da7219-hifi"
#define MAX98927_CODEC_DAI "max98927-aif1"
-#define MAXIM_DEV0_NAME "i2c-MX98927:00"
-#define MAXIM_DEV1_NAME "i2c-MX98927:01"
+#define MAX98927_DEV0_NAME "i2c-MX98927:00"
+#define MAX98927_DEV1_NAME "i2c-MX98927:01"
+
+#define MAX98373_CODEC_DAI "max98373-aif1"
+#define MAX98373_DEV0_NAME "i2c-MX98373:00"
+#define MAX98373_DEV1_NAME "i2c-MX98373:01"
+
+
#define DUAL_CHANNEL 2
#define QUAD_CHANNEL 4
#define NAME_SIZE 32
@@ -176,20 +182,38 @@ static int kabylake_ssp0_hw_params(struct snd_pcm_substream *substream,
for (j = 0; j < runtime->num_codecs; j++) {
struct snd_soc_dai *codec_dai = runtime->codec_dais[j];
- if (!strcmp(codec_dai->component->name, MAXIM_DEV0_NAME)) {
+ if (!strcmp(codec_dai->component->name, MAX98927_DEV0_NAME)) {
ret = snd_soc_dai_set_tdm_slot(codec_dai, 0x30, 3, 8, 16);
if (ret < 0) {
dev_err(runtime->dev, "DEV0 TDM slot err:%d\n", ret);
return ret;
}
}
- if (!strcmp(codec_dai->component->name, MAXIM_DEV1_NAME)) {
+ if (!strcmp(codec_dai->component->name, MAX98927_DEV1_NAME)) {
ret = snd_soc_dai_set_tdm_slot(codec_dai, 0xC0, 3, 8, 16);
if (ret < 0) {
dev_err(runtime->dev, "DEV1 TDM slot err:%d\n", ret);
return ret;
}
}
+ if (!strcmp(codec_dai->component->name, MAX98373_DEV0_NAME)) {
+ ret = snd_soc_dai_set_tdm_slot(codec_dai,
+ 0x03, 3, 8, 24);
+ if (ret < 0) {
+ dev_err(runtime->dev,
+ "DEV0 TDM slot err:%d\n", ret);
+ return ret;
+ }
+ }
+ if (!strcmp(codec_dai->component->name, MAX98373_DEV1_NAME)) {
+ ret = snd_soc_dai_set_tdm_slot(codec_dai,
+ 0x0C, 3, 8, 24);
+ if (ret < 0) {
+ dev_err(runtime->dev,
+ "DEV0 TDM slot err:%d\n", ret);
+ return ret;
+ }
+ }
}
return 0;
@@ -213,6 +237,25 @@ static int kabylake_ssp_fixup(struct snd_soc_pcm_runtime *rtd,
struct snd_soc_dai_link *be_dai_link = dpcm->be->dai_link;
/*
+ * Topology for kblda7219m98373 & kblmax98373 supports only S24_LE,
+ * where as kblda7219m98927 & kblmax98927 supports S16_LE by default.
+ * Skipping the port wise FE and BE configuration for kblda7219m98373 &
+ * kblmax98373 as the topology (FE & BE) supports S24_LE only.
+ */
+
+ if (!strcmp(rtd->card->name, "kblda7219m98373") ||
+ !strcmp(rtd->card->name, "kblmax98373")) {
+ /* The ADSP will convert the FE rate to 48k, stereo */
+ rate->min = rate->max = 48000;
+ channels->min = channels->max = DUAL_CHANNEL;
+
+ /* set SSP to 24 bit */
+ snd_mask_none(fmt);
+ snd_mask_set_format(fmt, SNDRV_PCM_FORMAT_S24_LE);
+ return 0;
+ }
+
+ /*
* The ADSP will convert the FE rate to 48k, stereo, 24 bit
*/
if (!strcmp(fe_dai_link->name, "Kbl Audio Port") ||
@@ -352,20 +395,31 @@ static struct snd_pcm_hw_constraint_list constraints_channels_quad = {
static int kbl_fe_startup(struct snd_pcm_substream *substream)
{
struct snd_pcm_runtime *runtime = substream->runtime;
+ struct snd_soc_pcm_runtime *soc_rt = substream->private_data;
/*
* On this platform for PCM device we support,
* 48Khz
* stereo
- * 16 bit audio
*/
runtime->hw.channels_max = DUAL_CHANNEL;
snd_pcm_hw_constraint_list(runtime, 0, SNDRV_PCM_HW_PARAM_CHANNELS,
&constraints_channels);
-
- runtime->hw.formats = SNDRV_PCM_FMTBIT_S16_LE;
- snd_pcm_hw_constraint_msbits(runtime, 0, 16, 16);
+ /*
+ * Setup S24_LE (32 bit container and 24 bit valid data) for
+ * kblda7219m98373 & kblmax98373. For kblda7219m98927 &
+ * kblmax98927 keeping it as 16/16 due to topology FW dependency.
+ */
+ if (!strcmp(soc_rt->card->name, "kblda7219m98373") ||
+ !strcmp(soc_rt->card->name, "kblmax98373")) {
+ runtime->hw.formats = SNDRV_PCM_FMTBIT_S24_LE;
+ snd_pcm_hw_constraint_msbits(runtime, 0, 32, 24);
+
+ } else {
+ runtime->hw.formats = SNDRV_PCM_FMTBIT_S16_LE;
+ snd_pcm_hw_constraint_msbits(runtime, 0, 16, 16);
+ }
snd_pcm_hw_constraint_list(runtime, 0,
SNDRV_PCM_HW_PARAM_RATE, &constraints_rates);
@@ -398,11 +452,23 @@ static int kabylake_dmic_fixup(struct snd_soc_pcm_runtime *rtd,
static int kabylake_dmic_startup(struct snd_pcm_substream *substream)
{
struct snd_pcm_runtime *runtime = substream->runtime;
+ struct snd_soc_pcm_runtime *soc_rt = substream->private_data;
runtime->hw.channels_min = runtime->hw.channels_max = QUAD_CHANNEL;
snd_pcm_hw_constraint_list(runtime, 0, SNDRV_PCM_HW_PARAM_CHANNELS,
&constraints_channels_quad);
+ /*
+ * Topology for kblda7219m98373 & kblmax98373 supports only S24_LE.
+ * The DMIC also configured for S24_LE. Forcing the DMIC format to
+ * S24_LE due to the topology FW dependency.
+ */
+ if (!strcmp(soc_rt->card->name, "kblda7219m98373") ||
+ !strcmp(soc_rt->card->name, "kblmax98373")) {
+ runtime->hw.formats = SNDRV_PCM_FMTBIT_S24_LE;
+ snd_pcm_hw_constraint_msbits(runtime, 0, 32, 24);
+ }
+
return snd_pcm_hw_constraint_list(substream->runtime, 0,
SNDRV_PCM_HW_PARAM_RATE, &constraints_rates);
}
@@ -448,29 +514,55 @@ static struct snd_soc_ops skylake_refcap_ops = {
static struct snd_soc_codec_conf max98927_codec_conf[] = {
{
- .dev_name = MAXIM_DEV0_NAME,
+ .dev_name = MAX98927_DEV0_NAME,
+ .name_prefix = "Right",
+ },
+
+ {
+ .dev_name = MAX98927_DEV1_NAME,
+ .name_prefix = "Left",
+ },
+};
+
+static struct snd_soc_codec_conf max98373_codec_conf[] = {
+
+ {
+ .dev_name = MAX98373_DEV0_NAME,
.name_prefix = "Right",
},
{
- .dev_name = MAXIM_DEV1_NAME,
+ .dev_name = MAX98373_DEV1_NAME,
.name_prefix = "Left",
},
};
-static struct snd_soc_dai_link_component ssp0_codec_components[] = {
+static struct snd_soc_dai_link_component max98927_ssp0_codec_components[] = {
{ /* Left */
- .name = MAXIM_DEV0_NAME,
+ .name = MAX98927_DEV0_NAME,
.dai_name = MAX98927_CODEC_DAI,
},
{ /* For Right */
- .name = MAXIM_DEV1_NAME,
+ .name = MAX98927_DEV1_NAME,
.dai_name = MAX98927_CODEC_DAI,
},
};
+static struct snd_soc_dai_link_component max98373_ssp0_codec_components[] = {
+ { /* Left */
+ .name = MAX98373_DEV0_NAME,
+ .dai_name = MAX98373_CODEC_DAI,
+ },
+
+ { /* For Right */
+ .name = MAX98373_DEV1_NAME,
+ .dai_name = MAX98373_CODEC_DAI,
+ },
+
+};
+
/* kabylake digital audio interface glue - connects codec <--> CPU */
static struct snd_soc_dai_link kabylake_dais[] = {
/* Front End DAI links */
@@ -607,8 +699,8 @@ static struct snd_soc_dai_link kabylake_dais[] = {
.cpu_dai_name = "SSP0 Pin",
.platform_name = "0000:00:1f.3",
.no_pcm = 1,
- .codecs = ssp0_codec_components,
- .num_codecs = ARRAY_SIZE(ssp0_codec_components),
+ .codecs = max98927_ssp0_codec_components,
+ .num_codecs = ARRAY_SIZE(max98927_ssp0_codec_components),
.dai_fmt = SND_SOC_DAIFMT_DSP_B |
SND_SOC_DAIFMT_NB_NF |
SND_SOC_DAIFMT_CBS_CFS,
@@ -683,7 +775,7 @@ static struct snd_soc_dai_link kabylake_dais[] = {
};
/* kabylake digital audio interface glue - connects codec <--> CPU */
-static struct snd_soc_dai_link kabylake_max98927_dais[] = {
+static struct snd_soc_dai_link kabylake_max98_927_373_dais[] = {
/* Front End DAI links */
[KBL_DPCM_AUDIO_PB] = {
.name = "Kbl Audio Port",
@@ -802,8 +894,8 @@ static struct snd_soc_dai_link kabylake_max98927_dais[] = {
.cpu_dai_name = "SSP0 Pin",
.platform_name = "0000:00:1f.3",
.no_pcm = 1,
- .codecs = ssp0_codec_components,
- .num_codecs = ARRAY_SIZE(ssp0_codec_components),
+ .codecs = max98927_ssp0_codec_components,
+ .num_codecs = ARRAY_SIZE(max98927_ssp0_codec_components),
.dai_fmt = SND_SOC_DAIFMT_DSP_B |
SND_SOC_DAIFMT_NB_NF |
SND_SOC_DAIFMT_CBS_CFS,
@@ -917,8 +1009,8 @@ static struct snd_soc_card kbl_audio_card_da7219_m98927 = {
static struct snd_soc_card kbl_audio_card_max98927 = {
.name = "kblmax98927",
.owner = THIS_MODULE,
- .dai_link = kabylake_max98927_dais,
- .num_links = ARRAY_SIZE(kabylake_max98927_dais),
+ .dai_link = kabylake_max98_927_373_dais,
+ .num_links = ARRAY_SIZE(kabylake_max98_927_373_dais),
.controls = kabylake_controls,
.num_controls = ARRAY_SIZE(kabylake_controls),
.dapm_widgets = kabylake_widgets,
@@ -931,9 +1023,46 @@ static struct snd_soc_card kbl_audio_card_max98927 = {
.late_probe = kabylake_card_late_probe,
};
+static struct snd_soc_card kbl_audio_card_da7219_m98373 = {
+ .name = "kblda7219m98373",
+ .owner = THIS_MODULE,
+ .dai_link = kabylake_dais,
+ .num_links = ARRAY_SIZE(kabylake_dais),
+ .controls = kabylake_controls,
+ .num_controls = ARRAY_SIZE(kabylake_controls),
+ .dapm_widgets = kabylake_widgets,
+ .num_dapm_widgets = ARRAY_SIZE(kabylake_widgets),
+ .dapm_routes = kabylake_map,
+ .num_dapm_routes = ARRAY_SIZE(kabylake_map),
+ .codec_conf = max98373_codec_conf,
+ .num_configs = ARRAY_SIZE(max98373_codec_conf),
+ .fully_routed = true,
+ .late_probe = kabylake_card_late_probe,
+};
+
+static struct snd_soc_card kbl_audio_card_max98373 = {
+ .name = "kblmax98373",
+ .owner = THIS_MODULE,
+ .dai_link = kabylake_max98_927_373_dais,
+ .num_links = ARRAY_SIZE(kabylake_max98_927_373_dais),
+ .controls = kabylake_controls,
+ .num_controls = ARRAY_SIZE(kabylake_controls),
+ .dapm_widgets = kabylake_widgets,
+ .num_dapm_widgets = ARRAY_SIZE(kabylake_widgets),
+ .dapm_routes = kabylake_map,
+ .num_dapm_routes = ARRAY_SIZE(kabylake_map),
+ .codec_conf = max98373_codec_conf,
+ .num_configs = ARRAY_SIZE(max98373_codec_conf),
+ .fully_routed = true,
+ .late_probe = kabylake_card_late_probe,
+};
+
static int kabylake_audio_probe(struct platform_device *pdev)
{
struct kbl_codec_private *ctx;
+ struct snd_soc_dai_link *kbl_dai_link;
+ struct snd_soc_dai_link_component **codecs;
+ int i = 0;
ctx = devm_kzalloc(&pdev->dev, sizeof(*ctx), GFP_KERNEL);
if (!ctx)
@@ -944,6 +1073,22 @@ static int kabylake_audio_probe(struct platform_device *pdev)
kabylake_audio_card =
(struct snd_soc_card *)pdev->id_entry->driver_data;
+ kbl_dai_link = kabylake_audio_card->dai_link;
+
+ /* Update codecs for SSP0 with max98373 codec info */
+ if (!strcmp(pdev->name, "kbl_da7219_max98373") ||
+ (!strcmp(pdev->name, "kbl_max98373"))) {
+ for (i = 0; i < kabylake_audio_card->num_links; ++i) {
+ if (strcmp(kbl_dai_link[i].name, "SSP0-Codec"))
+ continue;
+
+ codecs = &(kbl_dai_link[i].codecs);
+ *codecs = max98373_ssp0_codec_components;
+ kbl_dai_link[i].num_codecs =
+ ARRAY_SIZE(max98373_ssp0_codec_components);
+ break;
+ }
+ }
kabylake_audio_card->dev = &pdev->dev;
snd_soc_card_set_drvdata(kabylake_audio_card, ctx);
@@ -961,13 +1106,23 @@ static const struct platform_device_id kbl_board_ids[] = {
.driver_data =
(kernel_ulong_t)&kbl_audio_card_max98927,
},
+ {
+ .name = "kbl_da7219_max98373",
+ .driver_data =
+ (kernel_ulong_t)&kbl_audio_card_da7219_m98373,
+ },
+ {
+ .name = "kbl_max98373",
+ .driver_data =
+ (kernel_ulong_t)&kbl_audio_card_max98373,
+ },
{ }
};
static struct platform_driver kabylake_audio = {
.probe = kabylake_audio_probe,
.driver = {
- .name = "kbl_da7219_max98927",
+ .name = "kbl_da7219_max98_927_373",
.pm = &snd_soc_pm_ops,
},
.id_table = kbl_board_ids,
@@ -976,8 +1131,10 @@ static struct platform_driver kabylake_audio = {
module_platform_driver(kabylake_audio)
/* Module information */
-MODULE_DESCRIPTION("Audio KabyLake Machine driver for MAX98927 & DA7219");
+MODULE_DESCRIPTION("Audio KabyLake Machine driver for MAX98927/MAX98373 & DA7219");
MODULE_AUTHOR("Mac Chiang <mac.chiang@intel.com>");
MODULE_LICENSE("GPL v2");
MODULE_ALIAS("platform:kbl_da7219_max98927");
MODULE_ALIAS("platform:kbl_max98927");
+MODULE_ALIAS("platform:kbl_da7219_max98373");
+MODULE_ALIAS("platform:kbl_max98373");
diff --git a/sound/soc/intel/common/soc-acpi-intel-bxt-match.c b/sound/soc/intel/common/soc-acpi-intel-bxt-match.c
index 61dedc103b19..229e39586868 100644
--- a/sound/soc/intel/common/soc-acpi-intel-bxt-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-bxt-match.c
@@ -51,9 +51,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_bxt_machines[] = {
.id = "INT343A",
.drv_name = "bxt_alc298s_i2s",
.fw_filename = "intel/dsp_fw_bxtn.bin",
- .sof_fw_filename = "intel/sof-apl.ri",
- .sof_tplg_filename = "intel/sof-apl-rt298.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-apl.ri",
+ .sof_tplg_filename = "sof-apl-rt298.tplg",
},
{
.id = "DLGS7219",
@@ -61,31 +60,27 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_bxt_machines[] = {
.fw_filename = "intel/dsp_fw_bxtn.bin",
.machine_quirk = snd_soc_acpi_codec_list,
.quirk_data = &bxt_codecs,
- .sof_fw_filename = "intel/sof-apl.ri",
- .sof_tplg_filename = "intel/sof-apl-da7219.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-apl.ri",
+ .sof_tplg_filename = "sof-apl-da7219.tplg",
},
{
.id = "104C5122",
.drv_name = "bxt-pcm512x",
- .sof_fw_filename = "intel/sof-apl.ri",
- .sof_tplg_filename = "intel/sof-apl-pcm512x.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-apl.ri",
+ .sof_tplg_filename = "sof-apl-pcm512x.tplg",
},
{
.id = "1AEC8804",
.drv_name = "bxt-wm8804",
- .sof_fw_filename = "intel/sof-apl.ri",
- .sof_tplg_filename = "intel/sof-apl-wm8804.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-apl.ri",
+ .sof_tplg_filename = "sof-apl-wm8804.tplg",
},
{
.id = "INT34C3",
.drv_name = "bxt_tdf8532",
.machine_quirk = apl_quirk,
- .sof_fw_filename = "intel/sof-apl.ri",
- .sof_tplg_filename = "intel/sof-apl-tdf8532.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-apl.ri",
+ .sof_tplg_filename = "sof-apl-tdf8532.tplg",
},
{},
};
diff --git a/sound/soc/intel/common/soc-acpi-intel-byt-match.c b/sound/soc/intel/common/soc-acpi-intel-byt-match.c
index 96f9c553fe6c..fe812a909db4 100644
--- a/sound/soc/intel/common/soc-acpi-intel-byt-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-byt-match.c
@@ -83,9 +83,8 @@ static struct snd_soc_acpi_mach byt_thinkpad_10 = {
.drv_name = "cht-bsw-rt5672",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5670.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5670.tplg",
};
static struct snd_soc_acpi_mach byt_pov_p1006w = {
@@ -93,9 +92,8 @@ static struct snd_soc_acpi_mach byt_pov_p1006w = {
.drv_name = "bytcr_rt5651",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcr_rt5651",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5651.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5651.tplg",
};
static struct snd_soc_acpi_mach *byt_quirk(void *arg)
@@ -136,63 +134,56 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_baytrail_machines[] = {
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcr_rt5640",
.machine_quirk = byt_quirk,
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5640.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5640.tplg",
},
{
.id = "10EC5642",
.drv_name = "bytcr_rt5640",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcr_rt5640",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5640.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5640.tplg",
},
{
.id = "INTCCFFD",
.drv_name = "bytcr_rt5640",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcr_rt5640",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5640.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5640.tplg",
},
{
.id = "10EC5651",
.drv_name = "bytcr_rt5651",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcr_rt5651",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5651.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5651.tplg",
},
{
.id = "DLGS7212",
.drv_name = "bytcht_da7213",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcht_da7213",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-da7213.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-da7213.tplg",
},
{
.id = "DLGS7213",
.drv_name = "bytcht_da7213",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcht_da7213",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-da7213.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-da7213.tplg",
},
{
.id = "ESSX8316",
.drv_name = "bytcht_es8316",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "bytcht_es8316",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-es8316.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-es8316.tplg",
},
/* some Baytrail platforms rely on RT5645, use CHT machine driver */
{
@@ -200,18 +191,16 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_baytrail_machines[] = {
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5645.tplg",
},
{
.id = "10EC5648",
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-rt5645.tplg",
},
/* use CHT driver to Baytrail Chromebooks */
{
@@ -219,9 +208,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_baytrail_machines[] = {
.drv_name = "cht-bsw-max98090",
.fw_filename = "intel/fw_sst_0f28.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-byt.ri",
- .sof_tplg_filename = "intel/sof-byt-max98090.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-byt.ri",
+ .sof_tplg_filename = "sof-byt-max98090.tplg",
},
#if IS_ENABLED(CONFIG_SND_SOC_INTEL_BYT_CHT_NOCODEC_MACH)
/*
diff --git a/sound/soc/intel/common/soc-acpi-intel-cht-match.c b/sound/soc/intel/common/soc-acpi-intel-cht-match.c
index 91bb99b69601..deafd87cc764 100644
--- a/sound/soc/intel/common/soc-acpi-intel-cht-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-cht-match.c
@@ -44,9 +44,8 @@ static struct snd_soc_acpi_mach cht_surface_mach = {
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5645.tplg",
};
static struct snd_soc_acpi_mach *cht_quirk(void *arg)
@@ -68,90 +67,80 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_cherrytrail_machines[] = {
.drv_name = "cht-bsw-rt5672",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5670.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5670.tplg",
},
{
.id = "10EC5672",
.drv_name = "cht-bsw-rt5672",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5670.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5670.tplg",
},
{
.id = "10EC5645",
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5645.tplg",
},
{
.id = "10EC5650",
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5645.tplg",
},
{
.id = "10EC3270",
.drv_name = "cht-bsw-rt5645",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5645.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5645.tplg",
},
{
.id = "193C9890",
.drv_name = "cht-bsw-max98090",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-max98090.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-max98090.tplg",
},
{
.id = "10508824",
.drv_name = "cht-bsw-nau8824",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "cht-bsw",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-nau8824.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-nau8824.tplg",
},
{
.id = "DLGS7212",
.drv_name = "bytcht_da7213",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcht_da7213",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-da7213.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-da7213.tplg",
},
{
.id = "DLGS7213",
.drv_name = "bytcht_da7213",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcht_da7213",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-da7213.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-da7213.tplg",
},
{
.id = "ESSX8316",
.drv_name = "bytcht_es8316",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcht_es8316",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-es8316.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-es8316.tplg",
},
/* some CHT-T platforms rely on RT5640, use Baytrail machine driver */
{
@@ -160,18 +149,16 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_cherrytrail_machines[] = {
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcr_rt5640",
.machine_quirk = cht_quirk,
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5640.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5640.tplg",
},
{
.id = "10EC3276",
.drv_name = "bytcr_rt5640",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcr_rt5640",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5640.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5640.tplg",
},
/* some CHT-T platforms rely on RT5651, use Baytrail machine driver */
{
@@ -179,9 +166,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_cherrytrail_machines[] = {
.drv_name = "bytcr_rt5651",
.fw_filename = "intel/fw_sst_22a8.bin",
.board = "bytcr_rt5651",
- .sof_fw_filename = "intel/sof-cht.ri",
- .sof_tplg_filename = "intel/sof-cht-rt5651.tplg",
- .asoc_plat_name = "sst-mfld-platform",
+ .sof_fw_filename = "sof-cht.ri",
+ .sof_tplg_filename = "sof-cht-rt5651.tplg",
},
#if IS_ENABLED(CONFIG_SND_SOC_INTEL_BYT_CHT_NOCODEC_MACH)
/*
diff --git a/sound/soc/intel/common/soc-acpi-intel-cnl-match.c b/sound/soc/intel/common/soc-acpi-intel-cnl-match.c
index ec8e28e7b937..a914dd238d0a 100644
--- a/sound/soc/intel/common/soc-acpi-intel-cnl-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-cnl-match.c
@@ -20,9 +20,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_cnl_machines[] = {
.drv_name = "cnl_rt274",
.fw_filename = "intel/dsp_fw_cnl.bin",
.pdata = &cnl_pdata,
- .sof_fw_filename = "intel/sof-cnl.ri",
- .sof_tplg_filename = "intel/sof-cnl-rt274.tplg",
- .asoc_plat_name = "0000:00:1f.3",
+ .sof_fw_filename = "sof-cnl.ri",
+ .sof_tplg_filename = "sof-cnl-rt274.tplg",
},
{},
};
diff --git a/sound/soc/intel/common/soc-acpi-intel-glk-match.c b/sound/soc/intel/common/soc-acpi-intel-glk-match.c
index 305875af71ca..3f2061475ae4 100644
--- a/sound/soc/intel/common/soc-acpi-intel-glk-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-glk-match.c
@@ -19,9 +19,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_glk_machines[] = {
.id = "INT343A",
.drv_name = "glk_alc298s_i2s",
.fw_filename = "intel/dsp_fw_glk.bin",
- .sof_fw_filename = "intel/sof-glk.ri",
- .sof_tplg_filename = "intel/sof-glk-alc298.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-glk.ri",
+ .sof_tplg_filename = "sof-glk-alc298.tplg",
},
{
.id = "DLGS7219",
@@ -29,9 +28,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_glk_machines[] = {
.fw_filename = "intel/dsp_fw_glk.bin",
.machine_quirk = snd_soc_acpi_codec_list,
.quirk_data = &glk_codecs,
- .sof_fw_filename = "intel/sof-glk.ri",
- .sof_tplg_filename = "intel/sof-glk-da7219.tplg",
- .asoc_plat_name = "0000:00:0e.0",
+ .sof_fw_filename = "sof-glk.ri",
+ .sof_tplg_filename = "sof-glk-da7219.tplg",
},
{},
};
diff --git a/sound/soc/intel/common/soc-acpi-intel-hda-match.c b/sound/soc/intel/common/soc-acpi-intel-hda-match.c
index 533c1064f84b..68ae43f7b4b2 100644
--- a/sound/soc/intel/common/soc-acpi-intel-hda-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-hda-match.c
@@ -23,7 +23,7 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_hda_machines[] = {
/* .sof_fw_filename is dynamically set in sof/intel driver */
- .sof_tplg_filename = "intel/sof-hda-generic.tplg",
+ .sof_tplg_filename = "sof-hda-generic.tplg",
/*
* .machine_quirk and .quirk_data are not used here but
diff --git a/sound/soc/intel/common/soc-acpi-intel-hsw-bdw-match.c b/sound/soc/intel/common/soc-acpi-intel-hsw-bdw-match.c
index 494a0ea9b029..690b305a255b 100644
--- a/sound/soc/intel/common/soc-acpi-intel-hsw-bdw-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-hsw-bdw-match.c
@@ -23,9 +23,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_haswell_machines[] = {
.id = "INT33CA",
.drv_name = "haswell-audio",
.fw_filename = "intel/IntcSST1.bin",
- .sof_fw_filename = "intel/sof-hsw.ri",
- .sof_tplg_filename = "intel/sof-hsw.tplg",
- .asoc_plat_name = "haswell-pcm-audio",
+ .sof_fw_filename = "sof-hsw.ri",
+ .sof_tplg_filename = "sof-hsw.tplg",
},
{}
};
@@ -36,25 +35,22 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_broadwell_machines[] = {
.id = "INT343A",
.drv_name = "broadwell-audio",
.fw_filename = "intel/IntcSST2.bin",
- .sof_fw_filename = "intel/sof-bdw.ri",
- .sof_tplg_filename = "intel/sof-bdw-rt286.tplg",
- .asoc_plat_name = "haswell-pcm-audio",
+ .sof_fw_filename = "sof-bdw.ri",
+ .sof_tplg_filename = "sof-bdw-rt286.tplg",
},
{
.id = "RT5677CE",
.drv_name = "bdw-rt5677",
.fw_filename = "intel/IntcSST2.bin",
- .sof_fw_filename = "intel/sof-bdw.ri",
- .sof_tplg_filename = "intel/sof-bdw-rt5677.tplg",
- .asoc_plat_name = "haswell-pcm-audio",
+ .sof_fw_filename = "sof-bdw.ri",
+ .sof_tplg_filename = "sof-bdw-rt5677.tplg",
},
{
.id = "INT33CA",
.drv_name = "haswell-audio",
.fw_filename = "intel/IntcSST2.bin",
- .sof_fw_filename = "intel/sof-bdw.ri",
- .sof_tplg_filename = "intel/sof-bdw-rt5640.tplg",
- .asoc_plat_name = "haswell-pcm-audio",
+ .sof_fw_filename = "sof-bdw.ri",
+ .sof_tplg_filename = "sof-bdw-rt5640.tplg",
},
{}
};
diff --git a/sound/soc/intel/common/soc-acpi-intel-icl-match.c b/sound/soc/intel/common/soc-acpi-intel-icl-match.c
index 33b441dca4d3..e5a6be5bc0ee 100644
--- a/sound/soc/intel/common/soc-acpi-intel-icl-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-icl-match.c
@@ -20,9 +20,8 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_icl_machines[] = {
.drv_name = "icl_rt274",
.fw_filename = "intel/dsp_fw_icl.bin",
.pdata = &icl_pdata,
- .sof_fw_filename = "intel/sof-icl.ri",
- .sof_tplg_filename = "intel/sof-icl-rt274.tplg",
- .asoc_plat_name = "0000:00:1f.3",
+ .sof_fw_filename = "sof-icl.ri",
+ .sof_tplg_filename = "sof-icl-rt274.tplg",
},
{},
};
diff --git a/sound/soc/intel/common/soc-acpi-intel-kbl-match.c b/sound/soc/intel/common/soc-acpi-intel-kbl-match.c
index e6fa6f470526..4b331058e807 100644
--- a/sound/soc/intel/common/soc-acpi-intel-kbl-match.c
+++ b/sound/soc/intel/common/soc-acpi-intel-kbl-match.c
@@ -37,6 +37,11 @@ static struct snd_soc_acpi_codecs kbl_7219_98927_codecs = {
.codecs = {"MX98927"}
};
+static struct snd_soc_acpi_codecs kbl_7219_98373_codecs = {
+ .num_codecs = 1,
+ .codecs = {"MX98373"}
+};
+
struct snd_soc_acpi_mach snd_soc_acpi_intel_kbl_machines[] = {
{
.id = "INT343A",
@@ -106,6 +111,20 @@ struct snd_soc_acpi_mach snd_soc_acpi_intel_kbl_machines[] = {
.drv_name = "kbl_rt5660",
.fw_filename = "intel/dsp_fw_kbl.bin",
},
+ {
+ .id = "DLGS7219",
+ .drv_name = "kbl_da7219_max98373",
+ .fw_filename = "intel/dsp_fw_kbl.bin",
+ .machine_quirk = snd_soc_acpi_codec_list,
+ .quirk_data = &kbl_7219_98373_codecs,
+ .pdata = &skl_dmic_data
+ },
+ {
+ .id = "MX98373",
+ .drv_name = "kbl_max98373",
+ .fw_filename = "intel/dsp_fw_kbl.bin",
+ .pdata = &skl_dmic_data
+ },
{},
};
EXPORT_SYMBOL_GPL(snd_soc_acpi_intel_kbl_machines);
diff --git a/sound/soc/intel/skylake/skl-pcm.c b/sound/soc/intel/skylake/skl-pcm.c
index 088e6b2fb1bc..1ae83f4ccc36 100644
--- a/sound/soc/intel/skylake/skl-pcm.c
+++ b/sound/soc/intel/skylake/skl-pcm.c
@@ -1459,6 +1459,7 @@ static const struct snd_soc_component_driver skl_component = {
.ops = &skl_platform_ops,
.pcm_new = skl_pcm_new,
.pcm_free = skl_pcm_free,
+ .ignore_module_refcount = 1, /* do not increase the refcount in core */
};
int skl_platform_register(struct device *dev)