RFC selftests: KVM: SEV: selftests for fd-based private memory
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 RFC Latest8 patches 0 repliesNew
- v1 RFC3 patches 4 repliesSuperseded
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/8 | selftests: kvm: x86_64: Add support for pagetable trackingtools/ tools/ tools/ | +214 | 0 replies | |
| 2/8 | kvm: Add HVA range operatorinclude/ virt/ | +54 | 0 replies | |
| 3/8 | arch: x86: sev: Populate private memory fd during LAUNCH_UPDATE_DATAarch/ include/ virt/ | +116 | 0 replies | |
| 4/8 | selftests: kvm: sev: Support memslots with private memorytools/ tools/ | +14 | 0 replies | |
| 5/8 | selftests: kvm: Update usage of private mem lib for SEV VMstools/ tools/ | +83 | 0 replies | |
| 6/8 | selftests: kvm: Support executing SEV VMs with private memorytools/ tools/ | +87 | 0 replies | |
| 7/8 | selftests: kvm: Refactor testing logic for private memorytools/ tools/ tools/ +1 more | +289 | 0 replies | |
| 8/8 | selftests: kvm: Add private memory test for SEV VMstools/ tools/ tools/ | +23 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [RFC V2 PATCH 0/8] selftests: KVM: SEV: selftests for fd-based private memory
This series implements selftests executing SEV VMs to target the feature floated by Chao via:
https://lore.kernel.org/linux-mm/[email protected]/T/
Below changes aim to test the fd based approach for guest private memory in context of SEV VMs executing on AMD SEV compatible platforms.
sev_private_mem_test.c file adds selftest to access private memory from the guest via private/shared accesses and checking if the contents can be leaked to/accessed by vmm via shared memory view before/after conversions.
To allow SEV/SEV-ES VMs to toggle the encryption bit during memory conversion, support is added for mapping guest pagetables to guest va ranges and passing the mapping information to guests via shared pages.
This series has dependency on following patch series:
1) V7 series patches from Chao mentioned above.
2) https://lore.kernel.org/lkml/[email protected]/T/#u
- Series posted by Peter containing patches from Michael and Sean
3) https://lore.kernel.org/lkml/Ywa9T+jKUpaHLu%[email protected]/T/
- Series posted for similar selftests executing non-confidential VMs.
Github link for the patches posted as part of this series:
https://github.com/vishals4gh/linux/commits/sev_upm_selftests_rfcv2
Vishal Annapurve (8):
selftests: kvm: x86_64: Add support for pagetable tracking
kvm: Add HVA range operator
arch: x86: sev: Populate private memory fd during LAUNCH_UPDATE_DATA
selftests: kvm: sev: Support memslots with private memory
selftests: kvm: Update usage of private mem lib for SEV VMs
selftests: kvm: Support executing SEV VMs with private memory
selftests: kvm: Refactor testing logic for private memory
selftests: kvm: Add private memory test for SEV VMs
arch/x86/kvm/svm/sev.c | 99 ++++++- include/linux/kvm_host.h | 8 + tools/testing/selftests/kvm/.gitignore | 1 + tools/testing/selftests/kvm/Makefile | 2 + .../selftests/kvm/include/kvm_util_base.h | 105 +++++++ .../kvm/include/x86_64/private_mem.h | 10 +- .../include/x86_64/private_mem_test_helper.h | 13 + .../selftests/kvm/include/x86_64/sev.h | 2 + tools/testing/selftests/kvm/lib/kvm_util.c | 78 ++++- .../selftests/kvm/lib/x86_64/private_mem.c | 189 ++++++++++-- .../kvm/lib/x86_64/private_mem_test_helper.c | 273 ++++++++++++++++++ .../selftests/kvm/lib/x86_64/processor.c | 32 ++ tools/testing/selftests/kvm/lib/x86_64/sev.c | 15 +- .../selftests/kvm/x86_64/private_mem_test.c | 246 +--------------- .../kvm/x86_64/sev_private_mem_test.c | 21 ++ virt/kvm/kvm_main.c | 87 +++++- 16 files changed, 880 insertions(+), 301 deletions(-) create mode 100644 tools/testing/selftests/kvm/include/x86_64/private_mem_test_helper.h create mode 100644 tools/testing/selftests/kvm/lib/x86_64/private_mem_test_helper.c create mode 100644 tools/testing/selftests/kvm/x86_64/sev_private_mem_test.c
Signature · 1 line
2.37.2.672.g94769d06f0-goog