summaryrefslogtreecommitdiff
path: root/drivers/nand/nand_base.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/nand/nand_base.c')
-rw-r--r--drivers/nand/nand_base.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/nand/nand_base.c b/drivers/nand/nand_base.c
index 2e3fcdf..7fdf57b 100644
--- a/drivers/nand/nand_base.c
+++ b/drivers/nand/nand_base.c
@@ -838,9 +838,9 @@ static int nand_wait(struct mtd_info *mtd, struct nand_chip *this, int state)
unsigned long timeo;
if (state == FL_ERASING)
- timeo += (HZ * 400) / 1000;
+ timeo = (CFG_HZ * 400) / 1000;
else
- timeo += (HZ * 20) / 1000;
+ timeo = (CFG_HZ * 20) / 1000;
if ((state == FL_ERASING) && (this->options & NAND_IS_AND))
this->cmdfunc(mtd, NAND_CMD_STATUS_MULTI, -1, -1);
@@ -1713,6 +1713,7 @@ static int nand_write_ecc (struct mtd_info *mtd, loff_t to, size_t len,
goto out;
}
*retlen = written;
+ bufstart = (u_char*) &buf[written];
ofs = autoplace ? mtd->oobavail : mtd->oobsize;
if (eccbuf)