drivers/mfd: don't check resource with devm_ioremap_resource
authorWolfram Sang <wsa@the-dreams.de>
Sun, 12 May 2013 13:19:49 +0000 (15:19 +0200)
committerWolfram Sang <wsa@the-dreams.de>
Sat, 18 May 2013 09:55:53 +0000 (11:55 +0200)
devm_ioremap_resource does sanity checks on the given resource. No need to
duplicate this in the driver.

Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/mfd/intel_msic.c

index 5be3b5e..d8d5137 100644 (file)
@@ -414,11 +414,6 @@ static int intel_msic_probe(struct platform_device *pdev)
         * the clients via intel_msic_irq_read().
         */
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-       if (!res) {
-               dev_err(&pdev->dev, "failed to get SRAM iomem resource\n");
-               return -ENODEV;
-       }
-
        msic->irq_base = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(msic->irq_base))
                return PTR_ERR(msic->irq_base);