diff options
author | Frederic Weisbecker <frederic@kernel.org> | 2024-01-12 16:46:19 +0100 |
---|---|---|
committer | Boqun Feng <boqun.feng@gmail.com> | 2024-02-14 16:51:36 +0100 |
commit | 8e5e621566485a3e160c0d8bfba206cb1d6b980d (patch) | |
tree | ac9a02f263304cd2e7ce2e6a39a7f6bd87718517 /kernel/rcu/tree.h | |
parent | rcu/exp: Move expedited kthread worker creation functions above rcutree_prepa... (diff) | |
download | linux-8e5e621566485a3e160c0d8bfba206cb1d6b980d.tar.xz linux-8e5e621566485a3e160c0d8bfba206cb1d6b980d.zip |
rcu/exp: Make parallel exp gp kworker per rcu node
When CONFIG_RCU_EXP_KTHREAD=n, the expedited grace period per node
initialization is performed in parallel via workqueues (one work per
node).
However in CONFIG_RCU_EXP_KTHREAD=y, this per node initialization is
performed by a single kworker serializing each node initialization (one
work for all nodes).
The second part is certainly less scalable and efficient beyond a single
leaf node.
To improve this, expand this single kworker into per-node kworkers. This
new layout is eventually intended to remove the workqueues based
implementation since it will essentially now become duplicate code.
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
Reviewed-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Boqun Feng <boqun.feng@gmail.com>
Diffstat (limited to 'kernel/rcu/tree.h')
-rw-r--r-- | kernel/rcu/tree.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/rcu/tree.h b/kernel/rcu/tree.h index 13e7b0d907ab..e173808f486f 100644 --- a/kernel/rcu/tree.h +++ b/kernel/rcu/tree.h @@ -72,6 +72,9 @@ struct rcu_node { /* Online CPUs for next expedited GP. */ /* Any CPU that has ever been online will */ /* have its bit set. */ + struct kthread_worker *exp_kworker; + /* Workers performing per node expedited GP */ + /* initialization. */ unsigned long cbovldmask; /* CPUs experiencing callback overload. */ unsigned long ffmask; /* Fully functional CPUs. */ |