OSDN Git Service

KVM: selftests: Expect #PF(RSVD) when TDP is disabled
authorDavid Matlack <dmatlack@google.com>
Wed, 2 Nov 2022 18:46:53 +0000 (11:46 -0700)
committerSean Christopherson <seanjc@google.com>
Thu, 17 Nov 2022 00:59:01 +0000 (16:59 -0800)
commita323845d6c3d2f667274bde8145906580359fe06
tree66aee90186ffba0caf31f9ec8a81ed7bfe5a0cf3
parentb9635930f0a73c1ef7b465121896c3fb2e3b77cd
KVM: selftests: Expect #PF(RSVD) when TDP is disabled

Change smaller_maxphyaddr_emulation_test to expect a #PF(RSVD), rather
than an emulation failure, when TDP is disabled. KVM only needs to
emulate instructions to emulate a smaller guest.MAXPHYADDR when TDP is
enabled.

Fixes: 39bbcc3a4e39 ("selftests: kvm: Allows userspace to handle emulation errors.")
Signed-off-by: David Matlack <dmatlack@google.com>
Link: https://lore.kernel.org/r/20221102184654.282799-10-dmatlack@google.com
[sean: massage comment to talk about having to emulate due to MAXPHYADDR]
Signed-off-by: Sean Christopherson <seanjc@google.com>
tools/testing/selftests/kvm/x86_64/smaller_maxphyaddr_emulation_test.c