Closed moshe-shahar closed 3 years ago
Here is a suggested fix for K64F to that issue: https://github.com/ARMmbed/mbed-os/pull/13832
But, this issue probably exists on more targets (from a quick look, K66F too) and needs further investigation on how to prevent creating a non-contiguous application.
Another issue that may be hidden here is that when the combined Bootloader+App tool is calculating the App digest, it's using 0xFF value for the gap, which is by chance is the erase value in that target.
Thanks to @kjbracey-arm and @alzix for the support.
Here is additional info that may be useful: FILLing unused Memory with the GNU Linker.
Thank you for raising this detailed GitHub issue. I am now notifying our internal issue triagers. Internal Jira reference: https://jira.arm.com/browse/IOTOSM-2599
We closed this issue because it has been inactive for quite some time and we believe it to be low priority. If you think that the priority should be higher, then please reopen with your justification for increasing the priority.
Description of defect
On some targets, GCC_ARM produces a non-contiguous FW image. When building application and bootloader combine image in hex format, bootloader integrity checks failed to validate active FW.
Target(s) affected by this defect ?
Reproduced on K64F but can appear on many others
Toolchain(s) (name and version) displaying this defect ?
GCC_ARM
What version of Mbed-os are you using (tag or sha) ?
mbed-os 15.1.0 to mbed-os 6.4.0
What version(s) of tools are you using. List all that apply (E.g. mbed-cli)
NA
How is this defect reproduced?
Build:
Test:
pyocd flash -M under-reset BUILD/K64F/ARM/mbed-os-example-blinky.hex
or write something in 0xA810-0xA83Fpyocd flash -M under-reset BUILD/K64F/GCC_ARM/mbed-os-example-blinky.hex
Results:
Note, the issue can't be reproduced with DAPLink because it erases the flash sectors and hides the problem.