summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSameer Pujar <spujar@nvidia.com>2018-12-26 05:34:49 -0500
committerTakashi Iwai <tiwai@suse.de>2019-01-01 03:31:37 -0500
commit63d2a9ec310d8bcc955574220d4631aa55c1a80c (patch)
tree6cd81be4ee16f7a15f1a8565a8d246247490a30b
parent82b01149ec94d746867d7f9156c44d775d4d2d67 (diff)
ALSA: hda/tegra: clear pending irq handlers
Even after disabling interrupts on the module, it could be possible that irq handlers are still running. System hang is seen during suspend path. It was found that, there were pending writes on the HDA bus and clock was disabled by that time. Above mentioned issue is fixed by clearing any pending irq handlers before disabling clocks and returning from hda suspend. Suggested-by: Mohan Kumar <mkumard@nvidia.com> Suggested-by: Dara Ramesh <dramesh@nvidia.com> Signed-off-by: Sameer Pujar <spujar@nvidia.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r--sound/pci/hda/hda_tegra.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/pci/hda/hda_tegra.c b/sound/pci/hda/hda_tegra.c
index 83befd8d43e8..97a176d817a0 100644
--- a/sound/pci/hda/hda_tegra.c
+++ b/sound/pci/hda/hda_tegra.c
@@ -234,10 +234,12 @@ static int hda_tegra_suspend(struct device *dev)
234 struct snd_card *card = dev_get_drvdata(dev); 234 struct snd_card *card = dev_get_drvdata(dev);
235 struct azx *chip = card->private_data; 235 struct azx *chip = card->private_data;
236 struct hda_tegra *hda = container_of(chip, struct hda_tegra, chip); 236 struct hda_tegra *hda = container_of(chip, struct hda_tegra, chip);
237 struct hdac_bus *bus = azx_bus(chip);
237 238
238 snd_power_change_state(card, SNDRV_CTL_POWER_D3hot); 239 snd_power_change_state(card, SNDRV_CTL_POWER_D3hot);
239 240
240 azx_stop_chip(chip); 241 azx_stop_chip(chip);
242 synchronize_irq(bus->irq);
241 azx_enter_link_reset(chip); 243 azx_enter_link_reset(chip);
242 hda_tegra_disable_clocks(hda); 244 hda_tegra_disable_clocks(hda);
243 245