diff options
author | Aaron Durbin <adurbin@chromium.org> | 2018-04-23 14:47:07 -0600 |
---|---|---|
committer | Aaron Durbin <adurbin@chromium.org> | 2018-04-24 14:39:36 +0000 |
commit | 3b16e78a9e1de3d3e03f43c69ae92fc27317bd94 (patch) | |
tree | bc4f6e730ff19bbcadbb4c131147e2c7ead87e26 | |
parent | c546c766c0a6525c07e51d0ee051a1080bf4cf62 (diff) |
lib/ext_stage_cache: include prog arg in stage cache metadata
In commit d87e4b34 (stage_cache: Add rmodule params in metadata)
the cbmem stage cache was updatd to keep track of the arg from
struct prog in the metadata. However, external stage cache did
not get the same change. Fix that.
BUG=b:72728953
Change-Id: Ifdaaa255cac0f413856410ff61bfb411a9554a31
Signed-off-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: https://review.coreboot.org/25794
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Justin TerAvest <teravest@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
-rw-r--r-- | src/lib/ext_stage_cache.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/ext_stage_cache.c b/src/lib/ext_stage_cache.c index ab783473f3..c3d4aee190 100644 --- a/src/lib/ext_stage_cache.c +++ b/src/lib/ext_stage_cache.c @@ -78,6 +78,7 @@ void stage_cache_add(int stage_id, const struct prog *stage) meta->load_addr = (uintptr_t)prog_start(stage); meta->entry_addr = (uintptr_t)prog_entry(stage); + meta->arg = (uintptr_t)prog_entry_arg(stage); e = imd_entry_add(imd, CBMEM_ID_STAGEx_CACHE + stage_id, prog_size(stage)); @@ -166,7 +167,8 @@ void stage_cache_load_stage(int stage_id, struct prog *stage) memcpy((void *)(uintptr_t)meta->load_addr, c, size); prog_set_area(stage, (void *)(uintptr_t)meta->load_addr, size); - prog_set_entry(stage, (void *)(uintptr_t)meta->entry_addr, NULL); + prog_set_entry(stage, (void *)(uintptr_t)meta->entry_addr, + (void *)(uintptr_t)meta->arg); } static void stage_cache_setup(int is_recovery) |