Re: [PATCH] x86/sgx: Free backing memory after faulting the enclave page

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/4/21 8:04 AM, Jarkko Sakkinen wrote:
>> Do we also need to deal with truncating the PCMD?  (For those watching
>> along at home, there are two things SGX swaps to RAM: the actual page
>> data and also some metadata that ensures page integrity and helps
>> prevent things like rolling back to old versions of swapped pages)
> Yes.
> 
> This can be achieved by iterating through all of the enclave pages,
> which share the same shmem page for storing their PCMD's, as the one
> being faulted back. If none of those pages is swapped, the PCMD page can
> safely truncated.

I was thinking we could just read the page.  If it's all 0's, truncate it.



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux