Commit 0598344d authored by Christophe JAILLET's avatar Christophe JAILLET Committed by Boris Brezillon

mtd: onenand: samsung: Propagate the error returned by 'onenand_scan()'

Propagate the error code returned by 'onenand_scan()' instead of a
hard-coded -EFAULT.
Signed-off-by: default avatarChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@free-electrons.com>
parent ad99be47
......@@ -922,8 +922,9 @@ static int s3c_onenand_probe(struct platform_device *pdev)
}
}
if (onenand_scan(mtd, 1))
return -EFAULT;
err = onenand_scan(mtd, 1);
if (err)
return err;
if (onenand->type != TYPE_S5PC110) {
/* S3C doesn't handle subpage write */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment