Skip to content

Commit

Permalink
ALSA: hda_intel: fix build error when !PM
Browse files Browse the repository at this point in the history
Fix this build error when CONFIG_PM is not set:
ound/pci/hda/hda_intel.c: In function 'azx_bus_reset':
sound/pci/hda/hda_intel.c:1270: error: implicit declaration of function 'snd_pcm_suspend_all'
sound/pci/hda/hda_intel.c:1271: error: implicit declaration of function 'snd_hda_suspend'
sound/pci/hda/hda_intel.c:1272: error: implicit declaration of function 'snd_hda_resume'

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Alexander Beregalov authored and Takashi Iwai committed Jun 4, 2009
1 parent 018df41 commit 65f7598
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion sound/pci/hda/hda_intel.c
Original file line number Diff line number Diff line change
@@ -1260,17 +1260,20 @@ static void azx_stop_chip(struct azx *chip);
static void azx_bus_reset(struct hda_bus *bus)
{
struct azx *chip = bus->private_data;
int i;

bus->in_reset = 1;
azx_stop_chip(chip);
azx_init_chip(chip);
#ifdef CONFIG_PM
if (chip->initialized) {
int i;

for (i = 0; i < AZX_MAX_PCMS; i++)
snd_pcm_suspend_all(chip->pcm[i]);
snd_hda_suspend(chip->bus);
snd_hda_resume(chip->bus);
}
#endif
bus->in_reset = 0;
}

0 comments on commit 65f7598

Please sign in to comment.