diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2018-03-09 20:06:53 +0300 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2018-03-12 17:15:39 +0300 |
commit | dcb0453d71e361d4718bb566d99e6ae498284419 (patch) | |
tree | 2bcbd1552a80d82d3588d56595e7ca09c872b6d7 /drivers/pci/pci.c | |
parent | ef7942603e35e300e6967fa7c17ebc17a0c00f59 (diff) | |
download | linux-dcb0453d71e361d4718bb566d99e6ae498284419.tar.xz |
PCI/PM: Move pcie_clear_root_pme_status() to core
Move pcie_clear_root_pme_status() from the port driver to the PCI core so
it will be available even when the port driver isn't present. No
functional change intended.
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/pci/pci.c')
-rw-r--r-- | drivers/pci/pci.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index f6a4dd10d9b0..120e3393fc35 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -1684,6 +1684,15 @@ int pci_set_pcie_reset_state(struct pci_dev *dev, enum pcie_reset_state state) EXPORT_SYMBOL_GPL(pci_set_pcie_reset_state); /** + * pcie_clear_root_pme_status - Clear root port PME interrupt status. + * @dev: PCIe root port or event collector. + */ +void pcie_clear_root_pme_status(struct pci_dev *dev) +{ + pcie_capability_set_dword(dev, PCI_EXP_RTSTA, PCI_EXP_RTSTA_PME); +} + +/** * pci_check_pme_status - Check if given device has generated PME. * @dev: Device to check. * |