[GIT pull] core/urgent for 5.7-rc2

From: Thomas Gleixner
Date: Sun Apr 19 2020 - 09:58:15 EST


Linus,

please pull the latest core/urgent branch from:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git core-urgent-2020-04-19

up to: 40e7d7bdc19e: Merge branch 'urgent-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu into core/urgent


A single bugfix for RCU to prevent taking a lock in NMI context.

Thanks,

tglx

------------------>
Paul E. McKenney (1):
rcu: Don't acquire lock in NMI handler in rcu_nmi_enter_common()


kernel/rcu/tree.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index 06548e2ebb72..d9a49cd6065a 100644
--- a/kernel/rcu/tree.c
+++ b/kernel/rcu/tree.c
@@ -825,7 +825,7 @@ static __always_inline void rcu_nmi_enter_common(bool irq)
rcu_cleanup_after_idle();

incby = 1;
- } else if (tick_nohz_full_cpu(rdp->cpu) &&
+ } else if (irq && tick_nohz_full_cpu(rdp->cpu) &&
rdp->dynticks_nmi_nesting == DYNTICK_IRQ_NONIDLE &&
READ_ONCE(rdp->rcu_urgent_qs) &&
!READ_ONCE(rdp->rcu_forced_tick)) {