提交 76cda6ec 编写于 作者: L Laurent Navet 提交者: Linus Walleij

drivers: pinctrl: vt8500: use devm_ioremap_resource()

Replace a call to deprecated devm_request_and_ioremap by devm_ioremap_resource.

Found with coccicheck and this semantic patch:
 scripts/coccinelle/api/devm_ioremap_resource.cocci
Signed-off-by: NLaurent Navet <laurent.navet@gmail.com>
Acked-by: NTony Prisk <linux@prisktech.co.nz>
Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
上级 bbd7b275
......@@ -569,10 +569,10 @@ int wmt_pinctrl_probe(struct platform_device *pdev,
struct resource *res;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
data->base = devm_request_and_ioremap(&pdev->dev, res);
if (!data->base) {
data->base = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(data->base)) {
dev_err(&pdev->dev, "failed to map memory resource\n");
return -EBUSY;
return PTR_ERR(data->base);
}
wmt_desc.pins = data->pins;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册