Skip to content
Commit 329bd56c authored by Vipin Sharma's avatar Vipin Sharma Committed by Paolo Bonzini
Browse files

KVM: VMX: Add a helper function to retrieve the GPR index for INVPCID, INVVPID, and INVEPT



handle_invept(), handle_invvpid(), handle_invpcid() read the same reg2
field in vmcs.VMX_INSTRUCTION_INFO to get the index of the GPR that
holds the invalidation type. Add a helper to retrieve reg2 from VMX
instruction info to consolidate and document the shift+mask magic.

Signed-off-by: default avatarVipin Sharma <vipinsh@google.com>
Reviewed-by: default avatarSean Christopherson <seanjc@google.com>
Message-Id: <20211109174426.2350547-2-vipinsh@google.com>
Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent a5e0c252
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment