Remove unneeded error handling on the result of a call
to platform_get_resource() when the value is passed to
devm_ioremap_resource().
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Acked-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: Corey Minyard <cminyard@mvista.com>
dev_set_drvdata(&pdev->dev, bt_bmc);
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- if (!res) {
- dev_err(dev, "Unable to find resources\n");
- return -ENXIO;
- }
-
bt_bmc->base = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(bt_bmc->base))
return PTR_ERR(bt_bmc->base);