On 07/29/17 03:37, Brijesh Singh wrote: > On 7/28/17 7:52 PM, Brijesh Singh wrote: > [snip] >> AMD APM document a procedure which must be used to perform in-place >> encryption/decryption. We must follow those steps to ensure that data is >> flush into memory using the correct C-bit. Not doing so may result in >> unpredictable results. >> >> http://support.amd.com/TechDocs/24593.pdf (Section 7.10.8) > I am wondering if UEFI provides APIs to get two linear mapping of the > same physical address. The steps says we create two mapping of same > physical address with different C-bits. I will look into UEFI docs to > see if something like this exist otherwise we have to consider two > memcpy. Since its just for CommandBuffers (which usually are smaller > hence we may be okay from performance point of view.
Right, the separate static bounce buffer (4KB in size) and the two matching CopyMem()s look easier to understand and safer. Hopefully there won't be a performance issue in practice. > Also its just a > boot time thing, does not get used when guest OS is takes over. I will > investigate and see what works best without adding extra complexity in > the code :) Thanks! (Sorry about the late reply.) Laszlo _______________________________________________ edk2-devel mailing list [email protected] https://lists.01.org/mailman/listinfo/edk2-devel

