imx-drm: imx-tve: Remove unneeded check for platform_get_resource()
authorFabio Estevam <fabio.estevam@freescale.com>
Mon, 22 Jul 2013 01:19:42 +0000 (22:19 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Jul 2013 20:35:22 +0000 (13:35 -0700)
As devm_ioremap_resource() is used on probe, there is no need to explicitly
check the return value from platform_get_resource(), as this is something that
devm_ioremap_resource() takes care by itself.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/imx-drm/imx-tve.c

index 0a1c6ab76344115d2a5c609495f8197c3a247fb0..12a3940de69543d54143df0b384a43cff429680d 100644 (file)
@@ -625,11 +625,6 @@ static int imx_tve_probe(struct platform_device *pdev)
        }
 
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-       if (!res) {
-               dev_err(&pdev->dev, "failed to get memory region\n");
-               return -ENOENT;
-       }
-
        base = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(base))
                return PTR_ERR(base);