Flash left in a write mode

Allen Curtis acurtis at onz.com
Sat Feb 9 12:28:22 EST 2002


> Define 'rebooted'? Hitting the reset button if you have one should reset
> the flash (although sometimes it doesn't - bogus f***wit points
> to whoever
> designed the Assabet for that one)
>
> If you're implementing machine_restart() for your platform, then
> it should
> be ensuring that the hardware is in a state sufficiently close to the
> power-up state, for the benefit of the bootloader. That means turning off
> the MMU and jumping to the startup vector, at the very least. Often it
> means resetting bus controllers where we've moved around the physical
> memory map too - it could be argued that this preparation should include
> resetting the flash too.

This is a normal reboot operation. Calling machine_restart() and jumping
into the boot ROM. I don't believe that this is the proper place to reset
the flash or any other optional feature of a system. All cleanup operations
for optional components should be localized to that components
implementation.

> I'll consider if it a clean patch is presented - but I'm not going to go
> out of my way to fix it myself - I don't consider it particularly broken.

I will work on a fix that is implemented with the rest of the driver code.
As for being broken, it is.... I don't have to patch my hard driver code to
get the system to reboot reliably. My guess is that may of the users of
these libraries are embedded systems programmers, who do not have hard
drives and are using the flash as their root file system. If your primary
boot device does not work reliably, it is broken.





More information about the linux-mtd mailing list