linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, x86@kernel.org
Subject: [GIT pull] core/core for 5.19-rc1
Date: Mon, 23 May 2022 10:02:03 +0200 (CEST)	[thread overview]
Message-ID: <165329267741.3801280.534077656528571075.tglx@xen13> (raw)

Linus,

please pull the latest core/core branch from:

   git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git core-core-2022-05-23

up to:  75d8cce128c5: lib/irq_poll: Prevent softirq pending leak in irq_poll_cpu_dead()


A single update for irqpoll:

  - Ensure that a raised soft interrupt is handled after pulling the
    blk_cpu_iopoll backlog from a unplugged CPU. This prevents that the CPU
    which runs that code reaches idle with soft interrupts pending.

Thanks,

	tglx

------------------>
Sebastian Andrzej Siewior (1):
      lib/irq_poll: Prevent softirq pending leak in irq_poll_cpu_dead()


 lib/irq_poll.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/lib/irq_poll.c b/lib/irq_poll.c
index 2f17b488d58e..2d5329a42105 100644
--- a/lib/irq_poll.c
+++ b/lib/irq_poll.c
@@ -188,14 +188,18 @@ EXPORT_SYMBOL(irq_poll_init);
 static int irq_poll_cpu_dead(unsigned int cpu)
 {
 	/*
-	 * If a CPU goes away, splice its entries to the current CPU
-	 * and trigger a run of the softirq
+	 * If a CPU goes away, splice its entries to the current CPU and
+	 * set the POLL softirq bit. The local_bh_disable()/enable() pair
+	 * ensures that it is handled. Otherwise the current CPU could
+	 * reach idle with the POLL softirq pending.
 	 */
+	local_bh_disable();
 	local_irq_disable();
 	list_splice_init(&per_cpu(blk_cpu_iopoll, cpu),
 			 this_cpu_ptr(&blk_cpu_iopoll));
 	__raise_softirq_irqoff(IRQ_POLL_SOFTIRQ);
 	local_irq_enable();
+	local_bh_enable();
 
 	return 0;
 }


             reply	other threads:[~2022-05-23  8:02 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-23  8:02 Thomas Gleixner [this message]
2022-05-23  8:02 ` [GIT pull] core/debugobjects for 5.19-rc1 Thomas Gleixner
2022-05-24  0:22   ` pr-tracker-bot
2022-05-23  8:02 ` [GIT pull] irq/core " Thomas Gleixner
2022-05-24  0:02   ` Linus Torvalds
2022-05-24  8:17     ` Thomas Gleixner
2022-05-24  0:22   ` pr-tracker-bot
2022-05-23  8:02 ` [GIT pull] smp/core " Thomas Gleixner
2022-05-24  0:22   ` pr-tracker-bot
2022-05-23  8:02 ` [GIT pull] timers/core " Thomas Gleixner
2022-05-24  0:11   ` Linus Torvalds
2022-05-24  8:07     ` Thomas Gleixner
2022-05-24  0:22   ` pr-tracker-bot
2022-05-23  8:02 ` [GIT pull] x86/irq " Thomas Gleixner
2022-05-24  0:22   ` pr-tracker-bot
2022-05-24  0:22 ` [GIT pull] core/core " pr-tracker-bot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=165329267741.3801280.534077656528571075.tglx@xen13 \
    --to=tglx@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).