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: Yangtao Li <frank.li@xxxxxxxx> --- drivers/media/platform/marvell/mmp-driver.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/media/platform/marvell/mmp-driver.c b/drivers/media/platform/marvell/mmp-driver.c index e93feefb447b..1e9ad79e53e7 100644 --- a/drivers/media/platform/marvell/mmp-driver.c +++ b/drivers/media/platform/marvell/mmp-driver.c @@ -223,8 +223,7 @@ static int mmpcam_probe(struct platform_device *pdev) /* * Get our I/O memory. */ - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - mcam->regs = devm_ioremap_resource(&pdev->dev, res); + mcam->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(mcam->regs)) return PTR_ERR(mcam->regs); mcam->regs_size = resource_size(res); -- 2.39.0