diff options
author | Yang Li <yang.lee@linux.alibaba.com> | 2023-02-21 02:34:14 +0100 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2023-03-14 10:06:42 +0100 |
commit | e70a329832df84e25ed47cbdc5c96276331356b3 (patch) | |
tree | 86033981a6159cb57cdc39c8a11d10e3d599d48f /drivers/crypto/ccree | |
parent | crypto: aspeed - Use devm_platform_ioremap_resource() (diff) | |
download | linux-e70a329832df84e25ed47cbdc5c96276331356b3.tar.xz linux-e70a329832df84e25ed47cbdc5c96276331356b3.zip |
crypto: ccree - Use devm_platform_get_and_ioremap_resource()
Convert platform_get_resource(), devm_ioremap_resource() to a single
call to devm_platform_get_and_ioremap_resource(), as this is exactly
what this function does.
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Acked-by: Gilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/ccree')
-rw-r--r-- | drivers/crypto/ccree/cc_driver.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/crypto/ccree/cc_driver.c b/drivers/crypto/ccree/cc_driver.c index d489c6f80892..c57f929805d5 100644 --- a/drivers/crypto/ccree/cc_driver.c +++ b/drivers/crypto/ccree/cc_driver.c @@ -350,9 +350,9 @@ static int init_cc_resources(struct platform_device *plat_dev) /* Get device resources */ /* First CC registers space */ - req_mem_cc_regs = platform_get_resource(plat_dev, IORESOURCE_MEM, 0); /* Map registers space */ - new_drvdata->cc_base = devm_ioremap_resource(dev, req_mem_cc_regs); + new_drvdata->cc_base = devm_platform_get_and_ioremap_resource(plat_dev, + 0, &req_mem_cc_regs); if (IS_ERR(new_drvdata->cc_base)) return PTR_ERR(new_drvdata->cc_base); |