[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230525122112.647963-1-daniel.baluta@oss.nxp.com>
Date: Thu, 25 May 2023 15:21:12 +0300
From: Daniel Baluta <daniel.baluta@....nxp.com>
To: broonie@...nel.org, alsa-devel@...a-project.org
Cc: pierre-louis.bossart@...ux.intel.com, lgirdwood@...il.com,
yung-chuan.liao@...ux.intel.com, ranjani.sridharan@...ux.intel.com,
daniel.baluta@...il.com, kai.vehmanen@...ux.intel.com,
linux-imx@....com, linux-kernel@...r.kernel.org
Subject: [PATCH linux-nxp] ASoC: SOF: imx: Add OF machine descriptors for i.MX platforms
From: Paul Olaru <paul.olaru@....com>
Covered platforms: i.MX8QXP, i.MX8QM, i.MX8MP, i.MX8ULP.
These descriptors are used to locate the machine driver and topology
filenames.
Note: because the compatible values for the boards do not change between
the cs42888 and the wm8960 cases, I have selected a common topology
filename, which is intended to be a symlink to either the wm8960 or the
cs42888 topology file. For uniformity I did the same for i.MX8ULP.
Signed-off-by: Paul Olaru <paul.olaru@....com>
---
sound/soc/sof/imx/imx8.c | 16 ++++++++++++++++
sound/soc/sof/imx/imx8m.c | 10 ++++++++++
sound/soc/sof/imx/imx8ulp.c | 10 ++++++++++
3 files changed, 36 insertions(+)
diff --git a/sound/soc/sof/imx/imx8.c b/sound/soc/sof/imx/imx8.c
index 7e7d1f5c1147..2b91bfc8fb5b 100644
--- a/sound/soc/sof/imx/imx8.c
+++ b/sound/soc/sof/imx/imx8.c
@@ -624,7 +624,22 @@ static struct snd_sof_dsp_ops sof_imx8x_ops = {
SNDRV_PCM_INFO_NO_PERIOD_WAKEUP
};
+static struct snd_sof_of_mach sof_imx8_machs[] = {
+ {
+ .compatible = "fsl,imx8qxp",
+ .drv_name = "asoc-simple-card",
+ .sof_tplg_filename = "sof-imx8.tplg",
+ },
+ {
+ .compatible = "fsl,imx8qm",
+ .drv_name = "asoc-simple-card",
+ .sof_tplg_filename = "sof-imx8.tplg",
+ },
+ {}
+};
+
static struct sof_dev_desc sof_of_imx8qxp_desc = {
+ .of_machines = sof_imx8_machs,
.ipc_supported_mask = BIT(SOF_IPC),
.ipc_default = SOF_IPC,
.default_fw_path = {
@@ -641,6 +656,7 @@ static struct sof_dev_desc sof_of_imx8qxp_desc = {
};
static struct sof_dev_desc sof_of_imx8qm_desc = {
+ .of_machines = sof_imx8_machs,
.ipc_supported_mask = BIT(SOF_IPC),
.ipc_default = SOF_IPC,
.default_fw_path = {
diff --git a/sound/soc/sof/imx/imx8m.c b/sound/soc/sof/imx/imx8m.c
index d20011349b43..a05497eb8d89 100644
--- a/sound/soc/sof/imx/imx8m.c
+++ b/sound/soc/sof/imx/imx8m.c
@@ -487,7 +487,17 @@ static struct snd_sof_dsp_ops sof_imx8m_ops = {
SNDRV_PCM_INFO_NO_PERIOD_WAKEUP,
};
+static struct snd_sof_of_mach sof_imx8m_machs[] = {
+ {
+ .compatible = "fsl,imx8mp",
+ .drv_name = "asoc-simple-card",
+ .sof_tplg_filename = "sof-imx8m.tplg",
+ },
+ {}
+};
+
static struct sof_dev_desc sof_of_imx8mp_desc = {
+ .of_machines = sof_imx8m_machs,
.ipc_supported_mask = BIT(SOF_IPC),
.ipc_default = SOF_IPC,
.default_fw_path = {
diff --git a/sound/soc/sof/imx/imx8ulp.c b/sound/soc/sof/imx/imx8ulp.c
index 52c357ba570e..0c9878c2c420 100644
--- a/sound/soc/sof/imx/imx8ulp.c
+++ b/sound/soc/sof/imx/imx8ulp.c
@@ -496,7 +496,17 @@ static struct snd_sof_dsp_ops sof_imx8ulp_ops = {
.set_power_state = imx8ulp_dsp_set_power_state,
};
+static struct snd_sof_of_mach sof_imx8ulp_machs[] = {
+ {
+ .compatible = "fsl,imx8ulp",
+ .drv_name = "asoc-simple-card",
+ .sof_tplg_filename = "sof-imx8ulp.tplg",
+ },
+ {}
+};
+
static struct sof_dev_desc sof_of_imx8ulp_desc = {
+ .of_machines = sof_imx8ulp_machs,
.ipc_supported_mask = BIT(SOF_IPC),
.ipc_default = SOF_IPC,
.default_fw_path = {
--
2.40.1
Powered by blists - more mailing lists