[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190301085559.18736-1-andrew.smirnov@gmail.com>
Date: Fri, 1 Mar 2019 00:55:59 -0800
From: Andrey Smirnov <andrew.smirnov@...il.com>
To: Lorenzo Pieralisi <lorenzo.pieralisi@....com>
Cc: Andrey Smirnov <andrew.smirnov@...il.com>,
Trent Piepho <tpiepho@...inj.com>,
Bjorn Helgaas <bhelgaas@...gle.com>,
Chris Healy <cphealy@...il.com>,
Lucas Stach <l.stach@...gutronix.de>, linux-imx@....com,
linux-kernel@...r.kernel.org, linux-pci@...r.kernel.org
Subject: [PATCH] PCI: imx6: Don't request "pci_aux" clock on i.MX7
The clock in question is not present on i.MX7, so move the code
requesting it into i.MX8MQ-only path.
Fixes: eeb61c4e8530 ("PCI: imx6: Add code to request/control
"pcie_aux" clock for i.MX8MQ")
Reported-by: Trent Piepho <tpiepho@...inj.com>
Signed-off-by: Andrey Smirnov <andrew.smirnov@...il.com>
Cc: Bjorn Helgaas <bhelgaas@...gle.com>
Cc: Chris Healy <cphealy@...il.com>
Cc: Lucas Stach <l.stach@...gutronix.de>
Cc: Trent Piepho <tpiepho@...inj.com>
Cc: linux-imx@....com
Cc: linux-kernel@...r.kernel.org
Cc: linux-pci@...r.kernel.org
---
drivers/pci/controller/dwc/pci-imx6.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/pci/controller/dwc/pci-imx6.c b/drivers/pci/controller/dwc/pci-imx6.c
index 08f1ee050c73..5fe364a9959d 100644
--- a/drivers/pci/controller/dwc/pci-imx6.c
+++ b/drivers/pci/controller/dwc/pci-imx6.c
@@ -1100,8 +1100,14 @@ static int imx6_pcie_probe(struct platform_device *pdev)
return PTR_ERR(imx6_pcie->pcie_inbound_axi);
}
break;
- case IMX7D:
case IMX8MQ:
+ imx6_pcie->pcie_aux = devm_clk_get(dev, "pcie_aux");
+ if (IS_ERR(imx6_pcie->pcie_aux)) {
+ dev_err(dev, "pcie_aux clock source missing or invalid\n");
+ return PTR_ERR(imx6_pcie->pcie_aux);
+ }
+ /* fall through */
+ case IMX7D:
if (dbi_base->start == IMX8MQ_PCIE2_BASE_ADDR)
imx6_pcie->controller_id = 1;
@@ -1118,12 +1124,6 @@ static int imx6_pcie_probe(struct platform_device *pdev)
dev_err(dev, "Failed to get PCIE APPS reset control\n");
return PTR_ERR(imx6_pcie->apps_reset);
}
-
- imx6_pcie->pcie_aux = devm_clk_get(dev, "pcie_aux");
- if (IS_ERR(imx6_pcie->pcie_aux)) {
- dev_err(dev, "pcie_aux clock source missing or invalid\n");
- return PTR_ERR(imx6_pcie->pcie_aux);
- }
break;
default:
break;
--
2.20.1
Powered by blists - more mailing lists