Skip to content

Commit aebf1e2

Browse files
Minghao ChiDamien Le Moal
authored andcommitted
ata: pata_ep93xx: 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. Reported-by: Zeal Robot <[email protected]> Signed-off-by: Minghao Chi <[email protected]> Reviewed-by: Sergey Shtylyov <[email protected]> Signed-off-by: Damien Le Moal <[email protected]>
1 parent d5b560c commit aebf1e2

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/ata/pata_ep93xx.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -931,8 +931,7 @@ static int ep93xx_pata_probe(struct platform_device *pdev)
931931
goto err_rel_gpio;
932932
}
933933

934-
mem_res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
935-
ide_base = devm_ioremap_resource(&pdev->dev, mem_res);
934+
ide_base = devm_platform_get_and_ioremap_resource(pdev, 0, &mem_res);
936935
if (IS_ERR(ide_base)) {
937936
err = PTR_ERR(ide_base);
938937
goto err_rel_gpio;

0 commit comments

Comments
 (0)