]> Git Repo - J-linux.git/commitdiff
power: supply: da9150-fg: Remove unnecessary print function dev_err()
authorYang Li <[email protected]>
Tue, 1 Mar 2022 08:16:19 +0000 (16:16 +0800)
committerSebastian Reichel <[email protected]>
Fri, 4 Mar 2022 21:20:33 +0000 (22:20 +0100)
The print function dev_err() is redundant because
platform_get_irq_byname() already prints an error.

Eliminate the follow coccicheck warning:
./drivers/power/supply/da9150-fg.c:524:2-9: line 524 is redundant
because platform_get_irq() already prints an error

Reported-by: Abaci Robot <[email protected]>
Signed-off-by: Yang Li <[email protected]>
Reviewed-by: Adam Thomson <[email protected]>
Signed-off-by: Sebastian Reichel <[email protected]>
drivers/power/supply/da9150-fg.c

index e63fa62d19439c3fc9cae6f04779e44e764169c2..8c5e2c49d6c1c143e913530efff1243f88dceccf 100644 (file)
@@ -520,10 +520,8 @@ static int da9150_fg_probe(struct platform_device *pdev)
 
        /* Register IRQ */
        irq = platform_get_irq_byname(pdev, "FG");
-       if (irq < 0) {
-               dev_err(dev, "Failed to get IRQ FG: %d\n", irq);
+       if (irq < 0)
                return irq;
-       }
 
        ret = devm_request_threaded_irq(dev, irq, NULL, da9150_fg_irq,
                                        IRQF_ONESHOT, "FG", fg);
This page took 0.056072 seconds and 4 git commands to generate.