Skip to content

Commit 6f81bd6

Browse files
committed
rcutorture: Print message before invoking ->cb_barrier()
The various ->cb_barrier() functions, for example, rcu_barrier(), sometimes cause rcutorture hangs. But currently, the last console message is the unenlightening "Stopping rcu_torture_stats". This commit therefore prints a message of the form "rcu_torture_cleanup: Invoking rcu_barrier+0x0/0x1e0()" to help point people in the right direction. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
1 parent da12301 commit 6f81bd6

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

kernel/rcu/rcutorture.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2905,8 +2905,10 @@ rcu_torture_cleanup(void)
29052905
int i;
29062906

29072907
if (torture_cleanup_begin()) {
2908-
if (cur_ops->cb_barrier != NULL)
2908+
if (cur_ops->cb_barrier != NULL) {
2909+
pr_info("%s: Invoking %pS().\n", __func__, cur_ops->cb_barrier);
29092910
cur_ops->cb_barrier();
2911+
}
29102912
return;
29112913
}
29122914
if (!cur_ops) {
@@ -2961,8 +2963,10 @@ rcu_torture_cleanup(void)
29612963
* Wait for all RCU callbacks to fire, then do torture-type-specific
29622964
* cleanup operations.
29632965
*/
2964-
if (cur_ops->cb_barrier != NULL)
2966+
if (cur_ops->cb_barrier != NULL) {
2967+
pr_info("%s: Invoking %pS().\n", __func__, cur_ops->cb_barrier);
29652968
cur_ops->cb_barrier();
2969+
}
29662970
if (cur_ops->cleanup != NULL)
29672971
cur_ops->cleanup();
29682972

0 commit comments

Comments
 (0)