Skip to content

Commit 81cfa59

Browse files
rafaeljwbjorn-helgaas
authored andcommitted
PCI/PM: Move power state update away from pci_power_up()
Move the invocation of pci_update_current_state() from pci_power_up() to pci_pm_default_resume_early(), which is the only caller of that function. Preparatory change, no functional impact. Link: https://lore.kernel.org/r/37482337.udjOGdOKNb@kreacher Signed-off-by: Rafael J. Wysocki <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Mika Westerberg <[email protected]>
1 parent 1a1daf0 commit 81cfa59

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

drivers/pci/pci-driver.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -531,6 +531,7 @@ static void pci_pm_default_resume(struct pci_dev *pci_dev)
531531
static void pci_pm_default_resume_early(struct pci_dev *pci_dev)
532532
{
533533
pci_power_up(pci_dev);
534+
pci_update_current_state(pci_dev, PCI_D0);
534535
pci_restore_state(pci_dev);
535536
pci_pme_restore(pci_dev);
536537
}

drivers/pci/pci.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1148,7 +1148,6 @@ void pci_power_up(struct pci_dev *dev)
11481148
{
11491149
__pci_start_power_transition(dev, PCI_D0);
11501150
pci_raw_set_power_state(dev, PCI_D0);
1151-
pci_update_current_state(dev, PCI_D0);
11521151
}
11531152

11541153
/**

0 commit comments

Comments
 (0)