diff options
author | Shannon Zhao <shannon.zhao@linaro.org> | 2015-09-11 03:18:05 -0400 |
---|---|---|
committer | Marc Zyngier <marc.zyngier@arm.com> | 2016-02-29 13:34:21 -0500 |
commit | 5f0a714a2b63c25ffba5d832773f3ca4f0d02e21 (patch) | |
tree | d6120aa7da15b3ef5ae1ef7d0471eef506b0367e /include/kvm | |
parent | 2aa36e9840d71710f06b3c29634f044fde8bcbe5 (diff) |
arm64: KVM: Free perf event of PMU when destroying vcpu
When KVM frees VCPU, it needs to free the perf_event of PMU.
Signed-off-by: Shannon Zhao <shannon.zhao@linaro.org>
Reviewed-by: Marc Zyngier <marc.zyngier@arm.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'include/kvm')
-rw-r--r-- | include/kvm/arm_pmu.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/kvm/arm_pmu.h b/include/kvm/arm_pmu.h index b4993eb76aa1..9f87d717ef84 100644 --- a/include/kvm/arm_pmu.h +++ b/include/kvm/arm_pmu.h | |||
@@ -43,6 +43,7 @@ u64 kvm_pmu_get_counter_value(struct kvm_vcpu *vcpu, u64 select_idx); | |||
43 | void kvm_pmu_set_counter_value(struct kvm_vcpu *vcpu, u64 select_idx, u64 val); | 43 | void kvm_pmu_set_counter_value(struct kvm_vcpu *vcpu, u64 select_idx, u64 val); |
44 | u64 kvm_pmu_valid_counter_mask(struct kvm_vcpu *vcpu); | 44 | u64 kvm_pmu_valid_counter_mask(struct kvm_vcpu *vcpu); |
45 | void kvm_pmu_vcpu_reset(struct kvm_vcpu *vcpu); | 45 | void kvm_pmu_vcpu_reset(struct kvm_vcpu *vcpu); |
46 | void kvm_pmu_vcpu_destroy(struct kvm_vcpu *vcpu); | ||
46 | void kvm_pmu_disable_counter(struct kvm_vcpu *vcpu, u64 val); | 47 | void kvm_pmu_disable_counter(struct kvm_vcpu *vcpu, u64 val); |
47 | void kvm_pmu_enable_counter(struct kvm_vcpu *vcpu, u64 val); | 48 | void kvm_pmu_enable_counter(struct kvm_vcpu *vcpu, u64 val); |
48 | void kvm_pmu_overflow_set(struct kvm_vcpu *vcpu, u64 val); | 49 | void kvm_pmu_overflow_set(struct kvm_vcpu *vcpu, u64 val); |
@@ -69,6 +70,7 @@ static inline u64 kvm_pmu_valid_counter_mask(struct kvm_vcpu *vcpu) | |||
69 | return 0; | 70 | return 0; |
70 | } | 71 | } |
71 | static inline void kvm_pmu_vcpu_reset(struct kvm_vcpu *vcpu) {} | 72 | static inline void kvm_pmu_vcpu_reset(struct kvm_vcpu *vcpu) {} |
73 | static inline void kvm_pmu_vcpu_destroy(struct kvm_vcpu *vcpu) {} | ||
72 | static inline void kvm_pmu_disable_counter(struct kvm_vcpu *vcpu, u64 val) {} | 74 | static inline void kvm_pmu_disable_counter(struct kvm_vcpu *vcpu, u64 val) {} |
73 | static inline void kvm_pmu_enable_counter(struct kvm_vcpu *vcpu, u64 val) {} | 75 | static inline void kvm_pmu_enable_counter(struct kvm_vcpu *vcpu, u64 val) {} |
74 | static inline void kvm_pmu_overflow_set(struct kvm_vcpu *vcpu, u64 val) {} | 76 | static inline void kvm_pmu_overflow_set(struct kvm_vcpu *vcpu, u64 val) {} |