]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
ASoC: fsl_esai: Disable exception interrupt before scheduling tasklet
authorShengjiu Wang <shengjiu.wang@nxp.com>
Mon, 27 Apr 2020 06:23:21 +0000 (14:23 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 27 Apr 2020 12:06:31 +0000 (13:06 +0100)
Disable exception interrupt before scheduling tasklet, otherwise if
the tasklet isn't handled immediately, there will be endless xrun
interrupt.

Fixes: 7ccafa2b3879 ("ASoC: fsl_esai: recover the channel swap after xrun")
Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Acked-by: Nicolin Chen <nicoleotsuka@gmail.com>
Link: https://lore.kernel.org/r/a8f2ad955aac9e52587beedc1133b3efbe746895.1587968824.git.shengjiu.wang@nxp.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_esai.c

index c7a49d03463a7680dfaa3ce1222dc9bac0409cca..84290be778f0e9bc4f8f0d77e20dfaab6a0faa1a 100644 (file)
@@ -87,6 +87,10 @@ static irqreturn_t esai_isr(int irq, void *devid)
        if ((saisr & (ESAI_SAISR_TUE | ESAI_SAISR_ROE)) &&
            esai_priv->reset_at_xrun) {
                dev_dbg(&pdev->dev, "reset module for xrun\n");
+               regmap_update_bits(esai_priv->regmap, REG_ESAI_TCR,
+                                  ESAI_xCR_xEIE_MASK, 0);
+               regmap_update_bits(esai_priv->regmap, REG_ESAI_RCR,
+                                  ESAI_xCR_xEIE_MASK, 0);
                tasklet_schedule(&esai_priv->task);
        }