summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>2022-04-21 15:31:51 -0500
committerMark Brown <broonie@kernel.org>2022-04-25 13:58:27 +0100
commitb44c99f11de2c9f01b5526e668c476de976fd14d (patch)
tree7a98e416754d4635af2ee290f9881707f849903e
parent309e6e557482415c32338b118f0eb17600d98060 (diff)
downloadlinux-stable-b44c99f11de2c9f01b5526e668c476de976fd14d.tar.gz
linux-stable-b44c99f11de2c9f01b5526e668c476de976fd14d.tar.bz2
linux-stable-b44c99f11de2c9f01b5526e668c476de976fd14d.zip
ASoC: SOF: Intel: hda-dai: simplify hda_dai_widget_update() prototype
the argument "struct sof_intel_hda_stream *hda_stream" is not used, remove. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://lore.kernel.org/r/20220421203201.1550328-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/sof/intel/hda-dai.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/sound/soc/sof/intel/hda-dai.c b/sound/soc/sof/intel/hda-dai.c
index 65f3ff519624..3113f61ae737 100644
--- a/sound/soc/sof/intel/hda-dai.c
+++ b/sound/soc/sof/intel/hda-dai.c
@@ -162,8 +162,7 @@ static int hda_link_dma_params(struct hdac_ext_stream *hext_stream,
return 0;
}
-static int hda_dai_widget_update(struct sof_intel_hda_stream *hda_stream,
- struct snd_soc_dapm_widget *w,
+static int hda_dai_widget_update(struct snd_soc_dapm_widget *w,
int channel, bool widget_setup)
{
struct snd_sof_dai_config_data data;
@@ -186,7 +185,6 @@ static int hda_dai_hw_params(struct snd_pcm_substream *substream,
struct hdac_ext_stream *hext_stream;
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
- struct sof_intel_hda_stream *hda_stream;
struct hda_pipe_params p_params = {0};
struct snd_soc_dapm_widget *w;
struct hdac_ext_link *link;
@@ -205,15 +203,13 @@ static int hda_dai_hw_params(struct snd_pcm_substream *substream,
stream_tag = hdac_stream(hext_stream)->stream_tag;
- hda_stream = hstream_to_sof_hda_stream(hext_stream);
-
if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
w = dai->playback_widget;
else
w = dai->capture_widget;
/* set up the DAI widget and send the DAI_CONFIG with the new tag */
- ret = hda_dai_widget_update(hda_stream, w, stream_tag - 1, true);
+ ret = hda_dai_widget_update(w, stream_tag - 1, true);
if (ret < 0)
return ret;
@@ -281,7 +277,6 @@ static int ipc3_hda_dai_trigger(struct snd_pcm_substream *substream,
{
struct hdac_ext_stream *hext_stream =
snd_soc_dai_get_dma_data(dai, substream);
- struct sof_intel_hda_stream *hda_stream;
struct snd_soc_pcm_runtime *rtd;
struct snd_soc_dapm_widget *w;
struct hdac_ext_link *link;
@@ -298,8 +293,6 @@ static int ipc3_hda_dai_trigger(struct snd_pcm_substream *substream,
if (!link)
return -EINVAL;
- hda_stream = hstream_to_sof_hda_stream(hext_stream);
-
dev_dbg(dai->dev, "In %s cmd=%d\n", __func__, cmd);
w = snd_soc_dai_get_widget(dai, substream->stream);
@@ -316,7 +309,7 @@ static int ipc3_hda_dai_trigger(struct snd_pcm_substream *substream,
/*
* free DAI widget during stop/suspend to keep widget use_count's balanced.
*/
- ret = hda_dai_widget_update(hda_stream, w, DMA_CHAN_INVALID, false);
+ ret = hda_dai_widget_update(w, DMA_CHAN_INVALID, false);
if (ret < 0)
return ret;
@@ -372,7 +365,7 @@ static int hda_dai_hw_free(struct snd_pcm_substream *substream,
w = dai->capture_widget;
/* free the link DMA channel in the FW and the DAI widget */
- ret = hda_dai_widget_update(hda_stream, w, DMA_CHAN_INVALID, false);
+ ret = hda_dai_widget_update(w, DMA_CHAN_INVALID, false);
if (ret < 0)
return ret;