aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/kvm_host.h
diff options
context:
space:
mode:
authorLan Tianyu <Tianyu.Lan@microsoft.com>2018-12-06 21:21:04 +0800
committerPaolo Bonzini <pbonzini@redhat.com>2018-12-21 11:28:38 +0100
commita49b96352e68368c2e6784d13b0b4b7b8d830922 (patch)
tree0274fdd423b0b3433a155e107bfb9d4180c3d5cb /arch/x86/include/asm/kvm_host.h
parentKVM: x86: Disable Intel PT when VMXON in L1 guest (diff)
downloadlinux-dev-a49b96352e68368c2e6784d13b0b4b7b8d830922.tar.xz
linux-dev-a49b96352e68368c2e6784d13b0b4b7b8d830922.zip
KVM: Add tlb_remote_flush_with_range callback in kvm_x86_ops
Add flush range call back in the kvm_x86_ops and platform can use it to register its associated function. The parameter "kvm_tlb_range" accepts a single range and flush list which contains a list of ranges. Signed-off-by: Lan Tianyu <Tianyu.Lan@microsoft.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to '')
-rw-r--r--arch/x86/include/asm/kvm_host.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index ffb8a853e0d4..3639077d285b 100644
--- a/arch/x86/include/asm/kvm_host.h
+++ b/arch/x86/include/asm/kvm_host.h
@@ -439,6 +439,11 @@ struct kvm_mmu {
u64 pdptrs[4]; /* pae */
};
+struct kvm_tlb_range {
+ u64 start_gfn;
+ u64 pages;
+};
+
enum pmc_type {
KVM_PMC_GP = 0,
KVM_PMC_FIXED,
@@ -1041,6 +1046,8 @@ struct kvm_x86_ops {
void (*tlb_flush)(struct kvm_vcpu *vcpu, bool invalidate_gpa);
int (*tlb_remote_flush)(struct kvm *kvm);
+ int (*tlb_remote_flush_with_range)(struct kvm *kvm,
+ struct kvm_tlb_range *range);
/*
* Flush any TLB entries associated with the given GVA.