mirror of
https://review.coreboot.org/flashrom.git
synced 2025-07-01 14:11:15 +02:00
Add support for reading the current flash contents from a file
When developing software that has to be flashed to a flash chip to be executed, it often takes a long time to read the current flash contents (for flashrom to know what pages to erase and reprogram) each time when writing the new image. However, when the flash was just reprogrammed, its current state is known to be the previous image that was flashed (assuming it was verified). Thus, it makes sense to provide that image as a file for the flash contents instead of wasting valuable time read the whole flash each time. Change-Id: Idf153b6955f37779ae9bfb228a434ed10c304947 Signed-off-by: Mike Banon <mikebdp2@gmail.com> Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Reviewed-on: https://review.coreboot.org/23263 Reviewed-by: Nico Huber <nico.h@gmx.de> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:

committed by
Nico Huber

parent
3a826043db
commit
f701f34311
2
flash.h
2
flash.h
@ -329,7 +329,7 @@ int prepare_flash_access(struct flashctx *, bool read_it, bool write_it, bool er
|
||||
void finalize_flash_access(struct flashctx *);
|
||||
int do_read(struct flashctx *, const char *filename);
|
||||
int do_erase(struct flashctx *);
|
||||
int do_write(struct flashctx *, const char *const filename);
|
||||
int do_write(struct flashctx *, const char *const filename, const char *const referencefile);
|
||||
int do_verify(struct flashctx *, const char *const filename);
|
||||
|
||||
/* Something happened that shouldn't happen, but we can go on. */
|
||||
|
Reference in New Issue
Block a user