Skip to content

PCI PM refinements

Lukas Wunner linux-acpi linux-pci linux-pm 2 versions – Applied

Status from this message: I applied the patches above with Rafael's acks to pci/pm for v4.9, thanks,

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest5 patches 9 repliesApplied
  2. v14 patches 22 repliesSuperseded

Changes in v2 from the cover letter

* Patch [1/5] now sports an ack by Rafael.

* Patch [2/5]:
* In acpi_pci_get_power_state(), only check for ACPI_STATE_UNKNOWN instead of ACPI_STATE_D0 and ACPI_STATE_D3_COLD.
* Move the change to pci_update_current_state() to new patch [3/5].

* Patch [3/5]:
* Instead of solely relying on the platform firmware to report D3cold, also probe the vendor ID and assume D3cold if it can't be read. This should ensure proper detection of D3cold on pre-ACPI 4.0 platforms (which will never report anything deeper than D3hot) as well as for devices with nonstandard PM mechanisms.
* The two existing workarounds for D3cold are removed from pci_update_current_state(), as explained in the commit message.

* Patch [5/5]:
* Disable runtime PM on the device to prevent it from being runtime resumed during the remainder of the shutdown process.

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/5PCI: Afford direct-complete to devices with nonstandard PMdrivers/pci/pci.c+15 -20 replies
2/5PCI: Query platform firmware for device power statedrivers/pci/pci-acpi.c drivers/pci/pci.c drivers/pci/pci.h+33 -21 reply
3/5PCI: Recognize D3cold in pci_update_current_state()drivers/pci/pci.c+12 -131 reply
4/5PCI: Avoid unnecessary resume after direct-completedrivers/pci/pci-driver.c+13 -21 reply
5/5PCI: Avoid unnecessary resume on shutdowndrivers/pci/pci-driver.c+9 -04 replies

Reviews trailers per patch

4 of 5 patches have a Reviewed-by or Acked-by.

PatchRafael J. Wysocki
1/5A-b
2/5A-b
3/5A-b
4/5A-b
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/5] PCI PM refinements

Here's the second installment of this series, based on feedback from Rafael. (Thanks!)

To reiterate, these refinements are meant to speed up and reduce power consumption when entering and leaving system sleep and when shutting down the system. For details, please refer to the cover letter of v1:
http://www.spinics.net/lists/linux-pci/msg53702.html

As usual I've pushed the patches to GitHub in case anyone prefers reviewing in a GUI:
https://github.com/l1k/linux/commits/pci_pm_refinements_v2

Changes since v1:

* Patch [1/5] now sports an ack by Rafael.

* Patch [2/5]:
* In acpi_pci_get_power_state(), only check for ACPI_STATE_UNKNOWN instead of ACPI_STATE_D0 and ACPI_STATE_D3_COLD.
* Move the change to pci_update_current_state() to new patch [3/5].

* Patch [3/5]:
* Instead of solely relying on the platform firmware to report D3cold, also probe the vendor ID and assume D3cold if it can't be read. This should ensure proper detection of D3cold on pre-ACPI 4.0 platforms (which will never report anything deeper than D3hot) as well as for devices with nonstandard PM mechanisms.
* The two existing workarounds for D3cold are removed from pci_update_current_state(), as explained in the commit message.

* Patch [5/5]:
* Disable runtime PM on the device to prevent it from being runtime resumed during the remainder of the shutdown process.

Thanks,

Lukas

Lukas Wunner (5):
PCI: Afford direct-complete to devices with nonstandard PM
PCI: Query platform firmware for device power state
PCI: Recognize D3cold in pci_update_current_state()
PCI: Avoid unnecessary resume after direct-complete
PCI: Avoid unnecessary resume on shutdown

 drivers/pci/pci-acpi.c   | 22 ++++++++++++++++++++
 drivers/pci/pci-driver.c | 24 ++++++++++++++++++++--
 drivers/pci/pci.c        | 52 ++++++++++++++++++++++++++++++++----------------
 drivers/pci/pci.h        |  3 +++
 4 files changed, 82 insertions(+), 19 deletions(-)
Signature · 1 line
2.9.3