public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/9] PCI/PM: Always disable PTM for all devices during suspend
@ 2022-09-09 20:24 Bjorn Helgaas
  2022-09-09 20:24 ` [PATCH v4 1/9] PCI/PTM: Cache PTM Capability offset Bjorn Helgaas
                   ` (9 more replies)
  0 siblings, 10 replies; 19+ messages in thread
From: Bjorn Helgaas @ 2022-09-09 20:24 UTC (permalink / raw)
  To: Kai-Heng Feng, Rajvi Jingar, Rafael J . Wysocki
  Cc: Koba Ko, Mika Westerberg, David E . Box,
	Sathyanarayanan Kuppuswamy, linux-pci, linux-pm, linux-kernel,
	Bjorn Helgaas

From: Bjorn Helgaas <bhelgaas@google.com>

We currently disable PTM for Root Ports during suspend.  Leaving PTM
enabled for downstream devices causes UR errors if they send PTM Requests
to upstream devices that have PTM disabled.

The intent of this series is to:

  - Unconditionally disable PTM during suspend (even if the driver saves
    its own state) by moving the disable from pci_prepare_to_sleep() to
    pci_pm_suspend().

  - Disable PTM for all devices by removing the Root Port condition and
    doing it early in the suspend paths.

  - Explicitly re-enable PTM during resume.

Changes between v3 and v4:
  - Use u16 for ptm_cap
  - Add kernel-doc for pci_enable_ptm() and pci_disable_ptm() (exported
    functions)
  - Drop "Preserve PTM Root Select" (unnecessary since enabling PTM sets
    Root Select when needed)
  - Squash these three patches into one because they make more sense that
    way:
	PCI/PTM: Add suspend/resume
	PCI/PTM: Add pci_enable_ptm() wrapper
	PCI/PTM: Add pci_disable_ptm() wrapper
  - Add "PCI/PTM: Preserve RsvdP bits in PTM Control register"
  - Add "PCI/PTM: Consolidate PTM interface declarations"

Bjorn Helgaas (9):
  PCI/PTM: Cache PTM Capability offset
  PCI/PTM: Add pci_upstream_ptm() helper
  PCI/PTM: Separate configuration and enable
  PCI/PTM: Add pci_suspend_ptm() and pci_resume_ptm()
  PCI/PTM: Move pci_ptm_info() body into its only caller
  PCI/PTM: Preserve RsvdP bits in PTM Control register
  PCI/PTM: Reorder functions in logical order
  PCI/PTM: Consolidate PTM interface declarations
  PCI/PM: Always disable PTM for all devices during suspend

 drivers/pci/pci-driver.c |  11 ++
 drivers/pci/pci.c        |  28 +--
 drivers/pci/pci.h        |  14 +-
 drivers/pci/pcie/ptm.c   | 384 +++++++++++++++++++++------------------
 include/linux/pci.h      |   3 +
 5 files changed, 234 insertions(+), 206 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 19+ messages in thread
[parent not found: <e58cbb3c-fcfe-edaa-f8ac-5cf502ea62a6@linux.intel.com>]

end of thread, other threads:[~2022-09-13  8:13 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-09 20:24 [PATCH v4 0/9] PCI/PM: Always disable PTM for all devices during suspend Bjorn Helgaas
2022-09-09 20:24 ` [PATCH v4 1/9] PCI/PTM: Cache PTM Capability offset Bjorn Helgaas
2022-09-09 23:38   ` Sathyanarayanan Kuppuswamy
2022-09-09 20:24 ` [PATCH v4 2/9] PCI/PTM: Add pci_upstream_ptm() helper Bjorn Helgaas
2022-09-09 23:38   ` Sathyanarayanan Kuppuswamy
2022-09-09 20:24 ` [PATCH v4 3/9] PCI/PTM: Separate configuration and enable Bjorn Helgaas
2022-09-09 20:25 ` [PATCH v4 4/9] PCI/PTM: Add pci_suspend_ptm() and pci_resume_ptm() Bjorn Helgaas
2022-09-09 23:44   ` Sathyanarayanan Kuppuswamy
2022-09-09 20:25 ` [PATCH v4 5/9] PCI/PTM: Move pci_ptm_info() body into its only caller Bjorn Helgaas
2022-09-09 23:45   ` Sathyanarayanan Kuppuswamy
2022-09-09 20:25 ` [PATCH v4 6/9] PCI/PTM: Preserve RsvdP bits in PTM Control register Bjorn Helgaas
2022-09-09 23:46   ` Sathyanarayanan Kuppuswamy
2022-09-09 20:25 ` [PATCH v4 7/9] PCI/PTM: Reorder functions in logical order Bjorn Helgaas
2022-09-09 20:25 ` [PATCH v4 8/9] PCI/PTM: Consolidate PTM interface declarations Bjorn Helgaas
2022-09-09 20:25 ` [PATCH v4 9/9] PCI/PM: Always disable PTM for all devices during suspend Bjorn Helgaas
2022-09-12  4:16 ` [PATCH v4 0/9] " Mika Westerberg
2022-09-12 20:36   ` Bjorn Helgaas
2022-09-13  8:13     ` Rafael J. Wysocki
     [not found] <e58cbb3c-fcfe-edaa-f8ac-5cf502ea62a6@linux.intel.com>
2022-09-12 20:32 ` Bjorn Helgaas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox