diff options
author | Frederic Weisbecker <frederic@kernel.org> | 2024-01-12 18:46:19 +0300 |
---|---|---|
committer | Boqun Feng <boqun.feng@gmail.com> | 2024-02-14 18:51:36 +0300 |
commit | 8e5e621566485a3e160c0d8bfba206cb1d6b980d (patch) | |
tree | ac9a02f263304cd2e7ce2e6a39a7f6bd87718517 /kernel/rcu/tree.h | |
parent | c19e5d3b497a3036f800edf751dc7814e3e887e1 (diff) | |
download | linux-8e5e621566485a3e160c0d8bfba206cb1d6b980d.tar.xz |
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. */ |