Add SRCU support in a standalone patch. I included the mmu_notifier patch as well so that you can compare approaches without having to wait on me for additional input. Sean Christopherson (2): x86/sgx: Use SRCU to protect mm_list during reclaim x86/sgx: Use mmu_notifier.release() instead of per-vma refcounting arch/x86/Kconfig | 2 + arch/x86/kernel/cpu/sgx/driver/main.c | 60 +++++---- arch/x86/kernel/cpu/sgx/encl.c | 182 +++++++++++++------------- arch/x86/kernel/cpu/sgx/encl.h | 12 +- arch/x86/kernel/cpu/sgx/reclaim.c | 71 ++++------ 5 files changed, 158 insertions(+), 169 deletions(-) -- 2.22.0