aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/controller/dwc/pci-keystone.c
diff options
context:
space:
mode:
authorDejin Zheng <zhengdejin5@gmail.com>2020-07-09 00:40:13 +0800
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>2020-07-17 17:15:08 +0100
commit936fa5cd7b8e3e2a21b434d0f3ac29784ac69791 (patch)
tree616b839b76a4fb907d74f3b5fc0b105f7e557f6f /drivers/pci/controller/dwc/pci-keystone.c
parentPCI: qcom: Replace define with standard value (diff)
downloadlinux-dev-936fa5cd7b8e3e2a21b434d0f3ac29784ac69791.tar.xz
linux-dev-936fa5cd7b8e3e2a21b434d0f3ac29784ac69791.zip
PCI: dwc: Convert to devm_platform_ioremap_resource_byname()
Use devm_platform_ioremap_resource_byname() to simplify the code since it contains platform_get_resource_byname() and devm_ioremap_resource() respectively. Link: https://lore.kernel.org/r/20200708164013.5076-1-zhengdejin5@gmail.com Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Reviewed-by: Gustavo Pimentel <gustavo.pimentel@synopsys.com> Reviewed-by: Rob Herring <robh@kernel.org>
Diffstat (limited to 'drivers/pci/controller/dwc/pci-keystone.c')
-rw-r--r--drivers/pci/controller/dwc/pci-keystone.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c
index 790679fdfa48..00279002102e 100644
--- a/drivers/pci/controller/dwc/pci-keystone.c
+++ b/drivers/pci/controller/dwc/pci-keystone.c
@@ -1323,8 +1323,7 @@ static int __init ks_pcie_probe(struct platform_device *pdev)
}
if (pci->version >= 0x480A) {
- res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "atu");
- atu_base = devm_ioremap_resource(dev, res);
+ atu_base = devm_platform_ioremap_resource_byname(pdev, "atu");
if (IS_ERR(atu_base)) {
ret = PTR_ERR(atu_base);
goto err_get_sync;