Commit 4794601a authored by Ranjani Sridharan's avatar Ranjani Sridharan Committed by Mark Brown

ASoC: SOF: Intel: hda: reset stream before coupling host and link DMA's

The recommended programming sequence for HD-Audio DMA is to reset the
stream before coupling the link and host DMA's.
Signed-off-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: default avatarKai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20211125101520.291581-4-kai.vehmanen@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 2b1acedc
...@@ -659,6 +659,11 @@ int hda_dsp_stream_hw_free(struct snd_sof_dev *sdev, ...@@ -659,6 +659,11 @@ int hda_dsp_stream_hw_free(struct snd_sof_dev *sdev,
hstream); hstream);
struct hdac_bus *bus = sof_to_bus(sdev); struct hdac_bus *bus = sof_to_bus(sdev);
u32 mask = 0x1 << stream->index; u32 mask = 0x1 << stream->index;
int ret;
ret = hda_dsp_stream_reset(sdev, stream);
if (ret < 0)
return ret;
spin_lock_irq(&bus->reg_lock); spin_lock_irq(&bus->reg_lock);
/* couple host and link DMA if link DMA channel is idle */ /* couple host and link DMA if link DMA channel is idle */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment