Commit ca6a2489 authored by Matthieu CASTET's avatar Matthieu CASTET Committed by Artem Bityutskiy

mted: nand_wait_ready timeout fix

nand_wait_ready timeout should not assume HZ=100.
Make it independent of HZ value by using msecs_to_jiffies.
Signed-off-by: default avatarMatthieu CASTET <matthieu.castet@parrot.com>
Signed-off-by: default avatarArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
parent a6b3ed29
...@@ -490,7 +490,7 @@ static void panic_nand_wait_ready(struct mtd_info *mtd, unsigned long timeo) ...@@ -490,7 +490,7 @@ static void panic_nand_wait_ready(struct mtd_info *mtd, unsigned long timeo)
void nand_wait_ready(struct mtd_info *mtd) void nand_wait_ready(struct mtd_info *mtd)
{ {
struct nand_chip *chip = mtd->priv; struct nand_chip *chip = mtd->priv;
unsigned long timeo = jiffies + 2; unsigned long timeo = jiffies + msecs_to_jiffies(20);
/* 400ms timeout */ /* 400ms timeout */
if (in_interrupt() || oops_in_progress) if (in_interrupt() || oops_in_progress)
......
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