[PATCH v2 0/4] intel_sgx: Bug fixes
by Sean Christopherson
Sean Christopherson (4):
intel_sgx: Abort sgx_vma_do_fault if do_eldu fails
intel_sgx: Update ret val if vm_insert_pfn fails
intel_sgx: Avoid EREMOVE in fail path during fault
intel_sgx: Lock the enlcave when updating va_pages
drivers/platform/x86/intel_sgx_ioctl.c | 3 +++
drivers/platform/x86/intel_sgx_vma.c | 14 ++++++++++----
2 files changed, 13 insertions(+), 4 deletions(-)
5 years, 5 months
[PATCH v3 0/4] intel_sgx: Bug fixes
by Sean Christopherson
Sean Christopherson (4):
intel_sgx: Abort sgx_vma_do_fault if do_eldu fails
intel_sgx: Update ret val if vm_insert_pfn fails
intel_sgx: Lock the enlcave when updating va_pages
intel_sgx: Kill enclave if vm_insert_pfn fails
drivers/platform/x86/intel_sgx_ioctl.c | 3 +++
drivers/platform/x86/intel_sgx_vma.c | 17 +++++++++++++----
2 files changed, 16 insertions(+), 4 deletions(-)
5 years, 5 months
[PATCH 0/3] PCMD backing storage
by Jarkko Sakkinen
Move PCMD to the shmem file in order to have better control of the
memory consumption.
Jarkko Sakkinen (2):
intel_sgx: pin the backing page inside sgx_eldu
intel_sgx: backing storage file for PCMD
Sean Christopherson (1):
intel_sgx: check the result of do_eldu
drivers/platform/x86/intel_sgx.h | 5 ++-
drivers/platform/x86/intel_sgx_ioctl.c | 12 +++++
drivers/platform/x86/intel_sgx_page_cache.c | 19 +++++++-
drivers/platform/x86/intel_sgx_util.c | 30 +++++++++++++
drivers/platform/x86/intel_sgx_vma.c | 69 +++++++++++++++++------------
5 files changed, 104 insertions(+), 31 deletions(-)
--
2.9.3
5 years, 5 months
[PATCH 0/3] intel_sgx: Bug fixes
by Sean Christopherson
Sean Christopherson (3):
intel_sgx: Abort sgx_vma_do_fault if do_eldu fails
intel_sgx: bug fixes for vm_insert_pfn in fault
intel_sgx: Lock the enclave when updating va_pages
drivers/platform/x86/intel_sgx_ioctl.c | 3 +++
drivers/platform/x86/intel_sgx_vma.c | 14 ++++++++++----
2 files changed, 13 insertions(+), 4 deletions(-)
5 years, 5 months
[PATCH 0/6] intel_sgx: sgx_encl_page memory optimization
by Sean Christopherson
I will be on vacation until January 3rd and will not be checking
email, so there is no rush in evaluating this series.
The end goal of this patch series is to eliminate memory allocation
for eviction-specific structures for enclave pages that are resident
in the EPC. This is accomplished by moving the objects used to track
an evicted page, e.g. VA page, VA offset and PCMD, to a new struct,
sgx_evicted_page, that is allocated/freed on-demand. To completely
eliminate memory consumption for sgx_evicted_page when an encl page
is resident in EPC, sgx_epc_page and sgx_evicted_page are combined
into an anonymous union. The two pointers are mutually exclusive,
as an encl page cannot be simultaneously resident in EPC and evicted
from EPC.
The first two patches fix pre-existing bugs that are exposed by
allocating VA pages/offsets on-demand (immediately prior to EWB);
patches 3-5 prepare for on-demand allocation of eviction structures;
and the final patch implements sgx_evicted_page and its unionization
with sgx_epc_page.
Sean Christopherson (6):
intel_sgx: Abort sgx_vma_do_fault if do_eldu fails
intel_sgx: Lock the enlcave when updating va_pages
intel_sgx: Track SECS eviction using its epc_page
intel_sgx: Clean-up page freeing in sgx_ewb flow
intel_sgx: Delay VA slot allocation until EWB
intel_sgx: Combine epc/eviction pages via union
drivers/platform/x86/intel_sgx.h | 33 ++++++++-------
drivers/platform/x86/intel_sgx_ioctl.c | 108 ++++++++++++++++++++++++-------------------------
drivers/platform/x86/intel_sgx_page_cache.c | 115 +++++++++++++++++++++++++++++++++++------------------
drivers/platform/x86/intel_sgx_util.c | 12 +++---
drivers/platform/x86/intel_sgx_vma.c | 23 ++++++-----
5 files changed, 164 insertions(+), 127 deletions(-)
5 years, 5 months