Writing to flash problems
catlee at canada.com
Sat May 4 03:51:50 EDT 2002
After figuring out how to unlock my flash partition, I've been
experimenting with writing to it. Erasing the partition seems to work
I have a file which contains 2 characters:
First I erase the partition with eraseall /dev/mtd3
Then I write data to the partition with
mtd_debug write /dev/mtd3 0 2 data
I retrieve the data with
mtd_debug read /dev/mtd3 0 2 data.new
The contents of data.new is 2 characters:
Now, if I repeat the process (without erasing) with the data 22, the new
contents of data.new is 00.
So to me it looks like I have two problems: writing to the words
themselves is not functioning, and the only way to set bits to 1 is by
erasing ('0' == '1' & '2'). In fact, this is in the documentation for
the flash: "If users attempt to program "1"s, the memory cell contents
do not change and no error occurs."
So it looks like I need to erase before writing to fix my second
problem. I've tried putting in an erase command in do_write_oneword,
but I get timeout errors.
I'd really appreciate any pointers!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 232 bytes
Desc: This is a digitally signed message part
Url : http://lists.infradead.org/pipermail/linux-mtd/attachments/20020504/42737f00/attachment.bin
More information about the linux-mtd