libflashrom
|
Functions | |
int | flashrom_image_read (struct flashrom_flashctx *flashctx, void *buffer, size_t buffer_len) |
Read the current image from the specified ROM chip. More... | |
int | flashrom_image_write (struct flashrom_flashctx *flashctx, void *buffer, size_t buffer_len, const void *refbuffer) |
Write the specified image to the ROM chip. More... | |
int | flashrom_image_verify (struct flashrom_flashctx *flashctx, const void *buffer, size_t buffer_len) |
Verify the ROM chip's contents with the specified image. More... | |
int flashrom_image_read | ( | struct flashrom_flashctx * | flashctx, |
void * | buffer, | ||
size_t | buffer_len | ||
) |
Read the current image from the specified ROM chip.
If a layout is set in the specified flash context, only included regions will be read.
flashctx | The context of the flash chip. |
buffer | Target buffer to write image to. |
buffer_len | Size of target buffer in bytes. |
int flashrom_image_verify | ( | struct flashrom_flashctx * | flashctx, |
const void * | buffer, | ||
size_t | buffer_len | ||
) |
Verify the ROM chip's contents with the specified image.
If a layout is set in the specified flash context, only included regions will be verified.
flashctx | The context of the flash chip. |
buffer | Source buffer to verify with. |
buffer_len | Size of source buffer in bytes. |
int flashrom_image_write | ( | struct flashrom_flashctx * | flashctx, |
void * | buffer, | ||
size_t | buffer_len, | ||
const void * | refbuffer | ||
) |
Write the specified image to the ROM chip.
If a layout is set in the specified flash context, only erase blocks containing included regions will be touched.
flashctx | The context of the flash chip. |
buffer | Source buffer to read image from (may be altered for full verification). |
buffer_len | Size of source buffer in bytes. |
refbuffer | If given, assume flash chip contains same data as refbuffer . |