Re: [PATCH 05/25] x86/sgx: Introduce virtual EPC for use by KVM guests

2021-03-01 Thread Kai Huang
On Mon, 2021-03-01 at 08:21 -0800, Sean Christopherson wrote: > On Mon, Mar 01, 2021, Kai Huang wrote: > > + /* > > +* SECS pages are "pinned" by child pages, an unpinned once all > > s/an/and Thanks! > > > +* children have been EREMOVE'd. A child page in this instance > > +*

Re: [PATCH 05/25] x86/sgx: Introduce virtual EPC for use by KVM guests

2021-03-01 Thread Sean Christopherson
On Mon, Mar 01, 2021, Kai Huang wrote: > + /* > + * SECS pages are "pinned" by child pages, an unpinned once all s/an/and > + * children have been EREMOVE'd. A child page in this instance > + * may have pinned an SECS page encountered in an earlier release(), > + *

[PATCH 05/25] x86/sgx: Introduce virtual EPC for use by KVM guests

2021-03-01 Thread Kai Huang
From: Sean Christopherson Add a misc device /dev/sgx_vepc to allow userspace to allocate "raw" EPC without an associated enclave. The intended and only known use case for raw EPC allocation is to expose EPC to a KVM guest, hence the 'vepc' moniker, virt.{c,h} files and X86_SGX_KVM Kconfig. SGX