Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drivers: gpio: xgene-sb: 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>

authored by

Enrico Weigelt, metux IT consult and committed by
Linus Walleij
6ff49fba df53665b

+1 -3
+1 -3
drivers/gpio/gpio-xgene-sb.c
··· 229 229 { 230 230 struct xgene_gpio_sb *priv; 231 231 int ret; 232 - struct resource *res; 233 232 void __iomem *regs; 234 233 struct irq_domain *parent_domain = NULL; 235 234 u32 val32; ··· 237 238 if (!priv) 238 239 return -ENOMEM; 239 240 240 - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 241 - regs = devm_ioremap_resource(&pdev->dev, res); 241 + regs = devm_platform_ioremap_resource(pdev, 0); 242 242 if (IS_ERR(regs)) 243 243 return PTR_ERR(regs); 244 244