]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
PCI: starfive: Enable controller runtime PM before probing host bridge
authorMayank Rana <quic_mrana@quicinc.com>
Mon, 11 Nov 2024 08:41:52 +0000 (14:11 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Dec 2024 19:04:04 +0000 (20:04 +0100)
commitea1adfd7d0fc9ed8823ef5d99587dd42591d7f8c
tree64664904f754cac310f5e18b19964b7e7b7b9286
parent932a5f00a80885d235065dd85936138545435adc
PCI: starfive: Enable controller runtime PM before probing host bridge

[ Upstream commit 6168efbebace0db443185d4c6701ca8170a8788d ]

A PCI controller device, e.g., StarFive, is parent to PCI host bridge
device. We must enable runtime PM of the controller before enabling runtime
PM of the host bridge, which will happen in pci_host_probe(), to avoid this
warning:

  pcie-starfive 940000000.pcie: Enabling runtime PM for inactive device with active children

Fix this issue by enabling StarFive controller device's runtime PM before
calling pci_host_probe() in plda_pcie_host_init().

Link: https://lore.kernel.org/r/20241111-runtime_pm-v7-1-9c164eefcd87@quicinc.com
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Mayank Rana <quic_mrana@quicinc.com>
[bhelgaas: commit log]
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/pci/controller/plda/pcie-starfive.c