android_kernel_xiaomi_sm8350/drivers/mtd/nand
Sergei Shtylyov 35af68b53a NAND: Fix NAND ECC errors on AMD Au1550
On AMD Au1550 the static bus controller fails to keep -CE asserted during
chip ready delay on read commands and the NAND chip being used requires this.
So, the current driver allows nand_base.c to drive -CE manually during the
entire sector read. When the PCMCIA driver is enabled however, occasionally
the ECC errors occur on NAND reads. This happens because the PCMCIA driver
polls sockets periodically and reads one of the board's control/status regs
(BCSRs) which are on the same static bus as the NAND flash, and just use
another chip select (and the NOR flash also resides on that bus), so as the
NAND driver forces NAND chip select asserted and the -RE signal is shared, a
contention occurs on the static bus when BCSR or NOR flash is read while we're
reading from NAND.
    So, we either can't keep interrupts enabled during the whole NAND sector
read (which is hardly acceptable), or have to implement some interlocking
scheme between multiple drivers (which is painful, and makes me shudder :-).
    There's a third way which has proven to work: to force -CE asserted only
while we're waiting for a NAND chip to become ready after a read command,
disabling interrupts for a maximum of 25 microseconds (according to Toshiba
TC58DVM92A1FT00 datasheet -- this chip is mentioned in the board schematics);
for Samsung NAND chip which seems to be actually used this delay is even less,
12 us.

Signed-off-by: Konstantin Baydarov <kbaidarov@ru.mvista.com>
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2006-05-16 18:03:18 +01:00
..
au1550nd.c NAND: Fix NAND ECC errors on AMD Au1550 2006-05-16 18:03:18 +01:00
autcpu12.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
cs553x_nand.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
diskonchip.c [MTD NAND] Indent all of drivers/mtd/nand/*.c. 2006-05-13 18:07:53 +01:00
edb7312.c [MTD] Fix legacy character sets throughout drivers/mtd, include/linux/mtd 2006-05-14 01:51:54 +01:00
h1910.c [MTD] Fix legacy character sets throughout drivers/mtd, include/linux/mtd 2006-05-14 01:51:54 +01:00
Kconfig [MTD] Add help text for MTD_NAND_CS553X option. 2006-05-16 13:11:47 +01:00
Makefile [MTD] Basic NAND driver for AMD/NatSemi CS5535/CS5536 Geode companion chip 2006-05-11 22:35:28 +01:00
nand_base.c [MTD NAND] Modify check for modules registering NAND devices without ->owner 2006-05-14 16:54:39 +01:00
nand_bbt.c [MTD NAND] Indent all of drivers/mtd/nand/*.c. 2006-05-13 18:07:53 +01:00
nand_ecc.c [MTD NAND] Indent all of drivers/mtd/nand/*.c. 2006-05-13 18:07:53 +01:00
nand_ids.c [MTD NAND] Indent all of drivers/mtd/nand/*.c. 2006-05-13 18:07:53 +01:00
nandsim.c [MTD] Fix module refcounting in NAND board drivers. 2006-05-14 01:20:46 +01:00
ppchameleonevb.c [MTD] Fix module refcounting in NAND board drivers. 2006-05-14 01:20:46 +01:00
rtc_from4.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
s3c2410.c [MTD] Fix module refcounting in NAND board drivers. 2006-05-14 01:20:46 +01:00
sharpsl.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
spia.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
toto.c [MTD NAND] Make various initfuncs static, remove #ifdef MODULE from exitfuncs 2006-05-16 13:54:50 +01:00
ts7250.c [MTD] Fix legacy character sets throughout drivers/mtd, include/linux/mtd 2006-05-14 01:51:54 +01:00