diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2015-12-31 11:30:52 -0500 |
|---|---|---|
| committer | Thomas Gleixner <tglx@linutronix.de> | 2016-01-15 07:44:01 -0500 |
| commit | 56d7d2f4bbd00fb198b7907cb3ab657d06115a42 (patch) | |
| tree | 68abc85548849ef65c4501c647e1ae3e2d0015be | |
| parent | 5da0c1217f05d2ccc9a8ed6e6e5c23a8a1d24dd6 (diff) | |
x86/irq: Remove outgoing CPU from vector cleanup mask
We want to synchronize new vector assignments with a pending cleanup. Remove a
dying cpu from a pending cleanup mask.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Borislav Petkov <bp@alien8.de>
Tested-by: Joe Lawrence <joe.lawrence@stratus.com>
Cc: Jiang Liu <jiang.liu@linux.intel.com>
Cc: Jeremiah Mahler <jmmahler@gmail.com>
Cc: andy.shevchenko@gmail.com
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: stable@vger.kernel.org #4.3+
Link: http://lkml.kernel.org/r/20151231160107.045961667@linutronix.de
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| -rw-r--r-- | arch/x86/kernel/apic/vector.c | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/arch/x86/kernel/apic/vector.c b/arch/x86/kernel/apic/vector.c index 91dc2742cfb1..a7fa11e49582 100644 --- a/arch/x86/kernel/apic/vector.c +++ b/arch/x86/kernel/apic/vector.c | |||
| @@ -633,9 +633,23 @@ void irq_complete_move(struct irq_cfg *cfg) | |||
| 633 | void irq_force_complete_move(int irq) | 633 | void irq_force_complete_move(int irq) |
| 634 | { | 634 | { |
| 635 | struct irq_cfg *cfg = irq_cfg(irq); | 635 | struct irq_cfg *cfg = irq_cfg(irq); |
| 636 | struct apic_chip_data *data; | ||
| 637 | |||
| 638 | if (!cfg) | ||
| 639 | return; | ||
| 636 | 640 | ||
| 637 | if (cfg) | 641 | __irq_complete_move(cfg, cfg->vector); |
| 638 | __irq_complete_move(cfg, cfg->vector); | 642 | |
| 643 | /* | ||
| 644 | * Remove this cpu from the cleanup mask. The IPI might have been sent | ||
| 645 | * just before the cpu was removed from the offline mask, but has not | ||
| 646 | * been processed because the CPU has interrupts disabled and is on | ||
| 647 | * the way out. | ||
| 648 | */ | ||
| 649 | 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); | ||
| 652 | raw_spin_unlock(&vector_lock); | ||
| 639 | } | 653 | } |
| 640 | #endif | 654 | #endif |
| 641 | 655 | ||
