aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>2016-06-30 14:56:38 -0400
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2016-08-22 13:02:59 -0400
commit4ffa66992476c94d8b4d33b2c792d336a400ada2 (patch)
tree4525c3cb782a312431d324b7619155a6b54727f7
parent31257c3c8b7307f106d67345755d937cb5fb8bd4 (diff)
torture: Add task state to writer-task stall printk()s
This commit adds a dump of the scheduler state for stalled rcutorture writer tasks. This addition provides yet more debug for the intermittent "failures to proceed", where grace periods move ahead but the rcutorture writer tasks fail to do so. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
-rw-r--r--kernel/rcu/rcutorture.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/kernel/rcu/rcutorture.c b/kernel/rcu/rcutorture.c
index 971e2b138063..f0f32f888ec5 100644
--- a/kernel/rcu/rcutorture.c
+++ b/kernel/rcu/rcutorture.c
@@ -1238,6 +1238,7 @@ rcu_torture_stats_print(void)
1238 long pipesummary[RCU_TORTURE_PIPE_LEN + 1] = { 0 }; 1238 long pipesummary[RCU_TORTURE_PIPE_LEN + 1] = { 0 };
1239 long batchsummary[RCU_TORTURE_PIPE_LEN + 1] = { 0 }; 1239 long batchsummary[RCU_TORTURE_PIPE_LEN + 1] = { 0 };
1240 static unsigned long rtcv_snap = ULONG_MAX; 1240 static unsigned long rtcv_snap = ULONG_MAX;
1241 struct task_struct *wtp;
1241 1242
1242 for_each_possible_cpu(cpu) { 1243 for_each_possible_cpu(cpu) {
1243 for (i = 0; i < RCU_TORTURE_PIPE_LEN + 1; i++) { 1244 for (i = 0; i < RCU_TORTURE_PIPE_LEN + 1; i++) {
@@ -1312,10 +1313,12 @@ rcu_torture_stats_print(void)
1312 1313
1313 rcutorture_get_gp_data(cur_ops->ttype, 1314 rcutorture_get_gp_data(cur_ops->ttype,
1314 &flags, &gpnum, &completed); 1315 &flags, &gpnum, &completed);
1315 pr_alert("??? Writer stall state %s(%d) g%lu c%lu f%#x\n", 1316 wtp = READ_ONCE(writer_task);
1317 pr_alert("??? Writer stall state %s(%d) g%lu c%lu f%#x ->state %#lx\n",
1316 rcu_torture_writer_state_getname(), 1318 rcu_torture_writer_state_getname(),
1317 rcu_torture_writer_state, 1319 rcu_torture_writer_state,
1318 gpnum, completed, flags); 1320 gpnum, completed, flags,
1321 wtp == NULL ? ~0UL : wtp->state);
1319 show_rcu_gp_kthreads(); 1322 show_rcu_gp_kthreads();
1320 rcu_ftrace_dump(DUMP_ALL); 1323 rcu_ftrace_dump(DUMP_ALL);
1321 } 1324 }