aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Moysan <olivier.moysan@st.com>2017-10-19 09:03:21 -0400
committerMark Brown <broonie@kernel.org>2017-10-21 06:17:49 -0400
commit47a8907d7c73fad81030655f09832fbb4446a2f5 (patch)
tree898f9931c0b84fd4b0e1a646c2031ab2007f7a95
parent61fb4ff70377cd2c49a3487bdb0156eba6930072 (diff)
ASoC: stm32: sai: Remove spurious IRQs on stop
Clear IRQ mask on stream stop to avoid spurious IRQs. Signed-off-by: Olivier Moysan <olivier.moysan@st.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/stm/stm32_sai_sub.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sound/soc/stm/stm32_sai_sub.c b/sound/soc/stm/stm32_sai_sub.c
index 815ef1036199..fd7dc7760f58 100644
--- a/sound/soc/stm/stm32_sai_sub.c
+++ b/sound/soc/stm/stm32_sai_sub.c
@@ -419,8 +419,6 @@ static int stm32_sai_startup(struct snd_pcm_substream *substream,
419 } 419 }
420 420
421 /* Enable ITs */ 421 /* Enable ITs */
422 regmap_update_bits(sai->regmap, STM_SAI_SR_REGX,
423 SAI_XSR_MASK, (unsigned int)~SAI_XSR_MASK);
424 422
425 regmap_update_bits(sai->regmap, STM_SAI_CLRFR_REGX, 423 regmap_update_bits(sai->regmap, STM_SAI_CLRFR_REGX,
426 SAI_XCLRFR_MASK, SAI_XCLRFR_MASK); 424 SAI_XCLRFR_MASK, SAI_XCLRFR_MASK);
@@ -693,6 +691,9 @@ static int stm32_sai_trigger(struct snd_pcm_substream *substream, int cmd,
693 case SNDRV_PCM_TRIGGER_STOP: 691 case SNDRV_PCM_TRIGGER_STOP:
694 dev_dbg(cpu_dai->dev, "Disable DMA and SAI\n"); 692 dev_dbg(cpu_dai->dev, "Disable DMA and SAI\n");
695 693
694 regmap_update_bits(sai->regmap, STM_SAI_IMR_REGX,
695 SAI_XIMR_MASK, 0);
696
696 regmap_update_bits(sai->regmap, STM_SAI_CR1_REGX, 697 regmap_update_bits(sai->regmap, STM_SAI_CR1_REGX,
697 SAI_XCR1_SAIEN, 698 SAI_XCR1_SAIEN,
698 (unsigned int)~SAI_XCR1_SAIEN); 699 (unsigned int)~SAI_XCR1_SAIEN);