tools: fit: add "/totalsize" property for itb size

Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I1aa87d5c0e1dd39762c470b134c4d8a57cab4f29
This commit is contained in:
Joseph Chen 2020-05-22 18:02:06 +08:00 committed by Jianhong Chen
parent c516743f40
commit eaa66b0d6a
1 changed files with 2 additions and 1 deletions

View File

@ -99,7 +99,8 @@ static int fit_add_file_data(struct image_tool_params *params, size_t size_inc,
/* for first image creation, add a timestamp at offset 0 i.e., root */
if (params->datafile) {
time_t time = imagetool_get_source_date(params, sbuf.st_mtime);
ret = fit_set_timestamp(ptr, 0, time);
ret = fit_set_timestamp(ptr, 0, time);
ret |= fit_set_totalsize(ptr, 0, sbuf.st_size);
}
if (!ret) {