summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@kernel.org>2022-05-17 16:47:40 -0700
committerPaul E. McKenney <paulmck@kernel.org>2022-06-20 09:22:29 -0700
commit387c0ad702296c4eb7b95322c8af0e4391bf146f (patch)
treed99bce30468a0e922384e24414509e9f8e086b43
parent0bcb386857376224b5fd3f38b6e3173ec74d8d36 (diff)
downloadlwn-387c0ad702296c4eb7b95322c8af0e4391bf146f.tar.gz
lwn-387c0ad702296c4eb7b95322c8af0e4391bf146f.zip
rcu-tasks: Add blocked-task indicator to RCU Tasks Trace stall warnings
This commit adds a "B" indicator to the RCU Tasks Trace CPU stall warning when the task has blocked within its current read-side critical section. This serves as a debugging aid. Signed-off-by: Paul E. McKenney <paulmck@kernel.org> Cc: Neeraj Upadhyay <quic_neeraju@quicinc.com> Cc: Eric Dumazet <edumazet@google.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Andrii Nakryiko <andrii@kernel.org> Cc: Martin KaFai Lau <kafai@fb.com> Cc: KP Singh <kpsingh@kernel.org>
-rw-r--r--kernel/rcu/tasks.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/rcu/tasks.h b/kernel/rcu/tasks.h
index eb87a759ef0b..6f4b89f9517e 100644
--- a/kernel/rcu/tasks.h
+++ b/kernel/rcu/tasks.h
@@ -1536,11 +1536,12 @@ static void show_stalled_task_trace(struct task_struct *t, bool *firstreport)
".I"[t->trc_ipi_to_cpu >= 0],
".i"[is_idle_tsk]);
else
- pr_alert("P%d: %c%c%c nesting: %d%c%c cpu: %d%s\n",
+ pr_alert("P%d: %c%c%c%c nesting: %d%c%c cpu: %d%s\n",
t->pid,
".I"[trc_rdr.ipi_to_cpu >= 0],
".i"[is_idle_tsk],
".N"[cpu >= 0 && tick_nohz_full_cpu(cpu)],
+ ".B"[!!data_race(t->trc_reader_special.b.blocked)],
trc_rdr.nesting,
" !CN"[trc_rdr.needqs & 0x3],
" ?"[trc_rdr.needqs > 0x3],