ALSA: hda - Fix power-saving during playing beep sound
authorTakashi Iwai <tiwai@suse.de>
Mon, 18 Mar 2013 10:29:56 +0000 (11:29 +0100)
committerTakashi Iwai <tiwai@suse.de>
Mon, 18 Mar 2013 11:58:47 +0000 (12:58 +0100)
commite914b25e370a3a55a839ff507ed779f54431ace5
tree73779f18794bd94de2974cf3bd4530f21c4cbd8e
parent7504b6cd220a3dd8104abe3d0f985c6957dc3e17
ALSA: hda - Fix power-saving during playing beep sound

While playing the digital beep tone, the codec shouldn't be turned
off.  This patch adds proper snd_hda_power_up()/down() calls at each
time when the beep is played or off.

Also, this fixes automatically an unnecessary codec power-up at
detaching the beep device when the beep isn't being played.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/hda_beep.c
sound/pci/hda/hda_beep.h