PCI/PM: Do not restore BARs if device is not in D0
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 5 May 2022 18:14:24 +0000 (20:14 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Thu, 5 May 2022 19:19:49 +0000 (14:19 -0500)
commit0ce74a3b9c5255f641842df3c4c14fa8ea049a5a
treef29f6288d365dbb42feb170b353b252732a7fee5
parente200904b275c63dae711fca542f5fb20d162eb26
PCI/PM: Do not restore BARs if device is not in D0

Do not attempt to restore the device's BARs in
pci_set_full_power_state() if the actual current
power state of the device is not D0.

Link: https://lore.kernel.org/r/1849718.CQOukoFCf9@kreacher
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/pci.c