On Wed, Apr 21, 2004 at 10:49:02AM -0600, Li-Ta Lo wrote:
On Wed, 2004-04-21 at 10:40, YhLu wrote:
- or I only want to update the payload image in the beginning, [0,64k).
you need some kind of flash translation layer to accomplish this. You need to back up some part of the erase block you want reserve , erase the block and write with updated and reserved data.
If the start and end positions are not aligned to block boundaries then flash_rom should just return an error.
It would be nice to be able to update a payload without having to burn the whole flash. (Rewriting the whole flash risks the possibility of an incomplete write which could leave the machine unbootable.) Of course, if the user wishes to do this then it should be the responsibility of the user to know the flash part and what boundaries to align the payloads.
-Kevin