aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kvm/lapic.c8
-rw-r--r--virt/kvm/ioapic.h2
-rw-r--r--virt/kvm/irq_comm.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c
index f0b67f2cdd69..6aa8d20f9eeb 100644
--- a/arch/x86/kvm/lapic.c
+++ b/arch/x86/kvm/lapic.c
@@ -409,7 +409,7 @@ static int __apic_accept_irq(struct kvm_lapic *apic, int delivery_mode,
409} 409}
410 410
411static struct kvm_lapic *kvm_apic_round_robin(struct kvm *kvm, u8 vector, 411static struct kvm_lapic *kvm_apic_round_robin(struct kvm *kvm, u8 vector,
412 unsigned long bitmap) 412 unsigned long *bitmap)
413{ 413{
414 int last; 414 int last;
415 int next; 415 int next;
@@ -421,7 +421,7 @@ static struct kvm_lapic *kvm_apic_round_robin(struct kvm *kvm, u8 vector,
421 do { 421 do {
422 if (++next == KVM_MAX_VCPUS) 422 if (++next == KVM_MAX_VCPUS)
423 next = 0; 423 next = 0;
424 if (kvm->vcpus[next] == NULL || !test_bit(next, &bitmap)) 424 if (kvm->vcpus[next] == NULL || !test_bit(next, bitmap))
425 continue; 425 continue;
426 apic = kvm->vcpus[next]->arch.apic; 426 apic = kvm->vcpus[next]->arch.apic;
427 if (apic && apic_enabled(apic)) 427 if (apic && apic_enabled(apic))
@@ -437,7 +437,7 @@ static struct kvm_lapic *kvm_apic_round_robin(struct kvm *kvm, u8 vector,
437} 437}
438 438
439struct kvm_vcpu *kvm_get_lowest_prio_vcpu(struct kvm *kvm, u8 vector, 439struct kvm_vcpu *kvm_get_lowest_prio_vcpu(struct kvm *kvm, u8 vector,
440 unsigned long bitmap) 440 unsigned long *bitmap)
441{ 441{
442 struct kvm_lapic *apic; 442 struct kvm_lapic *apic;
443 443
@@ -508,7 +508,7 @@ static void apic_send_ipi(struct kvm_lapic *apic)
508 } 508 }
509 509
510 if (delivery_mode == APIC_DM_LOWEST) { 510 if (delivery_mode == APIC_DM_LOWEST) {
511 target = kvm_get_lowest_prio_vcpu(vcpu->kvm, vector, lpr_map); 511 target = kvm_get_lowest_prio_vcpu(vcpu->kvm, vector, &lpr_map);
512 if (target != NULL) 512 if (target != NULL)
513 __apic_accept_irq(target->arch.apic, delivery_mode, 513 __apic_accept_irq(target->arch.apic, delivery_mode,
514 vector, level, trig_mode); 514 vector, level, trig_mode);
diff --git a/virt/kvm/ioapic.h b/virt/kvm/ioapic.h
index f395798bc1d1..7275f87a11cd 100644
--- a/virt/kvm/ioapic.h
+++ b/virt/kvm/ioapic.h
@@ -65,7 +65,7 @@ static inline struct kvm_ioapic *ioapic_irqchip(struct kvm *kvm)
65} 65}
66 66
67struct kvm_vcpu *kvm_get_lowest_prio_vcpu(struct kvm *kvm, u8 vector, 67struct kvm_vcpu *kvm_get_lowest_prio_vcpu(struct kvm *kvm, u8 vector,
68 unsigned long bitmap); 68 unsigned long *bitmap);
69void kvm_ioapic_update_eoi(struct kvm *kvm, int vector, int trigger_mode); 69void kvm_ioapic_update_eoi(struct kvm *kvm, int vector, int trigger_mode);
70int kvm_ioapic_init(struct kvm *kvm); 70int kvm_ioapic_init(struct kvm *kvm);
71int kvm_ioapic_set_irq(struct kvm_ioapic *ioapic, int irq, int level); 71int kvm_ioapic_set_irq(struct kvm_ioapic *ioapic, int irq, int level);
diff --git a/virt/kvm/irq_comm.c b/virt/kvm/irq_comm.c
index e8ff89c3cca7..d4421cd6d663 100644
--- a/virt/kvm/irq_comm.c
+++ b/virt/kvm/irq_comm.c
@@ -55,7 +55,7 @@ void kvm_get_intr_delivery_bitmask(struct kvm_ioapic *ioapic,
55 switch (entry->fields.delivery_mode) { 55 switch (entry->fields.delivery_mode) {
56 case IOAPIC_LOWEST_PRIORITY: 56 case IOAPIC_LOWEST_PRIORITY:
57 vcpu = kvm_get_lowest_prio_vcpu(ioapic->kvm, 57 vcpu = kvm_get_lowest_prio_vcpu(ioapic->kvm,
58 entry->fields.vector, *deliver_bitmask); 58 entry->fields.vector, deliver_bitmask);
59 *deliver_bitmask = 1 << vcpu->vcpu_id; 59 *deliver_bitmask = 1 << vcpu->vcpu_id;
60 break; 60 break;
61 case IOAPIC_FIXED: 61 case IOAPIC_FIXED: