diff options
Diffstat (limited to 'bl1/bl1_fwu.c')
-rw-r--r-- | bl1/bl1_fwu.c | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/bl1/bl1_fwu.c b/bl1/bl1_fwu.c index 25be5770..0fbdf515 100644 --- a/bl1/bl1_fwu.c +++ b/bl1/bl1_fwu.c @@ -86,11 +86,9 @@ register_t bl1_fwu_smc_handler(unsigned int smc_fid, case FWU_SMC_UPDATE_DONE: bl1_fwu_done((void *)x1, NULL); - /* We should never return from bl1_fwu_done() */ - break; default: - assert(0); + assert(0); /* Unreachable */ break; } @@ -291,26 +289,11 @@ static int bl1_fwu_image_copy(unsigned int image_id, return -ENOMEM; } -#if LOAD_IMAGE_V2 /* Check that the image size to load is within limit */ if (image_size > image_desc->image_info.image_max_size) { WARN("BL1-FWU: Image size out of bounds\n"); return -ENOMEM; } -#else - /* - * Check the image will fit into the free trusted RAM after BL1 - * load. - */ - const meminfo_t *mem_layout = bl1_plat_sec_mem_layout(); - if (!is_mem_free(mem_layout->free_base, mem_layout->free_size, - image_desc->image_info.image_base, - image_size)) { - WARN("BL1-FWU: Copy not allowed due to insufficient" - " resources.\n"); - return -ENOMEM; - } -#endif /* Save the given image size. */ image_desc->image_info.image_size = image_size; @@ -747,7 +730,7 @@ static int bl1_fwu_image_reset(unsigned int image_id, unsigned int flags) case IMAGE_STATE_EXECUTED: default: - assert(0); + assert(0); /* Unreachable */ break; } |