ALSA: hda - restore the gpio led after resume
[deliverable/linux.git] / sound / pci / hda / patch_realtek.c
index b32ce086d2e0e9544f4d382da2f84bd1dd8caae7..d71270a3f73f7ec1826397fe45c00e53fa143a1a 100644 (file)
@@ -3268,6 +3268,15 @@ static int alc269_resume(struct hda_codec *codec)
        snd_hda_codec_resume_cache(codec);
        alc_inv_dmic_sync(codec, true);
        hda_call_check_power_status(codec, 0x01);
+
+       /* on some machine, the BIOS will clear the codec gpio data when enter
+        * suspend, and won't restore the data after resume, so we restore it
+        * in the driver.
+        */
+       if (spec->gpio_led)
+               snd_hda_codec_write(codec, codec->afg, 0, AC_VERB_SET_GPIO_DATA,
+                           spec->gpio_led);
+
        if (spec->has_alc5505_dsp)
                alc5505_dsp_resume(codec);
 
This page took 0.025547 seconds and 5 git commands to generate.