Commit bc441bc8 authored by Laurent Navet's avatar Laurent Navet Committed by Marc Kleine-Budde

drivers: net: can: grcan: use devm_ioremap_resource()

Replace a call to deprecated devm_request_and_ioremap by devm_ioremap_resource.
dev_err() message is no more needed since it's already displayed in
devm_ioremap_resource().
Signed-off-by: default avatarLaurent Navet <laurent.navet@gmail.com>
Acked-by: default avatarAndreas Larsson <andreas@gaisler.com>
Signed-off-by: default avatarMarc Kleine-Budde <mkl@pengutronix.de>
parent dbbffe68
...@@ -1683,10 +1683,9 @@ static int grcan_probe(struct platform_device *ofdev) ...@@ -1683,10 +1683,9 @@ static int grcan_probe(struct platform_device *ofdev)
} }
res = platform_get_resource(ofdev, IORESOURCE_MEM, 0); res = platform_get_resource(ofdev, IORESOURCE_MEM, 0);
base = devm_request_and_ioremap(&ofdev->dev, res); base = devm_ioremap_resource(&ofdev->dev, res);
if (!base) { if (IS_ERR(base)) {
dev_err(&ofdev->dev, "couldn't map IO resource\n"); err = PTR_ERR(base);
err = -EADDRNOTAVAIL;
goto exit_error; goto exit_error;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment