Skip to content

RFC Additional selftests for restrictedmem

Ackerley Tng kvm linux-api linux-arch linux-doc linux-fsdevel linux-mm lkml qemu-devel 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest10 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10KVM: selftests: Test error message fixes for memfd_restricted selfteststools/testing/selftests/vm/memfd_restricted.c+2 -20 replies
2/10KVM: selftests: Test that ftruncate to non-page-aligned size on a restrictedmem fd should failtools/testing/selftests/vm/memfd_restricted.c+5 -00 replies
3/10KVM: selftests: Test that VM private memory should not be readable from hosttools/testing/selftests/kvm/x86_64/private_mem_conversions_test.c+48 -60 replies
4/10KVM: selftests: Exercise restrictedmem allocation and truncation code after KVM invalidation code has been unboundtools/testing/selftests/kvm/x86_64/private_mem_conversions_test.c+25 -10 replies
5/10KVM: selftests: Generalize private_mem_conversions_test for parallel executiontools/testing/selftests/kvm/x86_64/private_mem_conversions_test.c+150 -530 replies
6/10KVM: selftests: Default private_mem_conversions_test to use 1 memslot for test datatools/testing/selftests/kvm/x86_64/private_mem_conversions_test.c+25 -50 replies
7/10KVM: selftests: Add vm_userspace_mem_region_add_with_restrictedmemtools/testing/selftests/kvm/include/kvm_util_base.h tools/testing/selftests/kvm/lib/kvm_util.c+46 -40 replies
8/10KVM: selftests: Default private_mem_conversions_test to use 1 restrictedmem file for test datatools/testing/selftests/kvm/x86_64/private_mem_conversions_test.c+38 -140 replies
9/10KVM: selftests: Add tests around sharing a restrictedmem fdtools/testing/selftests/kvm/set_memory_region_test.c+26 -30 replies
10/10KVM: selftests: Test KVM exit behavior for private memory/accesstools/testing/selftests/kvm/Makefile tools/testing/selftests/kvm/x86_64/private_mem_kvm_exits_test.c+125 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC PATCH 00/10] Additional selftests for restrictedmem

Hello,

This is a series containing additional selftests for restrictedmem, prepared to be used with the next iteration of the restrictedmem series after v10.

restrictedmem v10 is available at
https://lore.kernel.org/lkml/[email protected]/T/.

The tree can be found at
https://github.com/googleprodkernel/linux-cc/tree/restrictedmem-additional-selftests-rfc-v1/.

Dependencies
+ The next iteration of the restrictedmem series
+ branch: https://github.com/chao-p/linux/commits/privmem-v11.4
+ commit: https://github.com/chao-p/linux/tree/ddd2c92b268a2fdc6158f82a6169ad1a57f2a01d
+ Proposed fix to adjust VM's initial stack address to align with SysV
ABI spec: https://lore.kernel.org/lkml/[email protected]/

Ackerley Tng (10):
KVM: selftests: Test error message fixes for memfd_restricted
selftests
KVM: selftests: Test that ftruncate to non-page-aligned size on a
restrictedmem fd should fail
KVM: selftests: Test that VM private memory should not be readable
from host
KVM: selftests: Exercise restrictedmem allocation and truncation code
after KVM invalidation code has been unbound
KVM: selftests: Generalize private_mem_conversions_test for parallel
execution
KVM: selftests: Default private_mem_conversions_test to use 1 memslot
for test data
KVM: selftests: Add vm_userspace_mem_region_add_with_restrictedmem
KVM: selftests: Default private_mem_conversions_test to use 1
restrictedmem file for test data
KVM: selftests: Add tests around sharing a restrictedmem fd
KVM: selftests: Test KVM exit behavior for private memory/access

 tools/testing/selftests/kvm/Makefile          |   1 +
 .../selftests/kvm/include/kvm_util_base.h     |   4 +
 tools/testing/selftests/kvm/lib/kvm_util.c    |  46 ++-
 .../selftests/kvm/set_memory_region_test.c    |  29 +-
 .../kvm/x86_64/private_mem_conversions_test.c | 295 +++++++++++++++---
 .../kvm/x86_64/private_mem_kvm_exits_test.c   | 124 ++++++++
 tools/testing/selftests/vm/memfd_restricted.c |   9 +-
 7 files changed, 455 insertions(+), 53 deletions(-)
 create mode 100644 tools/testing/selftests/kvm/x86_64/private_mem_kvm_exits_test.c

--
2.40.0.rc2.332.ga46443480c-goog