diff mbox series

[v3,11/14] KVM: selftests: Use vcpu_arch_put_guest() in mmu_stress_test

Message ID 20241009154953.1073471-12-seanjc@google.com (mailing list archive)
State Handled Elsewhere
Headers show
Series KVM: selftests: Morph max_guest_mem to mmu_stress | expand

Checks

Context Check Description
conchuod/vmtest-fixes-PR fail merge-conflict
conchuod/vmtest-for-next-PR success PR summary
conchuod/patch-11-test-1 success .github/scripts/patches/tests/build_rv32_defconfig.sh took 99.67s
conchuod/patch-11-test-2 success .github/scripts/patches/tests/build_rv64_clang_allmodconfig.sh took 935.43s
conchuod/patch-11-test-3 success .github/scripts/patches/tests/build_rv64_gcc_allmodconfig.sh took 1118.03s
conchuod/patch-11-test-4 success .github/scripts/patches/tests/build_rv64_nommu_k210_defconfig.sh took 16.25s
conchuod/patch-11-test-5 success .github/scripts/patches/tests/build_rv64_nommu_virt_defconfig.sh took 17.86s
conchuod/patch-11-test-6 warning .github/scripts/patches/tests/checkpatch.sh took 0.35s
conchuod/patch-11-test-7 success .github/scripts/patches/tests/dtb_warn_rv64.sh took 34.79s
conchuod/patch-11-test-8 success .github/scripts/patches/tests/header_inline.sh took 0.00s
conchuod/patch-11-test-9 success .github/scripts/patches/tests/kdoc.sh took 0.45s
conchuod/patch-11-test-10 success .github/scripts/patches/tests/module_param.sh took 0.01s
conchuod/patch-11-test-11 success .github/scripts/patches/tests/verify_fixes.sh took 0.00s
conchuod/patch-11-test-12 success .github/scripts/patches/tests/verify_signedoff.sh took 0.03s

Commit Message

Sean Christopherson Oct. 9, 2024, 3:49 p.m. UTC
Use vcpu_arch_put_guest() to write memory from the guest in
mmu_stress_test as an easy way to provide a bit of extra coverage.

Reviewed-by: James Houghton <jthoughton@google.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
---
 tools/testing/selftests/kvm/mmu_stress_test.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/tools/testing/selftests/kvm/mmu_stress_test.c b/tools/testing/selftests/kvm/mmu_stress_test.c
index fbb693428a82..656a837c7f49 100644
--- a/tools/testing/selftests/kvm/mmu_stress_test.c
+++ b/tools/testing/selftests/kvm/mmu_stress_test.c
@@ -23,7 +23,7 @@  static void guest_code(uint64_t start_gpa, uint64_t end_gpa, uint64_t stride)
 
 	for (;;) {
 		for (gpa = start_gpa; gpa < end_gpa; gpa += stride)
-			*((volatile uint64_t *)gpa) = gpa;
+			vcpu_arch_put_guest(*((volatile uint64_t *)gpa), gpa);
 		GUEST_SYNC(0);
 	}
 }