Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=9d03280129e84f8cdfd83f84803a4548e3bf697d
Commit:     9d03280129e84f8cdfd83f84803a4548e3bf697d
Parent:     10b7a2bd6bf3510cbb5977a44d8822f085738729
Author:     Adrian Hunter <[EMAIL PROTECTED]>
AuthorDate: Wed Jan 10 07:51:26 2007 +0200
Committer:  Kyungmin Park <[EMAIL PROTECTED]>
CommitDate: Thu Jan 18 10:59:44 2007 +0900

    [MTD] OneNAND: Return an error if a read timeout occurs
    
    If OneNAND is operating within specification, all operations should easily 
be
    completed within the 20 millisecond timeout.
    This patch faithlessly adds a check for the timeout and returns an error in
    that case.
    
    Signed-off-by: Adrian Hunter <[EMAIL PROTECTED]>
    Signed-off-by: Kyungmin Park <[EMAIL PROTECTED]>
---
 drivers/mtd/onenand/onenand_base.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/mtd/onenand/onenand_base.c 
b/drivers/mtd/onenand/onenand_base.c
index d0f3118..ce1cbdc 100644
--- a/drivers/mtd/onenand/onenand_base.c
+++ b/drivers/mtd/onenand/onenand_base.c
@@ -333,6 +333,9 @@ static int onenand_wait(struct mtd_info *mtd, int state)
                        } else if (ecc & ONENAND_ECC_1BIT_ALL)
                                mtd->ecc_stats.corrected++;
                }
+       } else if (state == FL_READING) {
+               printk(KERN_ERR "onenand_wait: read timeout! ctrl=0x%04x 
intr=0x%04x\n", ctrl, interrupt);
+               return -EIO;
        }
 
        return 0;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to