Skip to content

Commit 5dc31b5

Browse files
committed
Merge branch 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull two small RCU fixlets from Ingo Molnar. * 'core-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: rcu: Make rcu_nocb_poll an early_param instead of module_param rcu: Prevent soft-lockup complaints about no-CBs CPUs
2 parents d92dd35 + d36b7b9 commit 5dc31b5

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

Documentation/kernel-parameters.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2438,7 +2438,7 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
24382438
real-time workloads. It can also improve energy
24392439
efficiency for asymmetric multiprocessors.
24402440

2441-
rcu_nocbs_poll [KNL,BOOT]
2441+
rcu_nocb_poll [KNL,BOOT]
24422442
Rather than requiring that offloaded CPUs
24432443
(specified by rcu_nocbs= above) explicitly
24442444
awaken the corresponding "rcuoN" kthreads,

kernel/rcutree_plugin.h

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,7 @@
4040
#ifdef CONFIG_RCU_NOCB_CPU
4141
static cpumask_var_t rcu_nocb_mask; /* CPUs to have callbacks offloaded. */
4242
static bool have_rcu_nocb_mask; /* Was rcu_nocb_mask allocated? */
43-
static bool rcu_nocb_poll; /* Offload kthread are to poll. */
44-
module_param(rcu_nocb_poll, bool, 0444);
43+
static bool __read_mostly rcu_nocb_poll; /* Offload kthread are to poll. */
4544
static char __initdata nocb_buf[NR_CPUS * 5];
4645
#endif /* #ifdef CONFIG_RCU_NOCB_CPU */
4746

@@ -2159,6 +2158,13 @@ static int __init rcu_nocb_setup(char *str)
21592158
}
21602159
__setup("rcu_nocbs=", rcu_nocb_setup);
21612160

2161+
static int __init parse_rcu_nocb_poll(char *arg)
2162+
{
2163+
rcu_nocb_poll = 1;
2164+
return 0;
2165+
}
2166+
early_param("rcu_nocb_poll", parse_rcu_nocb_poll);
2167+
21622168
/* Is the specified CPU a no-CPUs CPU? */
21632169
static bool is_nocb_cpu(int cpu)
21642170
{
@@ -2366,10 +2372,11 @@ static int rcu_nocb_kthread(void *arg)
23662372
for (;;) {
23672373
/* If not polling, wait for next batch of callbacks. */
23682374
if (!rcu_nocb_poll)
2369-
wait_event(rdp->nocb_wq, rdp->nocb_head);
2375+
wait_event_interruptible(rdp->nocb_wq, rdp->nocb_head);
23702376
list = ACCESS_ONCE(rdp->nocb_head);
23712377
if (!list) {
23722378
schedule_timeout_interruptible(1);
2379+
flush_signals(current);
23732380
continue;
23742381
}
23752382

0 commit comments

Comments
 (0)