-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
core: add HOB creation and Apply FF-A v1.2 in stmm_sp. #7086
base: master
Are you sure you want to change the base?
Conversation
f53a051
to
1c833bd
Compare
Why is this HOB needed if StMM could create it by itself before? What is the long-term goal with StMM? Should it be turned into an SP or something else? |
Since StandaloneMm (StMM) is not producer of HOB but consumer according to specification, As long term, there is plan for StMM to move SP, Thanks. |
Once StMM is an SP, who will create the HOB for StMM? How is this accommodated in the FF-A spec? Or do you anticipate a shim? If so how is that implemented? |
TBH, I don't know exactly, But I think SPMC should create the HOB information according to manifest file. This build hob list passed via FF-A boot protocol and StMM get Hob List in FF-A boot protocol and initialize itself with it. |
Do you expect to merge the same thing in Hafnium? |
No, It's not glue code for StMM, But it's based on the FF-A specfication. The FF-A boot protocol and its contents should be created from SPMC when it loads partition. |
Thanks, I've found it in the spec too. :-) |
We should go with the lib approach as in TF-A. Please move all the HOB-related code under |
1c833bd
to
a485339
Compare
Thanks for reviewing this :) |
17179c1
to
0370a5b
Compare
0370a5b
to
b64917c
Compare
According to Platform Initialization (PI) Specification [1] and Discussion on edk2 mailing list [2], StandaloneMm shouldn't create Hob but it should be passed from TF-A. That's why StandaloneMm in Arm wouldn't produce Hob by itself [3] but other software stack should pass boot information via PHIT Hob. This patch introduces libefi including create Hob to deliver boot information to StandaloneMm and defines related data structures. Link: https://uefi.org/sites/default/files/resources/PI_Spec_1_6.pdf [1] Link: https://edk2.groups.io/g/devel/topic/103675962#114283 [2] Link: tianocore/edk2#6116 [3] Signed-off-by: Levi Yun <[email protected]>
edk2's StandaloneMm will be applied with FF-A v1.2. while applying, StandaloneMm doesn't create anymore PHIT hob by itself but it should be passed from other software stack. To make StandaloneMm runs properly, create Hob information and deliver it using FF-A Boot protocol according to FF-A specification [1]. Also, apply FF-A management protocol to change it [2] to get/set memory permission instead of using DIRECT_REQ_MSG. Also, implements some FF-A ABIs to communication StandaloneMm properly. Link: https://developer.arm.com/documentation/den0077/latest [1] Link: https://developer.arm.com/documentation/den0140/latest [2] Signed-off-by: Levi Yun <[email protected]>
b64917c
to
7cb68f7
Compare
According to Platform Initialization (PI) Specification [1] and
Discussion on edk2 mailing list [2],
StandaloneMm shouldn't create Hob but it should be passed from TF-A.
That's why StandaloneMm in Arm wouldn't produce Hob by itself [3] but
other software stack should pass boot information via PHIT Hob.
To make compatible with edk2 patches [3],
add HOB creation to load StandaloneMm properly.
Also, StandaloneMm doesn't support under FF-A v1.2 version ABI.
For this, update syscall handler with FF-A v1.2 compatiblity.
Links: https://uefi.org/sites/default/files/resources/PI_Spec_1_6.pdf [1]
Links: https://edk2.groups.io/g/devel/topic/103675962#114283 [2]
Links: tianocore/edk2#6116 [3]