Skip to content

Commit 7322653

Browse files
Yang LiUlf Hansson
authored andcommitted
mmc: omap: Use devm_platform_get_and_ioremap_resource()
According to commit 890cc39 ("drivers: provide 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> Link: https://lore.kernel.org/r/20230315053434.38316-1-yang.lee@linux.alibaba.com Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
1 parent e3d1672 commit 7322653

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

drivers/mmc/host/omap.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1345,8 +1345,7 @@ static int mmc_omap_probe(struct platform_device *pdev)
13451345
if (irq < 0)
13461346
return -ENXIO;
13471347

1348-
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
1349-
host->virt_base = devm_ioremap_resource(&pdev->dev, res);
1348+
host->virt_base = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
13501349
if (IS_ERR(host->virt_base))
13511350
return PTR_ERR(host->virt_base);
13521351

0 commit comments

Comments
 (0)