linux-mips
[Top] [All Lists]

Re: [patch] cfi: prevent kernel panic with cfi flash

To: Jan Pedersen <jan.pedersen@glaze.dk>
Subject: Re: [patch] cfi: prevent kernel panic with cfi flash
From: Ralf Baechle <ralf@linux-mips.org>
Date: Fri, 30 Sep 2005 01:20:17 +0100
Cc: linux-mips@linux-mips.org
In-reply-to: <20050927192543.CAD8F376451@rocket.glaze.se>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20050927192543.CAD8F376451@rocket.glaze.se>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.4.2.1i
On Tue, Sep 27, 2005 at 09:25:42PM +0200, Jan Pedersen wrote:

> When using the cfi (common flash interface) driver, every word written to
> the flash chips is followed by a operation complete poll. This poll is
> intended to have a timeout of 1 ms. However this timeout is calculated by
> HZ/1000, which happends to be 0 because HZ < 1000. The result of this is
> that there will be just one poll for operation complete. If this single poll
> fails, the kernel panics. This patch increases this timeout to HZ (1
> second). This is far more than needed, but is preferred over a panic. This
> fix is well tested and completely avoids the panic.
> 
> Signed-off-by: Jan Pedersen <jp@jp-embedded.com>

Patch looks good to me - but this code isn't maintained by linux-mips.org,
so you may want to resend your patches here:

MEMORY TECHNOLOGY DEVICES
P:      David Woodhouse
M:      dwmw2@infradead.org
W:      http://www.linux-mtd.infradead.org/
L:      linux-mtd@lists.infradead.org
S:      Maintained

Thanks anyway,

  Ralf

<Prev in Thread] Current Thread [Next in Thread>