-
Notifications
You must be signed in to change notification settings - Fork 3k
Default psa headers implementation #9661
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,8 +17,10 @@ | |
|
||
#if defined(TARGET_TFM) | ||
#include "interface/include/psa_service.h" | ||
#else | ||
#elif defined(TARGET_MBED_SPM) | ||
#include "TARGET_MBED_SPM/psa_defs.h" | ||
#include "TARGET_MBED_SPM/COMPONENT_SPE/spm_server.h" | ||
#include "TARGET_MBED_SPM/COMPONENT_SPE/spm_panic.h" | ||
#else | ||
#error "Compiling psa service header on non-secure target is not allowed" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not allowed? Why? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. because you are not supposed to use psa/service/h in NSPE builds and non-PSA builds There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would call it not expected instead of not allowed. There are no rules about what symbols can be used where. |
||
#endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we duplicating the header file?
Please consider moving spm_client.h and psa_defs.h to this folder instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spm_client.h and psa_defs.h contains more defines and definitions that are not relevant for non-PSA builds (example K64F)
this "default" implementation holds only what the spec requires.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not see this default implementation gets removed from the original files. Thus it is a duplication.
Please keep in mind that our divergence from TF-M sources ( spec version) is temporal while single core API compliance is not. Eventually I would not want to duplicate the header files and would prefer adopting TF-M's version.
Please consider moving these files to a common place instead of simbols cherry picking.