ALSA: hda: beep - add missing cancel_delayed_work

The unregister work should be also canceled in snd_hda_detach_beep_device()
function.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Jaroslav Kysela 2009-11-04 12:46:49 +01:00 committed by Takashi Iwai
parent 13dab0808b
commit 5f81669750

View file

@ -239,6 +239,7 @@ void snd_hda_detach_beep_device(struct hda_codec *codec)
struct hda_beep *beep = codec->beep;
if (beep) {
cancel_work_sync(&beep->register_work);
cancel_delayed_work(&beep->unregister_work);
if (beep->enabled)
snd_hda_do_detach(beep);
codec->beep = NULL;