aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kvm/svm.c1
-rw-r--r--arch/x86/kvm/vmx.c1
-rw-r--r--arch/x86/kvm/x86.c1
-rw-r--r--include/asm-x86/kvm_host.h1
4 files changed, 4 insertions, 0 deletions
diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
index 60228888d1b5..9b54550fa4d2 100644
--- a/arch/x86/kvm/svm.c
+++ b/arch/x86/kvm/svm.c
@@ -1519,6 +1519,7 @@ static inline void svm_inject_irq(struct vcpu_svm *svm, int irq)
1519 1519
1520 KVMTRACE_1D(INJ_VIRQ, &svm->vcpu, (u32)irq, handler); 1520 KVMTRACE_1D(INJ_VIRQ, &svm->vcpu, (u32)irq, handler);
1521 1521
1522 ++svm->vcpu.stat.irq_injections;
1522 control = &svm->vmcb->control; 1523 control = &svm->vmcb->control;
1523 control->int_vector = irq; 1524 control->int_vector = irq;
1524 control->int_ctl &= ~V_INTR_PRIO_MASK; 1525 control->int_ctl &= ~V_INTR_PRIO_MASK;
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 71e57ae1cab7..e7e8c86f1b7d 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -2341,6 +2341,7 @@ static void vmx_inject_irq(struct kvm_vcpu *vcpu, int irq)
2341 2341
2342 KVMTRACE_1D(INJ_VIRQ, vcpu, (u32)irq, handler); 2342 KVMTRACE_1D(INJ_VIRQ, vcpu, (u32)irq, handler);
2343 2343
2344 ++vcpu->stat.irq_injections;
2344 if (vcpu->arch.rmode.active) { 2345 if (vcpu->arch.rmode.active) {
2345 vmx->rmode.irq.pending = true; 2346 vmx->rmode.irq.pending = true;
2346 vmx->rmode.irq.vector = irq; 2347 vmx->rmode.irq.vector = irq;
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index e3b89662cf6d..3f3cb7107c03 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -92,6 +92,7 @@ struct kvm_stats_debugfs_item debugfs_entries[] = {
92 { "fpu_reload", VCPU_STAT(fpu_reload) }, 92 { "fpu_reload", VCPU_STAT(fpu_reload) },
93 { "insn_emulation", VCPU_STAT(insn_emulation) }, 93 { "insn_emulation", VCPU_STAT(insn_emulation) },
94 { "insn_emulation_fail", VCPU_STAT(insn_emulation_fail) }, 94 { "insn_emulation_fail", VCPU_STAT(insn_emulation_fail) },
95 { "irq_injections", VCPU_STAT(irq_injections) },
95 { "mmu_shadow_zapped", VM_STAT(mmu_shadow_zapped) }, 96 { "mmu_shadow_zapped", VM_STAT(mmu_shadow_zapped) },
96 { "mmu_pte_write", VM_STAT(mmu_pte_write) }, 97 { "mmu_pte_write", VM_STAT(mmu_pte_write) },
97 { "mmu_pte_updated", VM_STAT(mmu_pte_updated) }, 98 { "mmu_pte_updated", VM_STAT(mmu_pte_updated) },
diff --git a/include/asm-x86/kvm_host.h b/include/asm-x86/kvm_host.h
index b6d26b80b75b..68a3ac13afce 100644
--- a/include/asm-x86/kvm_host.h
+++ b/include/asm-x86/kvm_host.h
@@ -413,6 +413,7 @@ struct kvm_vcpu_stat {
413 u32 insn_emulation; 413 u32 insn_emulation;
414 u32 insn_emulation_fail; 414 u32 insn_emulation_fail;
415 u32 hypercalls; 415 u32 hypercalls;
416 u32 irq_injections;
416}; 417};
417 418
418struct descriptor_table { 419struct descriptor_table {