Oh, the many joys of MTD...

David Woodhouse dwmw2 at infradead.org
Thu Mar 8 09:43:00 EST 2001


jacobs at penguin.theopalgroup.com said:
>  My first questions is likely something fairly basic.  I've read over
> much of the MTD source and it seems that many of the erase and write
> functions do not deal with concurrent access and CPU cache issues.
> What happens when a {read,write,erase} request comes in for a sector
> that is being {written,erased}?

See the state machine in cfi_cmdset_000[12].c. We wait until the operation 
which is currently in progress has completed. Theoretical support for 
interruption of erases and writes is there, but it's not yet implemented.

> Also, is it assumed that the memory mapped for MTD devices will not be
> cached by the CPU?  If so, is it feasible to add support.  If not,
> where is code to flush/update the cache after a write or erase
> operation? 

It's assumed that it won't be cached, you are correct. 

--
dwmw2




To unsubscribe, send "unsubscribe mtd" to majordomo at infradead.org



More information about the linux-mtd mailing list