W dniu 7.12.2023 o 11:28, Xiong Yining pisze:
We submit a patch(d56b488) in TF-A which is armed at reporting the information of memory through SMC. Cooperating with that patch, we can get the information of memory in EDK2 via SMC calls.
Xiong Yining (1): SbsaQemu: get the information of memory form TF-A
Platform/Qemu/SbsaQemu/SbsaQemu.dsc | 5 +++- .../SbsaQemuPlatformDxe/SbsaQemuPlatformDxe.c | 29 +++++++++++++++++++ .../SbsaQemuPlatformDxe.inf | 1 + .../SbsaQemuPlatformVersion.h | 14 +++++++++ .../Include/IndustryStandard/SbsaQemuSmc.h | 2 ++ Silicon/Qemu/SbsaQemu/SbsaQemu.dec | 2 ++ 6 files changed, 52 insertions(+), 1 deletion(-)
Please take a look at code present in Silicon/Qemu/SbsaQemu/Library/SbsaQemuLib/SbsaQemuMem.c file.
We read DT to get memory information there. This needs to be replaced with use of SMC calls.