linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux PM list <linux-pm@vger.kernel.org>,
	Len Brown <lenb@kernel.org>,
	Matthew Garrett <mjg59@srcf.ucam.org>,
	"Accardi, Kristen C" <kristen.c.accardi@intel.com>,
	"Huang, Ying" <ying.huang@intel.com>,
	linux-pci@vger.kernel.org
Subject: Re: [PATCH] PCI / ACPI: Always resume devices on ACPI wakeup notifications
Date: Mon, 25 Mar 2013 09:45:51 -0700	[thread overview]
Message-ID: <20130325164551.GA6869@xanatos> (raw)
In-Reply-To: <2282655.IicBMMa6jN@vostro.rjw.lan>

On Sat, Mar 23, 2013 at 03:33:03PM +0100, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> 
> It turns out that _Lxx control methods provided by some BIOSes clear
> the PME Status bit of PCI devices they handle, which means that
> pci_acpi_wake_dev() cannot really use that bit to check whether or
> not the device has signalled wakeup.
> 
> For this reason, make pci_acpi_wake_dev() always attempt to resume
> the device it is called for regardless of the device's PME Status bit
> value (that bit still has to be cleared if set at this point,
> though).
> 
> Reported-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

Should this be marked for stable?  I had this issue on 3.7 and 3.8 as
well.

Sarah

> ---
>  drivers/pci/pci-acpi.c |   15 ++++++++-------
>  1 file changed, 8 insertions(+), 7 deletions(-)
> 
> Index: linux-pm/drivers/pci/pci-acpi.c
> ===================================================================
> --- linux-pm.orig/drivers/pci/pci-acpi.c
> +++ linux-pm/drivers/pci/pci-acpi.c
> @@ -53,14 +53,15 @@ static void pci_acpi_wake_dev(acpi_handl
>  		return;
>  	}
>  
> -	if (!pci_dev->pm_cap || !pci_dev->pme_support
> -	     || pci_check_pme_status(pci_dev)) {
> -		if (pci_dev->pme_poll)
> -			pci_dev->pme_poll = false;
> +	/* Clear PME Status if set. */
> +	if (pci_dev->pme_support)
> +		pci_check_pme_status(pci_dev);
>  
> -		pci_wakeup_event(pci_dev);
> -		pm_runtime_resume(&pci_dev->dev);
> -	}
> +	if (pci_dev->pme_poll)
> +		pci_dev->pme_poll = false;
> +
> +	pci_wakeup_event(pci_dev);
> +	pm_runtime_resume(&pci_dev->dev);
>  
>  	if (pci_dev->subordinate)
>  		pci_pme_wakeup_bus(pci_dev->subordinate);
> 

  parent reply	other threads:[~2013-03-25 16:45 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-23 14:33 [PATCH] PCI / ACPI: Always resume devices on ACPI wakeup notifications Rafael J. Wysocki
2013-03-23 16:22 ` Matthew Garrett
2013-03-25 16:45 ` Sarah Sharp [this message]
2013-03-25 22:34   ` Rafael J. Wysocki
2013-03-28 17:10 ` [Resend][PATCH] " Rafael J. Wysocki
2013-03-28 21:07   ` [Update][PATCH] " Rafael J. Wysocki
2013-03-29 15:05     ` Martin Mokrejs
2013-03-29 16:05       ` Sarah Sharp
2013-03-29 17:11         ` Martin Mokrejs
2013-03-29 18:16           ` Martin Mokrejs
2013-03-29 21:37         ` Rafael J. Wysocki
2013-03-29 21:34       ` Rafael J. Wysocki
2013-04-03 22:38     ` Bjorn Helgaas
     [not found] ` <51548C9E.9090703@fold.natur.cuni.cz>
     [not found]   ` <2990024.LMTIBUbM3d@vostro.rjw.lan>
2013-03-30 22:38     ` [Update][PATCH] PCI / PM: Disable runtime PM of PCIe ports Rafael J. Wysocki
2013-04-01 17:34       ` Bjorn Helgaas
2013-04-01 20:51         ` Rafael J. Wysocki
2013-04-01 20:53           ` Bjorn Helgaas
2013-04-01 21:24             ` Rafael J. Wysocki
2013-04-01 23:20               ` Rafael J. Wysocki
2013-04-01 21:48             ` Martin Mokrejs
2013-04-02  5:34             ` huang ying
2013-04-02  5:28           ` huang ying
2013-04-02  5:31             ` huang ying
2013-04-03 22:34       ` Bjorn Helgaas
     [not found]     ` <51564804.9000700@fold.natur.cuni.cz>
     [not found]       ` <CAC=cRTMJH+40oPSM9pFzkb5x6Q42rWR8BPtUOxJn_3WopmOSvQ@mail.gmail.com>
     [not found]         ` <515AF312.1010507@fold.natur.cuni.cz>
     [not found]           ` <CAErSpo6EAkSniVF7NnDVsR=H_x0dHK=xQNbdKf67WDW=o1D+_Q@mail.gmail.com>
     [not found]             ` <515B17D9.6030805@fold.natur.cuni.cz>
2013-04-02 20:55               ` [PATCH] PCI / ACPI: Always resume devices on ACPI wakeup notifications Martin Mokrejs
2013-04-02 22:16                 ` Sarah Sharp
2013-04-03 10:35                   ` Martin Mokrejs
2013-04-03  2:34                 ` huang ying
2013-04-03 10:39                   ` Martin Mokrejs
2013-04-03 12:16                 ` Martin Mokrejs
2013-04-04 11:30                   ` Huang Ying
2013-04-04 19:19                     ` Sarah Sharp
2013-04-05 12:30                       ` Martin Mokrejs
2013-04-05 12:40                     ` Martin Mokrejs
2013-04-19 23:49                       ` Martin Mokrejs
2013-04-30 20:47                         ` Martin Mokrejs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130325164551.GA6869@xanatos \
    --to=sarah.a.sharp@linux.intel.com \
    --cc=bhelgaas@google.com \
    --cc=kristen.c.accardi@intel.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mjg59@srcf.ucam.org \
    --cc=rjw@sisk.pl \
    --cc=ying.huang@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).