diff options
author | Gleb Natapov <gleb@redhat.com> | 2009-08-24 04:54:26 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2009-12-03 02:32:08 -0500 |
commit | 680b3648ba89c44ac8d0316f78a0d6e147b88809 (patch) | |
tree | b2b40034c4c33affef8b89822673cca835874651 /virt/kvm/kvm_main.c | |
parent | eba0226bdfffe262e72b8360e4d0d12070e9a0f0 (diff) |
KVM: Drop kvm->irq_lock lock from irq injection path
The only thing it protects now is interrupt injection into lapic and
this can work lockless. Even now with kvm->irq_lock in place access
to lapic is not entirely serialized since vcpu access doesn't take
kvm->irq_lock.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'virt/kvm/kvm_main.c')
-rw-r--r-- | virt/kvm/kvm_main.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 6eca153e1a02..c12c95b1b641 100644 --- a/virt/kvm/kvm_main.c +++ b/virt/kvm/kvm_main.c | |||
@@ -137,7 +137,6 @@ static void kvm_assigned_dev_interrupt_work_handler(struct work_struct *work) | |||
137 | interrupt_work); | 137 | interrupt_work); |
138 | kvm = assigned_dev->kvm; | 138 | kvm = assigned_dev->kvm; |
139 | 139 | ||
140 | mutex_lock(&kvm->irq_lock); | ||
141 | spin_lock_irq(&assigned_dev->assigned_dev_lock); | 140 | spin_lock_irq(&assigned_dev->assigned_dev_lock); |
142 | if (assigned_dev->irq_requested_type & KVM_DEV_IRQ_HOST_MSIX) { | 141 | if (assigned_dev->irq_requested_type & KVM_DEV_IRQ_HOST_MSIX) { |
143 | struct kvm_guest_msix_entry *guest_entries = | 142 | struct kvm_guest_msix_entry *guest_entries = |
@@ -156,7 +155,6 @@ static void kvm_assigned_dev_interrupt_work_handler(struct work_struct *work) | |||
156 | assigned_dev->guest_irq, 1); | 155 | assigned_dev->guest_irq, 1); |
157 | 156 | ||
158 | spin_unlock_irq(&assigned_dev->assigned_dev_lock); | 157 | spin_unlock_irq(&assigned_dev->assigned_dev_lock); |
159 | mutex_unlock(&assigned_dev->kvm->irq_lock); | ||
160 | } | 158 | } |
161 | 159 | ||
162 | static irqreturn_t kvm_assigned_dev_intr(int irq, void *dev_id) | 160 | static irqreturn_t kvm_assigned_dev_intr(int irq, void *dev_id) |