[PATCH 5.10.y-cip 06/11] memory: renesas-rpc-if: simplify platform_get_resource_byname()


Lad Prabhakar
 

From: Krzysztof Kozlowski <krzysztof.kozlowski@...>

commit 2ca47b33a7794ce92ae881d6d62affea953814cd upstream.

Use devm_platform_ioremap_resource_byname() instead of
platform_get_resource_byname() and devm_ioremap_resource().

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...>
Link: https://lore.kernel.org/r/20220419142859.380566-7-krzysztof.kozlowski@linaro.org
Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@...>
---
drivers/memory/renesas-rpc-if.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/memory/renesas-rpc-if.c b/drivers/memory/renesas-rpc-if.c
index 54ed31b862d4..6a096a033651 100644
--- a/drivers/memory/renesas-rpc-if.c
+++ b/drivers/memory/renesas-rpc-if.c
@@ -260,8 +260,7 @@ int rpcif_sw_init(struct rpcif *rpc, struct device *dev)

rpc->dev = dev;

- res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "regs");
- rpc->base = devm_ioremap_resource(&pdev->dev, res);
+ rpc->base = devm_platform_ioremap_resource_byname(pdev, "regs");
if (IS_ERR(rpc->base))
return PTR_ERR(rpc->base);

--
2.17.1