diff options
author | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2014-12-27 13:08:54 +0200 |
---|---|---|
committer | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2014-12-28 19:58:35 +0100 |
commit | f9b8ed86dde6b9d5bb3f56259a7351ec6304f8ea (patch) | |
tree | f1e2af16f75897d814a321a65a5a6dc31bf2efc0 /util | |
parent | 78c622443e17a0b6d72142a9a8ed68069f22b745 (diff) |
cbfstool: Fix update-fit command
Regression in commit 3fcde22 caused parse_microcode_blob() to access
data outside cpu_microcode_blob.bin file in CBFS and create invalid
Intel Firmware Interface Table entries.
Change-Id: I1a687060084c2acd6cac5f5053b74a332b4ac714
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/7958
Tested-by: build bot (Jenkins)
Reviewed-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'util')
-rw-r--r-- | util/cbfstool/fit.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/cbfstool/fit.c b/util/cbfstool/fit.c index bf6c6d4dd5..0652129311 100644 --- a/util/cbfstool/fit.c +++ b/util/cbfstool/fit.c @@ -207,8 +207,8 @@ static int parse_microcode_blob(struct cbfs_image *image, uint32_t current_offset; uint32_t file_length; - current_offset = (int)((char *)mcode_file - image->buffer.data); fit_header(mcode_file, ¤t_offset, &file_length); + current_offset += (int)((char *)mcode_file - image->buffer.data); num_mcus = 0; while (file_length > sizeof(struct microcode_header)) |