diff options
author | Ranjani Sridharan <ranjani.sridharan@linux.intel.com> | 2021-11-19 20:26:13 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-11-22 16:40:16 +0100 |
commit | 5974f6843203f0061d9df05c32262a10359740a6 (patch) | |
tree | 21722983f3d417806a48864b362132db3a98bd4b /sound/soc/sof/imx | |
parent | ASoC: SOF: Intel: hda: expose get_chip_info() (diff) | |
download | linux-5974f6843203f0061d9df05c32262a10359740a6.tar.xz linux-5974f6843203f0061d9df05c32262a10359740a6.zip |
ASoC: SOF: Introduce num_cores and ref count per core
Add two fields num_cores and dsp_cores_ref_count to
struct snd_sof_dev. These will be used to maintain the
ref count for each core to determine when it should be
powered up or down.
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20211119192621.4096077-3-kai.vehmanen@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/imx')
-rw-r--r-- | sound/soc/sof/imx/imx8.c | 1 | ||||
-rw-r--r-- | sound/soc/sof/imx/imx8m.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/sound/soc/sof/imx/imx8.c b/sound/soc/sof/imx/imx8.c index 0aeb44d0acc7..2d0448b3c8c3 100644 --- a/sound/soc/sof/imx/imx8.c +++ b/sound/soc/sof/imx/imx8.c @@ -188,6 +188,7 @@ static int imx8_probe(struct snd_sof_dev *sdev) if (!priv) return -ENOMEM; + sdev->num_cores = 1; sdev->pdata->hw_pdata = priv; priv->dev = sdev->dev; priv->sdev = sdev; diff --git a/sound/soc/sof/imx/imx8m.c b/sound/soc/sof/imx/imx8m.c index f454a5d0a87e..c94422323d67 100644 --- a/sound/soc/sof/imx/imx8m.c +++ b/sound/soc/sof/imx/imx8m.c @@ -108,6 +108,7 @@ static int imx8m_probe(struct snd_sof_dev *sdev) if (!priv) return -ENOMEM; + sdev->num_cores = 1; sdev->pdata->hw_pdata = priv; priv->dev = sdev->dev; priv->sdev = sdev; |