summaryrefslogtreecommitdiffstats
path: root/arch/s390/kvm/interrupt.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2014-03-25 15:44:06 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2014-03-25 15:44:06 +0100
commitf7b9ddb8a5e8a25954217fa25d114bd8cf4491a4 (patch)
tree06837e268d145e59ad46d9cd5f6c36c16f2424c9 /arch/s390/kvm/interrupt.c
parentea2108c9308071ae41ae6f537724cb2734045943 (diff)
parent2ed10cc15e7edf2daf22ce807a877a1266e97711 (diff)
downloadop-kernel-dev-f7b9ddb8a5e8a25954217fa25d114bd8cf4491a4.zip
op-kernel-dev-f7b9ddb8a5e8a25954217fa25d114bd8cf4491a4.tar.gz
Merge tag 'kvm-s390-20140325' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into kvm-next
3 fixes - memory leak on certain SIGP conditions - wrong size for idle bitmap (always too big) - clear local interrupts on initial CPU reset 1 performance improvement - improve performance with many guests on certain workloads
Diffstat (limited to 'arch/s390/kvm/interrupt.c')
-rw-r--r--arch/s390/kvm/interrupt.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/s390/kvm/interrupt.c b/arch/s390/kvm/interrupt.c
index 2e2814e..200a8f9 100644
--- a/arch/s390/kvm/interrupt.c
+++ b/arch/s390/kvm/interrupt.c
@@ -510,6 +510,20 @@ enum hrtimer_restart kvm_s390_idle_wakeup(struct hrtimer *timer)
return HRTIMER_NORESTART;
}
+void kvm_s390_clear_local_irqs(struct kvm_vcpu *vcpu)
+{
+ struct kvm_s390_local_interrupt *li = &vcpu->arch.local_int;
+ struct kvm_s390_interrupt_info *n, *inti = NULL;
+
+ spin_lock_bh(&li->lock);
+ list_for_each_entry_safe(inti, n, &li->list, list) {
+ list_del(&inti->list);
+ kfree(inti);
+ }
+ atomic_set(&li->active, 0);
+ spin_unlock_bh(&li->lock);
+}
+
void kvm_s390_deliver_pending_interrupts(struct kvm_vcpu *vcpu)
{
struct kvm_s390_local_interrupt *li = &vcpu->arch.local_int;
OpenPOWER on IntegriCloud