Skip to content

Commit

Permalink
rcu: Avoid invoking RCU core on offline CPUs
Browse files Browse the repository at this point in the history
Offline CPUs transition through the scheduler to the idle loop one
last time before being shut down.  This can result in RCU raising
softirq on this CPU, which is at best useless given that the CPU's
callbacks will be offloaded at CPU_DEAD time.  This commit therefore
avoids raising softirq on offline CPUs.

Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
  • Loading branch information
Paul E. McKenney committed Mar 12, 2013
1 parent b5b3936 commit b0f7403
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kernel/rcutree.c
Original file line number Diff line number Diff line change
Expand Up @@ -2169,7 +2169,8 @@ static void invoke_rcu_callbacks(struct rcu_state *rsp, struct rcu_data *rdp)

static void invoke_rcu_core(void)
{
raise_softirq(RCU_SOFTIRQ);
if (cpu_online(smp_processor_id()))
raise_softirq(RCU_SOFTIRQ);
}

/*
Expand Down

0 comments on commit b0f7403

Please sign in to comment.