From: Takashi Iwai Subject: Re: [PATCH 5/5] ALSA: hda - Make device D3 during runtime suspend Date: Tue, 26 Nov 2013 13:34:08 +0100 Message-ID: References: <1385454553-12000-1-git-send-email-tiwai@suse.de> <1385454553-12000-6-git-send-email-tiwai@suse.de> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 870322607D7 for ; Tue, 26 Nov 2013 13:34:08 +0100 (CET) Received: from relay1.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 69EA1A70DC for ; Tue, 26 Nov 2013 13:34:08 +0100 (CET) In-Reply-To: <1385454553-12000-6-git-send-email-tiwai@suse.de> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Tue, 26 Nov 2013 09:29:13 +0100, Takashi Iwai wrote: > > We can make the device D3 for saving more power during the runtime > suspend. Meanwhile, I observed that Haswell HDMI codecs gets > corrupted ELD bytes when woken up from runtime suspend with D3. > As a quick workaround, exclude these chips from D3. Scratch this. After reading the PCI core code, I found this patch is just a nonsense. Takashi > > Signed-off-by: Takashi Iwai > --- > sound/pci/hda/hda_intel.c | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > > diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c > index b001aa6da3bc..c0b2c9079607 100644 > --- a/sound/pci/hda/hda_intel.c > +++ b/sound/pci/hda/hda_intel.c > @@ -2997,6 +2997,13 @@ static int azx_runtime_suspend(struct device *dev) > if (!chip->bus->avoid_link_reset) > azx_enter_link_reset(chip); > azx_clear_irq_pending(chip); > + > + /* Haswell HDMI/DP shows the broken ELD read after runtime PM */ > + if (chip->driver_type != AZX_DRIVER_HDMI) { > + pci_save_state(chip->pci); > + pci_set_power_state(chip->pci, PCI_D3hot); > + } > + > if (chip->driver_caps & AZX_DCAPS_I915_POWERWELL) > hda_display_power(false); > return 0; > @@ -3019,6 +3026,11 @@ static int azx_runtime_resume(struct device *dev) > if (chip->driver_caps & AZX_DCAPS_I915_POWERWELL) > hda_display_power(true); > > + if (chip->driver_type != AZX_DRIVER_HDMI) { > + pci_set_power_state(chip->pci, PCI_D0); > + pci_restore_state(chip->pci); > + } > + > /* Read STATESTS before controller reset */ > status = azx_readw(chip, STATESTS); > > -- > 1.8.4.3 > > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@alsa-project.org > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel >