summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/mvebu/pinctrl-mvebu.c
diff options
context:
space:
mode:
authorYueHaibing <yuehaibing@huawei.com>2019-10-16 16:12:17 +0200
committerLinus Walleij <linus.walleij@linaro.org>2019-10-24 14:04:13 +0200
commitfa679767addededcff5b35fadb95028542e3ff0a (patch)
tree3c69bea27ff59f793789316695473176c6e02109 /drivers/pinctrl/mvebu/pinctrl-mvebu.c
parentpinctrl: mediatek: use devm_platform_ioremap_resource() to simplify code (diff)
downloadlinux-fa679767addededcff5b35fadb95028542e3ff0a.tar.xz
linux-fa679767addededcff5b35fadb95028542e3ff0a.zip
pinctrl: mvebu: use devm_platform_ioremap_resource() to simplify code
Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Signed-off-by: YueHaibing <yuehaibing@huawei.com> Link: https://lore.kernel.org/r/20191016141217.21520-1-yuehaibing@huawei.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/mvebu/pinctrl-mvebu.c')
-rw-r--r--drivers/pinctrl/mvebu/pinctrl-mvebu.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/pinctrl/mvebu/pinctrl-mvebu.c b/drivers/pinctrl/mvebu/pinctrl-mvebu.c
index 00cfaf2c9d4a..a1f93859e7ca 100644
--- a/drivers/pinctrl/mvebu/pinctrl-mvebu.c
+++ b/drivers/pinctrl/mvebu/pinctrl-mvebu.c
@@ -759,12 +759,10 @@ int mvebu_pinctrl_simple_mmio_probe(struct platform_device *pdev)
{
struct mvebu_pinctrl_soc_info *soc = dev_get_platdata(&pdev->dev);
struct mvebu_mpp_ctrl_data *mpp_data;
- struct resource *res;
void __iomem *base;
int i;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- base = devm_ioremap_resource(&pdev->dev, res);
+ base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(base))
return PTR_ERR(base);