-
Notifications
You must be signed in to change notification settings - Fork 3k
Avoid building mbed_tz_context.c for TF-M targets #9324
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
Conversation
@ARMmbed/mbed-os-core |
@mikisch81, thank you for your changes. |
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.
Looks good to me 👍
@@ -22,6 +22,8 @@ | |||
* limitations under the License. | |||
*/ | |||
|
|||
#if !defined(TARGET_TFM) |
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 think using the below would be more flexible (it also allows the builder to set the macro to 0/1 in addition to just being set).
#if !defined(TARGET_TFM) | |
#if !TARGET_TFM |
@deepikabhavnani there was a PR about this recently, can you double check me on this?
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.
Thanks for catching this @bridadan. Yes we had a PR about this recently
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.
@bridadan TFM
will be added to the RAM_MUSCA_A1_S
target inside extra_labels
.
So it will generate #define TARGET_TFM 1
inside mbed_config.h
? and for any other target #define TARGET_TFM 0
?
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.
@mikisch81 yup, everything you said is correct and the way you have written it will work just fine! I was commenting because there was a previous PR that helped standardize this kind of #if
check in the code base (#9163). If you accept my suggested change, it would bring your changes inline with that styling.
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.
Oh, and also this PR: https://github.com/ARMmbed/mbed-os/pull/9327/files
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.
@bridadan done
- TF-M v8m secure-side implements their own TZ context APIs so need to avoid building the Mbed implementation.
@cmonr as everyone approved, can this PR move to |
CI started |
Test run: SUCCESSSummary: 11 of 11 test jobs passed |
Description
TF-M v8m secure-side implements their own TZ context APIs so need to avoid building the Mbed implementation.
TARGET_TFM
is a macro which will be set when #9221 is merged (Only for Secure targets).Pull request type
Reviewers
@deepikabhavnani