Boot: Change the return type of flash_area_align()
Change from uint8_t to uint32_t to prevent an implicit cast. Update
variables and functions which use the return value of the function.
Change-Id: I55bcb1cf2b4b642d1cdf8a1d41c04e601289dea0
Signed-off-by: Raef Coles <raef.coles@arm.com>
diff --git a/bl2/ext/mcuboot/bootutil/src/loader.c b/bl2/ext/mcuboot/bootutil/src/loader.c
index 406257e..abf88df 100644
--- a/bl2/ext/mcuboot/bootutil/src/loader.c
+++ b/bl2/ext/mcuboot/bootutil/src/loader.c
@@ -209,11 +209,11 @@
return 0;
}
-static uint8_t
+static uint32_t
boot_write_sz(void)
{
- uint8_t elem_sz;
- uint8_t align;
+ uint32_t elem_sz;
+ uint32_t align;
/* Figure out what size to write update status update as. The size depends
* on what the minimum write size is for scratch area, active image slot.
@@ -763,7 +763,7 @@
int area_id;
int rc;
uint8_t buf[BOOT_MAX_ALIGN];
- uint8_t align;
+ uint32_t align;
uint8_t erased_val;
/* NOTE: The first sector copied (that is the last sector on slot) contains