Commit 30862281 authored by Laurent Navet's avatar Laurent Navet Committed by Herbert Xu

drivers: crypto: use devm_ioremap_resource()

Replace calls to deprecated devm_request_and_ioremap by devm_ioremap_resource.

Found with coccicheck and this semantic patch:
 scripts/coccinelle/api/devm_request_and_ioremap.cocci.
Signed-off-by: default avatarLaurent Navet <laurent.navet@gmail.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 39761214
...@@ -1125,10 +1125,9 @@ static int omap_aes_probe(struct platform_device *pdev) ...@@ -1125,10 +1125,9 @@ static int omap_aes_probe(struct platform_device *pdev)
if (err) if (err)
goto err_res; goto err_res;
dd->io_base = devm_request_and_ioremap(dev, &res); dd->io_base = devm_ioremap_resource(dev, &res);
if (!dd->io_base) { if (IS_ERR(dd->io_base)) {
dev_err(dev, "can't ioremap\n"); err = PTR_ERR(dd->io_base);
err = -ENOMEM;
goto err_res; goto err_res;
} }
dd->phys_base = res.start; dd->phys_base = res.start;
......
...@@ -1686,10 +1686,9 @@ static int omap_sham_probe(struct platform_device *pdev) ...@@ -1686,10 +1686,9 @@ static int omap_sham_probe(struct platform_device *pdev)
if (err) if (err)
goto res_err; goto res_err;
dd->io_base = devm_request_and_ioremap(dev, &res); dd->io_base = devm_ioremap_resource(dev, &res);
if (!dd->io_base) { if (IS_ERR(dd->io_base)) {
dev_err(dev, "can't ioremap\n"); err = PTR_ERR(dd->io_base);
err = -ENOMEM;
goto res_err; goto res_err;
} }
dd->phys_base = res.start; dd->phys_base = res.start;
......
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