瀏覽代碼

[ALSA] hda-intel - Fix resume with power save

The controller power wasn't turned on properly at resume due to the
power-saving patch.  Now fixed.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Takashi Iwai 17 年之前
父節點
當前提交
95e99fdadb
共有 2 個文件被更改,包括 2 次插入2 次删除
  1. 1 1
      sound/pci/hda/hda_codec.c
  2. 1 1
      sound/pci/hda/hda_intel.c

+ 1 - 1
sound/pci/hda/hda_codec.c

@@ -1662,6 +1662,7 @@ static void hda_call_codec_suspend(struct hda_codec *codec)
 			    AC_PWRST_D3);
 #ifdef CONFIG_SND_HDA_POWER_SAVE
 	cancel_delayed_work(&codec->power_work);
+	codec->power_on = 0;
 #endif
 }
 
@@ -2195,7 +2196,6 @@ static void hda_power_work(struct work_struct *work)
 		return;
 
 	hda_call_codec_suspend(codec);
-	codec->power_on = 0;
 	if (codec->bus->ops.pm_notify)
 		codec->bus->ops.pm_notify(codec);
 }

+ 1 - 1
sound/pci/hda/hda_intel.c

@@ -1500,7 +1500,7 @@ static int azx_acquire_irq(struct azx *chip, int do_disconnect)
 
 static void azx_stop_chip(struct azx *chip)
 {
-	if (chip->initialized)
+	if (!chip->initialized)
 		return;
 
 	/* disable interrupts */