Merge tag 'gpio-v5.2-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux...
[linux-2.6-microblaze.git] / drivers / gpio / gpio-lpc18xx.c
index d441dba..d711ae0 100644 (file)
@@ -340,10 +340,7 @@ static int lpc18xx_gpio_probe(struct platform_device *pdev)
        index = of_property_match_string(dev->of_node, "reg-names", "gpio");
        if (index < 0) {
                /* To support backward compatibility take the first resource */
-               struct resource *res;
-
-               res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-               gc->base = devm_ioremap_resource(dev, res);
+               gc->base = devm_platform_ioremap_resource(pdev, 0);
        } else {
                struct resource res;