Hi Thomas,
Thanks for reporting this issue.
This is caused by
a recent patch about ITS. And it only occurs on NAND flash. lpcxpresso55s69 is the only board which uses NAND flash for ITS in TF-M currently. Sorry I missed to test my original patch based on lpcxpresso55s69.
I created this patch
https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/12282/ to fix it.
I have verified the fix on lpcxpresso55s69 board. The command I used in the test is
“cmake -S . -B cmake_build -DTFM_PLATFORM=nxp/lpcxpresso55s69 -DBL2=0”
Regards,
Sherry Zhang
From: TF-M <tf-m-bounces@lists.trustedfirmware.org>
On Behalf Of Thomas Törnblom via TF-M
Sent: Wednesday, November 3, 2021 8:32 PM
To: tf-m@lists.trustedfirmware.org
Subject: Re: [TF-M] lpcxpresso55s69 builds broken
It appears to be the logic around creating the ITS flash storage when the flash is empty that fails
This call to its_flash_fs_prepare() fails:
---
if (status != PSA_SUCCESS) {
/* Remove all data in the ITS memory area and create a valid ITS flash
* layout in that area.
*/
LOG_INFFMT("Creating an empty ITS flash layout.\r\n");
status = its_flash_fs_wipe_all(&fs_ctx_its);
if (status != PSA_SUCCESS) {
return status;
}
/* Attempt to prepare again */
status = its_flash_fs_prepare(&fs_ctx_its);
}
#endif /* ITS_CREATE_FLASH_LAYOUT */
#ifdef TFM_PARTITION_PROTECTED_STORAGE
/* Check status of ITS initialisation before continuing with PS */
if (status != PSA_SUCCESS) {
return status;
---
Thomas
Den 2021-11-03 kl. 09:43, skrev Ken Liu via TF-M:
It might be caused by the panic. Put a breakpoint in ‘tfm_platform_hal_system_reset’ should get stopped and know the reason.
/Ken
From: TF-M <tf-m-bounces@lists.trustedfirmware.org> On Behalf Of Thomas Törnblom via TF-M
Sent: Wednesday, November 3, 2021 4:09 PM
To: tf-m@lists.trustedfirmware.org
Subject: Re: [TF-M] lpcxpresso55s69 builds broken
While this allows building TF-M, it crashes and loops in the boot.
I have not figured out what causes this.
/ThomasDen 2021-11-02 kl. 05:53, skrev Ken Liu via TF-M:
Sorry, the merged one should be part of group patches but merged individually.
We are removing the dependency on VTOR for initial MSP retrieving, here is the followed one:
https://review.trustedfirmware.org/c/TF-M/trusted-firmware-m/+/12228
/Ken
From: TF-M <tf-m-bounces@lists.trustedfirmware.org> On Behalf Of Thomas Törnblom via TF-M
Sent: Monday, November 1, 2021 11:37 PM
To: tf-m@lists.trustedfirmware.org
Subject: Re: [TF-M] lpcxpresso55s69 builds broken
Apparently caused by:
68b14d40 SPM : Arch : Refine common arch codeDen 2021-11-01 kl. 15:33, skrev Thomas Törnblom:
More breakage:
In file included from ../secure_fw/spm/include/tfm_arch.h:19,
from ../secure_fw/spm/cmsis_psa/spm_ipc.h:13,
from ../secure_fw/partitions/idle_partition/load_info_idle_sp.c:10:
../secure_fw/spm/include/tfm_arch_v8m.h:58:2: error: #error "VTOR not present, check configurations."
58 | #error "VTOR not present, check configurations."
| ^~~~~
ninja: build stopped: subcommand failed.
Same issue with IAR.
/Thomas--
Thomas Törnblom, Product Engineer
IAR Systems AB
Box 23051, Strandbodgatan 1
SE-750 23 Uppsala, SWEDEN
Mobile: +46 76 180 17 80 Fax: +46 18 16 78 01
E-mail: thomas.tornblom@iar.com Website: www.iar.com
Twitter: www.twitter.com/iarsystems
--
Thomas Törnblom, Product Engineer
IAR Systems AB
Box 23051, Strandbodgatan 1
SE-750 23 Uppsala, SWEDEN
Mobile: +46 76 180 17 80 Fax: +46 18 16 78 01
E-mail: thomas.tornblom@iar.com Website: www.iar.com
Twitter: www.twitter.com/iarsystems
--
Thomas Törnblom, Product Engineer
IAR Systems AB
Box 23051, Strandbodgatan 1
SE-750 23 Uppsala, SWEDEN
Mobile: +46 76 180 17 80 Fax: +46 18 16 78 01
E-mail: thomas.tornblom@iar.com Website: www.iar.com
Twitter: www.twitter.com/iarsystems
--
Thomas Törnblom,
Product Engineer
IAR Systems AB
Box 23051, Strandbodgatan 1
SE-750 23 Uppsala, SWEDEN
Mobile: +46 76 180 17 80 Fax: +46 18 16 78 01
E-mail: thomas.tornblom@iar.com Website:
www.iar.com
Twitter: www.twitter.com/iarsystems