Commit f0063c4489a00ed5395378ef80a7edea4272f20b
Committed by
Jaroslav Kysela
1 parent
8b0c4149e8
Exists in
master
and in
20 other branches
[ALSA] intel8x0m - Free irq in suspend
Free the irq handler in suspend and reacquire in resume as well as intel8x0 audio driver does. Some devices may change the irq line dynamically during suspend/resume. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Showing 1 changed file with 5 additions and 0 deletions Side-by-side Diff
sound/pci/intel8x0m.c
... | ... | @@ -1045,6 +1045,8 @@ |
1045 | 1045 | for (i = 0; i < chip->pcm_devs; i++) |
1046 | 1046 | snd_pcm_suspend_all(chip->pcm[i]); |
1047 | 1047 | snd_ac97_suspend(chip->ac97); |
1048 | + if (chip->irq >= 0) | |
1049 | + free_irq(chip->irq, chip); | |
1048 | 1050 | pci_disable_device(pci); |
1049 | 1051 | pci_save_state(pci); |
1050 | 1052 | return 0; |
... | ... | @@ -1058,6 +1060,9 @@ |
1058 | 1060 | pci_restore_state(pci); |
1059 | 1061 | pci_enable_device(pci); |
1060 | 1062 | pci_set_master(pci); |
1063 | + request_irq(pci->irq, snd_intel8x0_interrupt, IRQF_DISABLED|IRQF_SHARED, | |
1064 | + card->shortname, chip); | |
1065 | + chip->irq = pci->irq; | |
1061 | 1066 | snd_intel8x0_chip_init(chip, 0); |
1062 | 1067 | snd_ac97_resume(chip->ac97); |
1063 | 1068 |