linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/6] nand_wait_ready timeout fix
@ 2011-06-26 16:26 Matthieu CASTET
  2011-06-26 16:26 ` [PATCH 2/6] nand_wait : warn if the nand is busy on exit Matthieu CASTET
                   ` (5 more replies)
  0 siblings, 6 replies; 21+ messages in thread
From: Matthieu CASTET @ 2011-06-26 16:26 UTC (permalink / raw)
  To: linux-mtd; +Cc: Matthieu CASTET

nand_wait_ready timeout should not assume HZ=1000.
Make it independent of HZ value.

Signed-off-by: Matthieu CASTET <matthieu.castet@parrot.com>
---
 drivers/mtd/nand/nand_base.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c
index a46e9bb..a3c7fd3 100644
--- a/drivers/mtd/nand/nand_base.c
+++ b/drivers/mtd/nand/nand_base.c
@@ -512,7 +512,7 @@ static void panic_nand_wait_ready(struct mtd_info *mtd, unsigned long timeo)
 void nand_wait_ready(struct mtd_info *mtd)
 {
 	struct nand_chip *chip = mtd->priv;
-	unsigned long timeo = jiffies + 2;
+	unsigned long timeo = jiffies + (2 * HZ) / 1000;
 
 	/* 400ms timeout */
 	if (in_interrupt() || oops_in_progress)
-- 
1.7.5.4

^ permalink raw reply related	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2011-06-30 12:36 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-26 16:26 [PATCH 1/6] nand_wait_ready timeout fix Matthieu CASTET
2011-06-26 16:26 ` [PATCH 2/6] nand_wait : warn if the nand is busy on exit Matthieu CASTET
2011-06-28  7:57   ` Artem Bityutskiy
2011-06-28 15:03     ` Matthieu CASTET
2011-06-28 19:05       ` Artem Bityutskiy
2011-06-29 13:59         ` Ivan Djelic
2011-06-30 12:36           ` Artem Bityutskiy
2011-06-26 16:26 ` [PATCH 3/6] refactor mtd wait code Matthieu CASTET
2011-06-28  8:00   ` Artem Bityutskiy
2011-06-28  8:03     ` Artem Bityutskiy
2011-06-28 15:00       ` Matthieu CASTET
2011-06-29  6:09         ` Artem Bityutskiy
2011-06-26 16:26 ` [PATCH 4/6] nand_wait_read : add code to wait on status for LP Matthieu CASTET
2011-06-26 16:26 ` [PATCH 5/6] nand_flash_detect_onfi propagate busw info Matthieu CASTET
2011-06-29 16:38   ` Brian Norris
2011-06-30 11:47   ` Artem Bityutskiy
2011-06-26 16:26 ` [PATCH 6/6] add NAND_BUSWIDTH_AUTO Matthieu CASTET
2011-06-29 16:37   ` Brian Norris
2011-06-28  7:48 ` [PATCH 1/6] nand_wait_ready timeout fix Artem Bityutskiy
2011-06-28 15:09   ` Matthieu CASTET
2011-06-29  6:08     ` Artem Bityutskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).