From 29d9640bb537bbe0c37ffd672ff56b73e4aa3252 Mon Sep 17 00:00:00 2001 From: YueHaibing Date: Wed, 23 Oct 2019 21:57:10 +0800 Subject: mtd: rawnand: cadence: Remove dev_err() on platform_get_irq() failure 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 Signed-off-by: Miquel Raynal --- drivers/mtd/nand/raw/cadence-nand-controller.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers/mtd') diff --git a/drivers/mtd/nand/raw/cadence-nand-controller.c b/drivers/mtd/nand/raw/cadence-nand-controller.c index 91dabff4b09d..28a0426cb16e 100644 --- a/drivers/mtd/nand/raw/cadence-nand-controller.c +++ b/drivers/mtd/nand/raw/cadence-nand-controller.c @@ -2961,10 +2961,9 @@ static int cadence_nand_dt_probe(struct platform_device *ofdev) cdns_ctrl->dev = &ofdev->dev; cdns_ctrl->irq = platform_get_irq(ofdev, 0); - if (cdns_ctrl->irq < 0) { - dev_err(&ofdev->dev, "no irq defined\n"); + if (cdns_ctrl->irq < 0) return cdns_ctrl->irq; - } + dev_info(cdns_ctrl->dev, "IRQ: nr %d\n", cdns_ctrl->irq); cdns_ctrl->reg = devm_platform_ioremap_resource(ofdev, 0); -- cgit v1.2.1