From eb684507159de2162cd6fc62f2b3a671afd5a61d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Engel?= Date: Sat, 20 Oct 2007 23:16:32 +0200 Subject: [MTD] [NAND] Replace -1 with -EBADMSG in nand error correction code MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Magic numerical values are just bad style. Particularly so when undocumented. Signed-off-by: Jörn Engel Signed-off-by: David Woodhouse --- drivers/mtd/nand/nand_ecc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/mtd/nand/nand_ecc.c') diff --git a/drivers/mtd/nand/nand_ecc.c b/drivers/mtd/nand/nand_ecc.c index fde593e5e634..9003a135e050 100644 --- a/drivers/mtd/nand/nand_ecc.c +++ b/drivers/mtd/nand/nand_ecc.c @@ -189,7 +189,7 @@ int nand_correct_data(struct mtd_info *mtd, u_char *dat, if(countbits(s0 | ((uint32_t)s1 << 8) | ((uint32_t)s2 <<16)) == 1) return 1; - return -1; + return -EBADMSG; } EXPORT_SYMBOL(nand_correct_data); -- cgit v1.2.1