mirror of
https://review.coreboot.org/flashrom.git
synced 2025-07-03 15:03:22 +02:00
libflashrom: Update the API for progress callback
The initial version of API for progress callback would require the
callback function to make a second call to get the needed data about
progress state (current, total etc).
This patch changes the callback API, so that callback function gets
all needed data straight away as parameters, and with this,
callback has all the data to do its job.
Since the initial version was submitted and it was in the tree for a
while, the change needs to add a _v2 suffix for new thing and
deprecated attribute for old thing.
Testing: both unit tests and cli are libflashrom clients.
All unit tests run successfully, for the cli all scenarios from
commit 75dc0655b9
run successfully.
Change-Id: Ia8cc0461c449b7e65888a64cdc594c55b81eae7a
Signed-off-by: Anastasia Klimchuk <aklm@flashrom.org>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/86031
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
Reviewed-by: Peter Marheine <pmarheine@chromium.org>
This commit is contained in:
@ -26,6 +26,6 @@ int open_logfile(const char * const filename);
|
||||
int close_logfile(void);
|
||||
void start_logging(void);
|
||||
int flashrom_print_cb(enum flashrom_log_level level, const char *fmt, va_list ap);
|
||||
void flashrom_progress_cb(struct flashrom_flashctx *flashctx);
|
||||
void flashrom_progress_cb(enum flashrom_progress_stage stage, size_t current, size_t total, void* user_data);
|
||||
|
||||
#endif /* __CLI_OUTPUT_H__ */
|
||||
|
Reference in New Issue
Block a user