diff options
author | Enrico Weigelt, metux IT consult <info@metux.net> | 2019-03-11 21:54:58 +0300 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2019-04-04 20:04:26 +0300 |
commit | 329e23f9bc0a28fc58e3910b100358309a2d3156 (patch) | |
tree | 9a12f0815e458f541c10625df9544cb8b4275a8a /drivers/gpio/gpio-mb86s7x.c | |
parent | 47b4916cb4fb691d10bcb82185737c15291a27ac (diff) | |
download | linux-329e23f9bc0a28fc58e3910b100358309a2d3156.tar.xz |
drivers: gpio: mb86s7x: use devm_platform_ioremap_resource()
Use the new helper that wraps the calls to platform_get_resource()
and devm_ioremap_resource() together.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-mb86s7x.c')
-rw-r--r-- | drivers/gpio/gpio-mb86s7x.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/gpio/gpio-mb86s7x.c b/drivers/gpio/gpio-mb86s7x.c index 3134c0d2bfe4..9308081e0a4a 100644 --- a/drivers/gpio/gpio-mb86s7x.c +++ b/drivers/gpio/gpio-mb86s7x.c @@ -146,7 +146,6 @@ static void mb86s70_gpio_set(struct gpio_chip *gc, unsigned gpio, int value) static int mb86s70_gpio_probe(struct platform_device *pdev) { struct mb86s70_gpio_chip *gchip; - struct resource *res; int ret; gchip = devm_kzalloc(&pdev->dev, sizeof(*gchip), GFP_KERNEL); @@ -155,8 +154,7 @@ static int mb86s70_gpio_probe(struct platform_device *pdev) platform_set_drvdata(pdev, gchip); - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - gchip->base = devm_ioremap_resource(&pdev->dev, res); + gchip->base = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(gchip->base)) return PTR_ERR(gchip->base); |