Hi Ken,
Your patch/fix helped, so now there is no stuck in assert.
But all regression tests are failed:
#### Execute test suites for the Secure area ####
Running Test Suite PSA protected storage S interface tests (TFM_SST_TEST_2XXX)...
> Executing 'TFM_SST_TEST_2001'
Description: 'Set interface'
Set should not fail with valid UID (Failed at ../../../../../../../middleware/tfm/test/suites/sst/secure/psa_ps_s_interface_testsuite.c:153)
TEST FAILED!
> Executing 'TFM_SST_TEST_2002'
Description: 'Set interface with create flags'
Set should not fail with no flags (Failed at ../../../../../../../middleware/tfm/test/suites/sst/secure/psa_ps_s_interface_testsuite.c:199)
TEST FAILED!
> Executing 'TFM_SST_TEST_2003'
Description: 'Set interface with NULL data pointer'
Set should succeed with NULL data pointer and zero length (Failed at ../../../../../../../middleware/tfm/test/suites/sst/secure/psa_ps_s_interface_testsuite.c:243)
TEST FAILED!
Will try to investigate...
-----Original Message-----
From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of Ken Liu (Arm Technology China) via TF-M
Sent: Friday, June 14, 2019 10:32 AM
To: TF-M(a)lists.trustedfirmware.org
Cc: nd <nd(a)arm.com>
Subject: Re: [TF-M] Is TFM_PSA_API broken?
Hi Andrej,
tfm_thrd_context_switch() does not want to thread to be running is NULL. And actually it should never happen in existing implement unless IRQ is involved.
Here is a patch for fixing this, but I am not sure if you are under the same case we met:
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Freview.tr…
I am curious about your environment, at least one partition will be running in latest master branch.
Can you share me your changes? Are your using original TF-M and which configuration file you are using?
Thanks.
-Ken
> -----Original Message-----
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of
> Andrej Butok via TF-M
> Sent: Friday, June 14, 2019 4:15 PM
> To: Antonio De Angelis <Antonio.DeAngelis(a)arm.com>
> Cc: tf-m(a)lists.trustedfirmware.org
> Subject: Re: [TF-M] Is TFM_PSA_API broken?
>
> Hi Antonio,
>
>
>
> So, I have disabled Platform and Log services.
>
> Also, TFM_NS_CLIENT_IDENTIFICATION have to be undefined for IPC. Is
> this correct?
>
> After that it becomes compliable.
>
>
>
> But when starting the regression tests, I am getting assert in
> tfm_thrd_conext_switch(). Terminal log:
>
>
>
> [Sec Thread] Secure image initializing!
>
>
>
> NS code is running...
>
>
>
> #### Execute test suites for the Secure area ####
>
> Running Test Suite PSA protected storage S interface tests
> (TFM_SST_TEST_2XXX)...
>
> > Executing 'TFM_SST_TEST_2001'
>
> Description: 'Set interface'
>
> Assert:tfm_thrd_context_switch:170
>
>
>
> So I am stuck now, and no matter what to use the IPC or the Function
> API approach.
>
> Probably, something serious happened during last two weeks (before it
> worked), may be in platform dependent code.
>
> NOTE: I am using a different platform LPC55S69 and IDE approach (not cmake).
>
>
>
> Any tips?
>
>
>
> Thanks,
>
> Andrej
>
>
>
>
>
> -----Original Message-----
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of
> Antonio De Angelis via TF-M
> Sent: Thursday, June 13, 2019 5:00 PM
> To: tf-m(a)lists.trustedfirmware.org
> Cc: nd <nd(a)arm.com>
> Subject: Re: [TF-M] Is TFM_PSA_API broken?
>
>
>
> Hi Andrej,
>
>
>
> "Should the Log and Platform services be disabled for IPC?"
>
>
>
> Yes, platform service and Audit Log service do not support IPC. You
> can see from existing IPC - specific build configurations which flags
> need to be set to make sure these two services are not built when IPC builds are selected.
>
>
>
> Thanks,
>
> Antonio
>
>
>
> -----Original Message-----
>
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org<mailto:tf-m-
> bounces(a)lists.trustedfirmware.org>> On Behalf Of Andrej Butok via TF-M
>
> Sent: 13 June 2019 15:46
>
> To:
> tf-m(a)lists.trustedfirmware.org<mailto:tf-m@lists.trustedfirmware.org>
>
> Subject: [TF-M] Is TFM_PSA_API broken?
>
>
>
> Hello,
>
>
>
> I use absolutely the latest TF-M (SHA-1:
> 81fb08cd66c1037a5e6c57e46ad5946bfc8a0d0e)
>
>
>
> I am trying to run the regression-test application using IPC API
> (TFM_PSA_API is
> defined) The application is compliable with errors:
>
> Error: L6218E: Undefined symbol tfm_spm_request_reset_vote (referred
> from platform_sp.o).
>
> Error: L6218E: Undefined symbol tfm_core_get_caller_client_id
> (referred from audit_core.o).
>
> Not enough information to list image symbols.
>
>
>
> It is caused by the fact that the platform and audit log services are
> using the functions (printed in the log) which are not
> available/disabled when TFM_PSA_API is defined.
>
> Is it known issue?
>
> Any suggestions?
>
> Should the Log and Platform services be disabled for IPC?
>
>
>
> Thanks,
>
> Andrej
>
> --
>
> TF-M mailing list
>
> TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
>
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> s.trust
> edfirmware.org%2Fmailman%2Flistinfo%2Ftf-
> m&data=02%7C01%7Candrey.butok%40nxp.com%7C4416c02536e54d420
> bdc08d6f00fc1ff%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C6369
> 60347799555976&sdata=1zhWkIyBjqiiTqtf0tYdtxRACLofQ%2B5Po6tC3cqW
> Fis%3D&reserved=0
>
> --
>
> TF-M mailing list
>
> TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
>
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> s.trust
> edfirmware.org%2Fmailman%2Flistinfo%2Ftf-
> m&data=02%7C01%7Candrey.butok%40nxp.com%7C4416c02536e54d420
> bdc08d6f00fc1ff%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C6369
> 60347799555976&sdata=1zhWkIyBjqiiTqtf0tYdtxRACLofQ%2B5Po6tC3cqW
> Fis%3D&reserved=0
> --
> TF-M mailing list
> TF-M(a)lists.trustedfirmware.org
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> s.trustedfirmware.org%2Fmailman%2Flistinfo%2Ftf-m&data=02%7C01%7Ca
> ndrey.butok%40nxp.com%7C441c81dc90a44fb5418408d6f0a2b68a%7C686ea1d3bc2
> b4c6fa92cd99c5c301635%7C0%7C0%7C636960978972859087&sdata=weHHf8wG3
> nlnTsI1JEA5Ww0D9sXSf4oJKyLkImmaCi8%3D&reserved=0
--
TF-M mailing list
TF-M(a)lists.trustedfirmware.org
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.tru…
I have just created T398 for integrating source cleanup to improve
portability.
I have just pushed a patch for review.
/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(a)iar.com <mailto:thomas.tornblom@iar.com>
Website: www.iar.com <http://www.iar.com>
Twitter: www.twitter.com/iarsystems <http://www.twitter.com/iarsystems>
Hi Thomas,
It's a bit slim, but I assume you noticed this but are looking for further
details?
https://git.trustedfirmware.org/trusted-firmware-m.git/tree/contributing.rst
Best regards,
Kevin
On Fri, 14 Jun 2019 at 13:10, Thomas Törnblom via TF-M <
tf-m(a)lists.trustedfirmware.org> wrote:
> I'm about to submit a set of cleanup patches but have not been able to
> find the contribution guide.
>
> Most of the useful documentation I've found seems to be related to TF-A.
>
> So where is it?
>
> /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(a)iar.com <mailto:thomas.tornblom@iar.com>
> Website: www.iar.com <http://www.iar.com>
> Twitter: www.twitter.com/iarsystems <http://www.twitter.com/iarsystems>
> --
> TF-M mailing list
> TF-M(a)lists.trustedfirmware.org
> https://lists.trustedfirmware.org/mailman/listinfo/tf-m
>
I'm about to submit a set of cleanup patches but have not been able to
find the contribution guide.
Most of the useful documentation I've found seems to be related to TF-A.
So where is it?
/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(a)iar.com <mailto:thomas.tornblom@iar.com>
Website: www.iar.com <http://www.iar.com>
Twitter: www.twitter.com/iarsystems <http://www.twitter.com/iarsystems>
Hi Andrej,
tfm_thrd_context_switch() does not want to thread to be running is NULL. And actually it should never happen in existing implement unless IRQ is involved.
Here is a patch for fixing this, but I am not sure if you are under the same case we met:
https://review.trustedfirmware.org/c/trusted-firmware-m/+/959
I am curious about your environment, at least one partition will be running in latest master branch.
Can you share me your changes? Are your using original TF-M and which configuration file you are using?
Thanks.
-Ken
> -----Original Message-----
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of Andrej
> Butok via TF-M
> Sent: Friday, June 14, 2019 4:15 PM
> To: Antonio De Angelis <Antonio.DeAngelis(a)arm.com>
> Cc: tf-m(a)lists.trustedfirmware.org
> Subject: Re: [TF-M] Is TFM_PSA_API broken?
>
> Hi Antonio,
>
>
>
> So, I have disabled Platform and Log services.
>
> Also, TFM_NS_CLIENT_IDENTIFICATION have to be undefined for IPC. Is this
> correct?
>
> After that it becomes compliable.
>
>
>
> But when starting the regression tests, I am getting assert in
> tfm_thrd_conext_switch(). Terminal log:
>
>
>
> [Sec Thread] Secure image initializing!
>
>
>
> NS code is running...
>
>
>
> #### Execute test suites for the Secure area ####
>
> Running Test Suite PSA protected storage S interface tests
> (TFM_SST_TEST_2XXX)...
>
> > Executing 'TFM_SST_TEST_2001'
>
> Description: 'Set interface'
>
> Assert:tfm_thrd_context_switch:170
>
>
>
> So I am stuck now, and no matter what to use the IPC or the Function API
> approach.
>
> Probably, something serious happened during last two weeks (before it worked),
> may be in platform dependent code.
>
> NOTE: I am using a different platform LPC55S69 and IDE approach (not cmake).
>
>
>
> Any tips?
>
>
>
> Thanks,
>
> Andrej
>
>
>
>
>
> -----Original Message-----
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of Antonio De
> Angelis via TF-M
> Sent: Thursday, June 13, 2019 5:00 PM
> To: tf-m(a)lists.trustedfirmware.org
> Cc: nd <nd(a)arm.com>
> Subject: Re: [TF-M] Is TFM_PSA_API broken?
>
>
>
> Hi Andrej,
>
>
>
> "Should the Log and Platform services be disabled for IPC?"
>
>
>
> Yes, platform service and Audit Log service do not support IPC. You can see from
> existing IPC - specific build configurations which flags need to be set to make
> sure these two services are not built when IPC builds are selected.
>
>
>
> Thanks,
>
> Antonio
>
>
>
> -----Original Message-----
>
> From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org<mailto:tf-m-
> bounces(a)lists.trustedfirmware.org>> On Behalf Of Andrej Butok via TF-M
>
> Sent: 13 June 2019 15:46
>
> To: tf-m(a)lists.trustedfirmware.org<mailto:tf-m@lists.trustedfirmware.org>
>
> Subject: [TF-M] Is TFM_PSA_API broken?
>
>
>
> Hello,
>
>
>
> I use absolutely the latest TF-M (SHA-1:
> 81fb08cd66c1037a5e6c57e46ad5946bfc8a0d0e)
>
>
>
> I am trying to run the regression-test application using IPC API (TFM_PSA_API is
> defined) The application is compliable with errors:
>
> Error: L6218E: Undefined symbol tfm_spm_request_reset_vote (referred from
> platform_sp.o).
>
> Error: L6218E: Undefined symbol tfm_core_get_caller_client_id (referred from
> audit_core.o).
>
> Not enough information to list image symbols.
>
>
>
> It is caused by the fact that the platform and audit log services are using the
> functions (printed in the log) which are not available/disabled when
> TFM_PSA_API is defined.
>
> Is it known issue?
>
> Any suggestions?
>
> Should the Log and Platform services be disabled for IPC?
>
>
>
> Thanks,
>
> Andrej
>
> --
>
> TF-M mailing list
>
> TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
>
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.tru…
> edfirmware.org%2Fmailman%2Flistinfo%2Ftf-
> m&data=02%7C01%7Candrey.butok%40nxp.com%7C4416c02536e54d420
> bdc08d6f00fc1ff%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C6369
> 60347799555976&sdata=1zhWkIyBjqiiTqtf0tYdtxRACLofQ%2B5Po6tC3cqW
> Fis%3D&reserved=0
>
> --
>
> TF-M mailing list
>
> TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
>
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.tru…
> edfirmware.org%2Fmailman%2Flistinfo%2Ftf-
> m&data=02%7C01%7Candrey.butok%40nxp.com%7C4416c02536e54d420
> bdc08d6f00fc1ff%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C6369
> 60347799555976&sdata=1zhWkIyBjqiiTqtf0tYdtxRACLofQ%2B5Po6tC3cqW
> Fis%3D&reserved=0
> --
> TF-M mailing list
> TF-M(a)lists.trustedfirmware.org
> https://lists.trustedfirmware.org/mailman/listinfo/tf-m
Hi Antonio,
So, I have disabled Platform and Log services.
Also, TFM_NS_CLIENT_IDENTIFICATION have to be undefined for IPC. Is this correct?
After that it becomes compliable.
But when starting the regression tests, I am getting assert in tfm_thrd_conext_switch(). Terminal log:
[Sec Thread] Secure image initializing!
NS code is running...
#### Execute test suites for the Secure area ####
Running Test Suite PSA protected storage S interface tests (TFM_SST_TEST_2XXX)...
> Executing 'TFM_SST_TEST_2001'
Description: 'Set interface'
Assert:tfm_thrd_context_switch:170
So I am stuck now, and no matter what to use the IPC or the Function API approach.
Probably, something serious happened during last two weeks (before it worked), may be in platform dependent code.
NOTE: I am using a different platform LPC55S69 and IDE approach (not cmake).
Any tips?
Thanks,
Andrej
-----Original Message-----
From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of Antonio De Angelis via TF-M
Sent: Thursday, June 13, 2019 5:00 PM
To: tf-m(a)lists.trustedfirmware.org
Cc: nd <nd(a)arm.com>
Subject: Re: [TF-M] Is TFM_PSA_API broken?
Hi Andrej,
"Should the Log and Platform services be disabled for IPC?"
Yes, platform service and Audit Log service do not support IPC. You can see from existing IPC - specific build configurations which flags need to be set to make sure these two services are not built when IPC builds are selected.
Thanks,
Antonio
-----Original Message-----
From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org<mailto:tf-m-bounces@lists.trustedfirmware.org>> On Behalf Of Andrej Butok via TF-M
Sent: 13 June 2019 15:46
To: tf-m(a)lists.trustedfirmware.org<mailto:tf-m@lists.trustedfirmware.org>
Subject: [TF-M] Is TFM_PSA_API broken?
Hello,
I use absolutely the latest TF-M (SHA-1: 81fb08cd66c1037a5e6c57e46ad5946bfc8a0d0e)
I am trying to run the regression-test application using IPC API (TFM_PSA_API is defined) The application is compliable with errors:
Error: L6218E: Undefined symbol tfm_spm_request_reset_vote (referred from platform_sp.o).
Error: L6218E: Undefined symbol tfm_core_get_caller_client_id (referred from audit_core.o).
Not enough information to list image symbols.
It is caused by the fact that the platform and audit log services are using the functions (printed in the log) which are not available/disabled when TFM_PSA_API is defined.
Is it known issue?
Any suggestions?
Should the Log and Platform services be disabled for IPC?
Thanks,
Andrej
--
TF-M mailing list
TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.tru…
--
TF-M mailing list
TF-M(a)lists.trustedfirmware.org<mailto:TF-M@lists.trustedfirmware.org>
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.tru…
Hi Andrej,
"Should the Log and Platform services be disabled for IPC?"
Yes, platform service and Audit Log service do not support IPC. You can see from existing IPC - specific build configurations which flags need to be set to make sure these two services are not built when IPC builds are selected.
Thanks,
Antonio
-----Original Message-----
From: TF-M <tf-m-bounces(a)lists.trustedfirmware.org> On Behalf Of Andrej Butok via TF-M
Sent: 13 June 2019 15:46
To: tf-m(a)lists.trustedfirmware.org
Subject: [TF-M] Is TFM_PSA_API broken?
Hello,
I use absolutely the latest TF-M (SHA-1: 81fb08cd66c1037a5e6c57e46ad5946bfc8a0d0e)
I am trying to run the regression-test application using IPC API (TFM_PSA_API is defined) The application is compliable with errors:
Error: L6218E: Undefined symbol tfm_spm_request_reset_vote (referred from platform_sp.o).
Error: L6218E: Undefined symbol tfm_core_get_caller_client_id (referred from audit_core.o).
Not enough information to list image symbols.
It is caused by the fact that the platform and audit log services are using the functions (printed in the log) which are not available/disabled when TFM_PSA_API is defined.
Is it known issue?
Any suggestions?
Should the Log and Platform services be disabled for IPC?
Thanks,
Andrej
--
TF-M mailing list
TF-M(a)lists.trustedfirmware.org
https://lists.trustedfirmware.org/mailman/listinfo/tf-m
Hello,
I use absolutely the latest TF-M (SHA-1: 81fb08cd66c1037a5e6c57e46ad5946bfc8a0d0e)
I am trying to run the regression-test application using IPC API (TFM_PSA_API is defined)
The application is compliable with errors:
Error: L6218E: Undefined symbol tfm_spm_request_reset_vote (referred from platform_sp.o).
Error: L6218E: Undefined symbol tfm_core_get_caller_client_id (referred from audit_core.o).
Not enough information to list image symbols.
It is caused by the fact that the platform and audit log services are using the functions (printed in the log) which are not available/disabled when TFM_PSA_API is defined.
Is it known issue?
Any suggestions?
Should the Log and Platform services be disabled for IPC?
Thanks,
Andrej
While working on porting TF-M to the IAR toolchain, I've run into a
couple of issues I'd like to discuss.
1) The duplicated REGION/REGION_NAME/REGION_DECLARE macros.
Why are these not defined in an include file instead of being defined in
eight different c files?
I see that they are also defined in spm_db.h, but that is only included
in spm related files.
2) I suggest adding a toolchain related include file that should be
included in every source file that is part of TF-M.
This could be something similar to cmsis_compiler.h, where a toolchain
vendor could add stuff that only relates to a specific toolchain.
In our case that could include things like:
---
#ifdef __ICCARM__
#define $$ZI$$Limit $$Limit
#define $$ZI$$Base $$Base
#define Image$$
#endif
---
Ideas?
/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(a)iar.com <mailto:thomas.tornblom@iar.com>
Website: www.iar.com <http://www.iar.com>
Twitter: www.twitter.com/iarsystems <http://www.twitter.com/iarsystems>
Hi,
Since the number of configuration files is increasing, let’s move the configuration files (ConfigXXXX.cmake) into specified directory.
This would reduces the files under root directory and makes the structure more clearer.
I have created the issue and patch for it:
https://developer.trustedfirmware.org/T394https://review.trustedfirmware.org/c/trusted-firmware-m/+/1234
IMPORTANT NOTES:
To be compatible with the existing building configurations, the existing configuration files have been forwarded into the corresponded configuration file under ./configs. Which means there are two set of configuration files under sources tree at current – but this will change soon. There is a warning while you are building with root configurations files: “Please use the configs available in the ./config sub-directory.”
So please:
- If you are planning to create new configuration, create it under ./configs instead of root directory
- The reference of configuration files under root directory will be removed soon, please change your build system setting to reference the configuration files put under ./configs
Any feedbacks please reply this mail or put comments under the issue, thanks 😉
-Ken