Skip to content

Commit ff52c67

Browse files
Wei YongjunDavid Woodhouse
authored andcommitted
mtd: atmel_nand: fix error return code in atmel_nand_probe()
Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Acked-by: Josh Wu <josh.wu@atmel.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
1 parent 13134f4 commit ff52c67

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/mtd/nand/atmel_nand.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2048,6 +2048,7 @@ static int __init atmel_nand_probe(struct platform_device *pdev)
20482048
irq = platform_get_irq(pdev, 0);
20492049
if (irq < 0) {
20502050
dev_err(host->dev, "Cannot get HSMC irq!\n");
2051+
res = irq;
20512052
goto err_nand_ioremap;
20522053
}
20532054

0 commit comments

Comments
 (0)