Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1311038 > unrolled thread

[tip:x86/urgent] x86/irq: Remove outgoing CPU from vector cleanup mask

Started bytip-bot for Thomas Gleixner <tipbot@zytor.com>
First post2016-01-16 22:30 +0100
Last post2016-01-16 22:30 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [tip:x86/urgent] x86/irq:   Remove outgoing CPU from vector cleanup mask tip-bot for Thomas Gleixner <tipbot@zytor.com> - 2016-01-16 22:30 +0100

#1311038 — [tip:x86/urgent] x86/irq: Remove outgoing CPU from vector cleanup mask

Fromtip-bot for Thomas Gleixner <tipbot@zytor.com>
Date2016-01-16 22:30 +0100
Subject[tip:x86/urgent] x86/irq: Remove outgoing CPU from vector cleanup mask
Message-ID<qRGA1-1x6-9@gated-at.bofh.it>
Commit-ID:  56d7d2f4bbd00fb198b7907cb3ab657d06115a42
Gitweb:     http://git.kernel.org/tip/56d7d2f4bbd00fb198b7907cb3ab657d06115a42
Author:     Thomas Gleixner <tglx@linutronix.de>
AuthorDate: Thu, 31 Dec 2015 16:30:52 +0000
Committer:  Thomas Gleixner <tglx@linutronix.de>
CommitDate: Fri, 15 Jan 2016 13:44:01 +0100

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>
---
 arch/x86/kernel/apic/vector.c | 18 ++++++++++++++++--
 1 file changed, 16 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/apic/vector.c b/arch/x86/kernel/apic/vector.c
index 91dc274..a7fa11e 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)
 void irq_force_complete_move(int irq)
 {
 	struct irq_cfg *cfg = irq_cfg(irq);
+	struct apic_chip_data *data;
+
+	if (!cfg)
+		return;
 
-	if (cfg)
-		__irq_complete_move(cfg, cfg->vector);
+	__irq_complete_move(cfg, cfg->vector);
+
+	/*
+	 * Remove this cpu from the cleanup mask. The IPI might have been sent
+	 * just before the cpu was removed from the offline mask, but has not
+	 * been processed because the CPU has interrupts disabled and is on
+	 * the way out.
+	 */
+	raw_spin_lock(&vector_lock);
+	data = container_of(cfg, struct apic_chip_data, cfg);
+	cpumask_clear_cpu(smp_processor_id(), data->old_domain);
+	raw_spin_unlock(&vector_lock);
 }
 #endif
 

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web