]> git.baikalelectronics.ru Git - kernel.git/commitdiff
iommu/ipmmu-vmsa: Remove dev_err() on platform_get_irq() failure
authorYueHaibing <yuehaibing@huawei.com>
Wed, 23 Oct 2019 13:59:41 +0000 (21:59 +0800)
committerJoerg Roedel <jroedel@suse.de>
Wed, 30 Oct 2019 09:16:37 +0000 (10:16 +0100)
platform_get_irq() will call dev_err() itself on failure,
so there is no need for the driver to also do this.
This is detected by coccinelle.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/ipmmu-vmsa.c

index 237103465b824c513722d67beb3135f21fbb00d0..2639fc7181171c4ab1db52bb0765c8f0a8b24bd6 100644 (file)
@@ -1105,10 +1105,8 @@ static int ipmmu_probe(struct platform_device *pdev)
        /* Root devices have mandatory IRQs */
        if (ipmmu_is_root(mmu)) {
                irq = platform_get_irq(pdev, 0);
-               if (irq < 0) {
-                       dev_err(&pdev->dev, "no IRQ found\n");
+               if (irq < 0)
                        return irq;
-               }
 
                ret = devm_request_irq(&pdev->dev, irq, ipmmu_irq, 0,
                                       dev_name(&pdev->dev), mmu);