summaryrefslogtreecommitdiff
path: root/drivers/pci/controller/pcie-brcmstb.c
diff options
context:
space:
mode:
authorDejin Zheng <zhengdejin5@gmail.com>2020-07-08 18:56:14 +0300
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>2020-07-10 13:50:23 +0300
commit3cf0eead9fb895dd91fc1fea0114ca0068d1c1a3 (patch)
tree107aec946adce5e80924a180d1cb3566777d2de8 /drivers/pci/controller/pcie-brcmstb.c
parente2dcd20b1645a7285b304bf6b9a1a6637f0f254a (diff)
downloadlinux-3cf0eead9fb895dd91fc1fea0114ca0068d1c1a3.tar.xz
PCI: controller: Convert to devm_platform_ioremap_resource()
Use devm_platform_ioremap_resource() to simplify the code, since t contains platform_get_resource() and devm_ioremap_resource() calls respectively. Link: https://lore.kernel.org/r/20200708155614.308-1-zhengdejin5@gmail.com Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Reviewed-by: Rob Herring <robh@kernel.org>
Diffstat (limited to 'drivers/pci/controller/pcie-brcmstb.c')
-rw-r--r--drivers/pci/controller/pcie-brcmstb.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/pci/controller/pcie-brcmstb.c b/drivers/pci/controller/pcie-brcmstb.c
index 15c747c1390a..91a4b7f3ee45 100644
--- a/drivers/pci/controller/pcie-brcmstb.c
+++ b/drivers/pci/controller/pcie-brcmstb.c
@@ -933,7 +933,6 @@ static int brcm_pcie_probe(struct platform_device *pdev)
struct pci_host_bridge *bridge;
struct device_node *fw_np;
struct brcm_pcie *pcie;
- struct resource *res;
int ret;
/*
@@ -958,8 +957,7 @@ static int brcm_pcie_probe(struct platform_device *pdev)
pcie->dev = &pdev->dev;
pcie->np = np;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- pcie->base = devm_ioremap_resource(&pdev->dev, res);
+ pcie->base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(pcie->base))
return PTR_ERR(pcie->base);