]> git.baikalelectronics.ru Git - kernel.git/commit
rcu: Create call_rcu_tasks() kthread at boot time
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Fri, 11 Aug 2017 19:37:07 +0000 (12:37 -0700)
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Mon, 9 Oct 2017 21:24:14 +0000 (14:24 -0700)
commit1b25b8c260dd1fcad4f4bfea5590f49d10a0bf82
tree3a985b57593a3ce64503837b9b55ae99e03483ad
parent27c39d7e44d40d55f3a93b4402991fbe54ce1eee
rcu: Create call_rcu_tasks() kthread at boot time

Currently the call_rcu_tasks() kthread is created upon first
invocation of call_rcu_tasks().  This has the advantage of avoiding
creation if there are never any invocations of call_rcu_tasks() and of
synchronize_rcu_tasks(), but it requires an unreliable heuristic to
determine when it is safe to create the kthread.  For example, it is
not safe to create the kthread when call_rcu_tasks() is invoked with
a spinlock held, but there is no good way to detect this in !PREEMPT
kernels.

This commit therefore creates this kthread unconditionally at
core_initcall() time.  If you don't want this kthread created, then
build with CONFIG_TASKS_RCU=n.

Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
kernel/rcu/update.c