Skip to content

Commit 5334da2

Browse files
qiangzh3paulmckrcu
authored andcommitted
rcu/nocb: Choose the right rcuog/rcuop kthreads to output
The show_rcu_nocb_gp_state() function is supposed to dump out the rcuog kthread and the show_rcu_nocb_state() function is supposed to dump out the rcuo[ps] kthread. Currently, both do a mixture, which is not optimal for debugging, even though it does not affect functionality. This commit therefore adjusts these two functions to focus on their respective kthreads. Signed-off-by: Zqiang <[email protected]> Signed-off-by: Paul E. McKenney <[email protected]>
1 parent 568035b commit 5334da2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

kernel/rcu/tree_nocb.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1452,8 +1452,8 @@ static void show_rcu_nocb_gp_state(struct rcu_data *rdp)
14521452
(long)rdp->nocb_gp_seq,
14531453
rnp->grplo, rnp->grphi, READ_ONCE(rdp->nocb_gp_loops),
14541454
rdp->nocb_gp_kthread ? task_state_to_char(rdp->nocb_gp_kthread) : '.',
1455-
rdp->nocb_cb_kthread ? (int)task_cpu(rdp->nocb_gp_kthread) : -1,
1456-
show_rcu_should_be_on_cpu(rdp->nocb_cb_kthread));
1455+
rdp->nocb_gp_kthread ? (int)task_cpu(rdp->nocb_gp_kthread) : -1,
1456+
show_rcu_should_be_on_cpu(rdp->nocb_gp_kthread));
14571457
}
14581458

14591459
/* Dump out nocb kthread state for the specified rcu_data structure. */
@@ -1497,7 +1497,7 @@ static void show_rcu_nocb_state(struct rcu_data *rdp)
14971497
".B"[!!rcu_cblist_n_cbs(&rdp->nocb_bypass)],
14981498
rcu_segcblist_n_cbs(&rdp->cblist),
14991499
rdp->nocb_cb_kthread ? task_state_to_char(rdp->nocb_cb_kthread) : '.',
1500-
rdp->nocb_cb_kthread ? (int)task_cpu(rdp->nocb_gp_kthread) : -1,
1500+
rdp->nocb_cb_kthread ? (int)task_cpu(rdp->nocb_cb_kthread) : -1,
15011501
show_rcu_should_be_on_cpu(rdp->nocb_cb_kthread));
15021502

15031503
/* It is OK for GP kthreads to have GP state. */

0 commit comments

Comments
 (0)