Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 487d499c authored by Belen Sarabia's avatar Belen Sarabia Committed by Tejun Heo
Browse files

Delete redundant return value check of platform_get_resource()



Delete error handling from the result of a call to platform_get_resource()
when the value is immediately passed to devm_ioremap_resource().

Signed-off-by: default avatarBelen Sarabia <belensarabia@gmail.com>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent e3779f6a
Loading
Loading
Loading
Loading
+0 −5
Original line number Diff line number Diff line
@@ -38,11 +38,6 @@ static int ahci_octeon_probe(struct platform_device *pdev)
	int ret;

	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
	if (!res) {
		dev_err(&pdev->dev, "Platform resource[0] is missing\n");
		return -ENODEV;
	}

	base = devm_ioremap_resource(&pdev->dev, res);
	if (IS_ERR(base))
		return PTR_ERR(base);