PCI: brcmstb: Disable/enable regulators in suspend/resume
authorJim Quinlan <jim2101024@gmail.com>
Mon, 25 Jul 2022 15:12:54 +0000 (11:12 -0400)
committerBjorn Helgaas <bhelgaas@google.com>
Wed, 27 Jul 2022 16:53:08 +0000 (11:53 -0500)
commit7a32e9b3ff01cdc12ea124fa258aacd31490dd11
treef98dbd6b58d8b5a847293d1fd7f0dca44bae469f
parent9e6be018b26347c26a93e63fb50a37ee2c9311de
PCI: brcmstb: Disable/enable regulators in suspend/resume

If we found power regulators for a device below the Root Port, disable them
during suspend and re-enable them during resume.

If any downstream device can be a wakeup device, do not turn off the
regulators as the device will need them on.

[bhelgaas: drop unused regulator_oops, skip wrapping of .add_bus()/
.remove_bus(), move brcm_pcie_start_link() to .add_bus() in previous patch,
squash WOL checking into this patch]
Link: https://lore.kernel.org/r/20220725151258.42574-6-jim2101024@gmail.com
Link: https://lore.kernel.org/r/20220725151258.42574-7-jim2101024@gmail.com
Signed-off-by: Jim Quinlan <jim2101024@gmail.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Tested-by: Florian Fainelli <f.fainelli@gmail.com>
drivers/pci/controller/pcie-brcmstb.c