diff options
-rw-r--r-- | arch/x86/include/asm/irq.h | 5 | ||||
-rw-r--r-- | arch/x86/kernel/apic/vector.c | 11 | ||||
-rw-r--r-- | arch/x86/kernel/irq.c | 2 |
3 files changed, 11 insertions, 7 deletions
diff --git a/arch/x86/include/asm/irq.h b/arch/x86/include/asm/irq.h index 881b4768644a..e7de5c9a4fbd 100644 --- a/arch/x86/include/asm/irq.h +++ b/arch/x86/include/asm/irq.h | |||
@@ -23,11 +23,13 @@ extern void irq_ctx_init(int cpu); | |||
23 | 23 | ||
24 | #define __ARCH_HAS_DO_SOFTIRQ | 24 | #define __ARCH_HAS_DO_SOFTIRQ |
25 | 25 | ||
26 | struct irq_desc; | ||
27 | |||
26 | #ifdef CONFIG_HOTPLUG_CPU | 28 | #ifdef CONFIG_HOTPLUG_CPU |
27 | #include <linux/cpumask.h> | 29 | #include <linux/cpumask.h> |
28 | extern int check_irq_vectors_for_cpu_disable(void); | 30 | extern int check_irq_vectors_for_cpu_disable(void); |
29 | extern void fixup_irqs(void); | 31 | extern void fixup_irqs(void); |
30 | extern void irq_force_complete_move(int); | 32 | extern void irq_force_complete_move(struct irq_desc *desc); |
31 | #endif | 33 | #endif |
32 | 34 | ||
33 | #ifdef CONFIG_HAVE_KVM | 35 | #ifdef CONFIG_HAVE_KVM |
@@ -37,7 +39,6 @@ extern void kvm_set_posted_intr_wakeup_handler(void (*handler)(void)); | |||
37 | extern void (*x86_platform_ipi_callback)(void); | 39 | extern void (*x86_platform_ipi_callback)(void); |
38 | extern void native_init_IRQ(void); | 40 | extern void native_init_IRQ(void); |
39 | 41 | ||
40 | struct irq_desc; | ||
41 | extern bool handle_irq(struct irq_desc *desc, struct pt_regs *regs); | 42 | extern bool handle_irq(struct irq_desc *desc, struct pt_regs *regs); |
42 | 43 | ||
43 | extern __visible unsigned int do_IRQ(struct pt_regs *regs); | 44 | extern __visible unsigned int do_IRQ(struct pt_regs *regs); |
diff --git a/arch/x86/kernel/apic/vector.c b/arch/x86/kernel/apic/vector.c index a7fa11e49582..5f7883578880 100644 --- a/arch/x86/kernel/apic/vector.c +++ b/arch/x86/kernel/apic/vector.c | |||
@@ -630,10 +630,14 @@ void irq_complete_move(struct irq_cfg *cfg) | |||
630 | __irq_complete_move(cfg, ~get_irq_regs()->orig_ax); | 630 | __irq_complete_move(cfg, ~get_irq_regs()->orig_ax); |
631 | } | 631 | } |
632 | 632 | ||
633 | void irq_force_complete_move(int irq) | 633 | /* |
634 | * Called with @desc->lock held and interrupts disabled. | ||
635 | */ | ||
636 | void irq_force_complete_move(struct irq_desc *desc) | ||
634 | { | 637 | { |
635 | struct irq_cfg *cfg = irq_cfg(irq); | 638 | struct irq_data *irqdata = irq_desc_get_irq_data(desc); |
636 | struct apic_chip_data *data; | 639 | struct apic_chip_data *data = apic_chip_data(irqdata); |
640 | struct irq_cfg *cfg = data ? &data->cfg : NULL; | ||
637 | 641 | ||
638 | if (!cfg) | 642 | if (!cfg) |
639 | return; | 643 | return; |
@@ -647,7 +651,6 @@ void irq_force_complete_move(int irq) | |||
647 | * the way out. | 651 | * the way out. |
648 | */ | 652 | */ |
649 | raw_spin_lock(&vector_lock); | 653 | raw_spin_lock(&vector_lock); |
650 | data = container_of(cfg, struct apic_chip_data, cfg); | ||
651 | cpumask_clear_cpu(smp_processor_id(), data->old_domain); | 654 | cpumask_clear_cpu(smp_processor_id(), data->old_domain); |
652 | raw_spin_unlock(&vector_lock); | 655 | raw_spin_unlock(&vector_lock); |
653 | } | 656 | } |
diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c index c0b58dd1ca04..61521dc19c10 100644 --- a/arch/x86/kernel/irq.c +++ b/arch/x86/kernel/irq.c | |||
@@ -462,7 +462,7 @@ void fixup_irqs(void) | |||
462 | * non intr-remapping case, we can't wait till this interrupt | 462 | * non intr-remapping case, we can't wait till this interrupt |
463 | * arrives at this cpu before completing the irq move. | 463 | * arrives at this cpu before completing the irq move. |
464 | */ | 464 | */ |
465 | irq_force_complete_move(irq); | 465 | irq_force_complete_move(desc); |
466 | 466 | ||
467 | if (cpumask_any_and(affinity, cpu_online_mask) >= nr_cpu_ids) { | 467 | if (cpumask_any_and(affinity, cpu_online_mask) >= nr_cpu_ids) { |
468 | break_affinity = 1; | 468 | break_affinity = 1; |