Odd behavior with non-linear mapping and CFI_0001
Marc Singer
elf at buici.com
Mon Oct 18 16:57:03 EDT 2004
On my target hardware, the flash is mapped in two discontiguous 8MiB
regions with an 8MiB gap between them. Initially, I used the physmap
driver and gave it the whole 24MiB region. The CFI driver correctly
recognized the two chips, at 0x0 and at 0x01000000. The chip data
structures were correct in that the chipshift and start addresses
correctly described the flash devices. I forcibly disabled the
point/unpoint methods because the cfi driver assumed that it was OK.
But there was a subtle problem. Periodically, the first chip would
become unreadable. It would get in a mode that I couldn't recognize
and I could not reset unless I cycled the target's power. Sending the
READARRAY command would not reset it. I could usually get it to
display the array status (which was 0x80), but it would not go back to
the READARRAY state.
I would have assumed that this was a hardware problem except that when
I wrote a new map driver to map the flash chips onto a contiguous
virtual memory region, the whole kit and kaboodle worked fine. I'm
now able to mount a jffs2 partition as /.
It seems to me that there could be something wonky in the cfi driver,
but I was never able to pin down the location where the array went
south.
Any comments?
Cheers.
More information about the linux-mtd
mailing list