summaryrefslogtreecommitdiffstats
path: root/sound/pci/nm256/nm256.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-12-10 07:34:27 +0100
committerTakashi Iwai <tiwai@suse.de>2019-12-11 07:25:50 +0100
commit1478eb63654b367399f79edc0734a3bda1b0324b (patch)
tree733798eacb4950a9d6090b75a86a3552e4727865 /sound/pci/nm256/nm256.c
parentALSA: maestro3: Support PCM sync_stop (diff)
downloadlinux-1478eb63654b367399f79edc0734a3bda1b0324b.tar.xz
linux-1478eb63654b367399f79edc0734a3bda1b0324b.zip
ALSA: nm256: Support PCM sync_stop
The driver invokes snd_pcm_period_elapsed() simply from the interrupt handler. Set card->sync_irq for enabling the missing sync_stop PCM operation. It's cleared and reset dynamically at IRQ re-acquiring for the PM resume, too. Link: https://lore.kernel.org/r/20191210063454.31603-29-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to '')
-rw-r--r--sound/pci/nm256/nm256.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/pci/nm256/nm256.c b/sound/pci/nm256/nm256.c
index 02767f33deb7..ac194485aa78 100644
--- a/sound/pci/nm256/nm256.c
+++ b/sound/pci/nm256/nm256.c
@@ -460,6 +460,7 @@ static int snd_nm256_acquire_irq(struct nm256 *chip)
return -EBUSY;
}
chip->irq = chip->pci->irq;
+ chip->card->sync_irq = chip->irq;
}
chip->irq_acks++;
mutex_unlock(&chip->irq_mutex);
@@ -475,6 +476,7 @@ static void snd_nm256_release_irq(struct nm256 *chip)
if (chip->irq_acks == 0 && chip->irq >= 0) {
free_irq(chip->irq, chip);
chip->irq = -1;
+ chip->card->sync_irq = -1;
}
mutex_unlock(&chip->irq_mutex);
}