diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2022-01-13 09:57:50 -0600 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2022-01-13 09:57:50 -0600 |
commit | 4ceca42d396eb5b7a80301e7d49a6d0012a17a43 (patch) | |
tree | e64d9f8b1247479107c989cadc2da6d519c0799f /drivers/pci | |
parent | f0eb209fed997810d7af807e660b60eadad38781 (diff) | |
parent | d2a14b54989e9ccea8401895fdfbc213bd1f56af (diff) |
Merge branch 'remotes/lorenzo/pci/rcar'
- Fix aarch32 abort handler so it doesn't check the wrong bus clock before
accessing the host controller (Marek Vasut)
* remotes/lorenzo/pci/rcar:
PCI: rcar: Check if device is runtime suspended instead of __clk_is_enabled()
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/controller/pcie-rcar-host.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/pci/controller/pcie-rcar-host.c b/drivers/pci/controller/pcie-rcar-host.c index e12c2d8be05a..780e60159993 100644 --- a/drivers/pci/controller/pcie-rcar-host.c +++ b/drivers/pci/controller/pcie-rcar-host.c @@ -50,10 +50,10 @@ struct rcar_msi { */ static void __iomem *pcie_base; /* - * Static copy of bus clock pointer, so we can check whether the clock - * is enabled or not. + * Static copy of PCIe device pointer, so we can check whether the + * device is runtime suspended or not. */ -static struct clk *pcie_bus_clk; +static struct device *pcie_dev; #endif /* Structure representing the PCIe interface */ @@ -792,7 +792,7 @@ static int rcar_pcie_get_resources(struct rcar_pcie_host *host) #ifdef CONFIG_ARM /* Cache static copy for L1 link state fixup hook on aarch32 */ pcie_base = pcie->base; - pcie_bus_clk = host->bus_clk; + pcie_dev = pcie->dev; #endif return 0; @@ -1062,7 +1062,7 @@ static int rcar_pcie_aarch32_abort_handler(unsigned long addr, spin_lock_irqsave(&pmsr_lock, flags); - if (!pcie_base || !__clk_is_enabled(pcie_bus_clk)) { + if (!pcie_base || pm_runtime_suspended(pcie_dev)) { ret = 1; goto unlock_exit; } |