Skip to content

Commit

Permalink
rcu: Dump specified number of blocked tasks
Browse files Browse the repository at this point in the history
The dump_blkd_tasks() function dumps at most 10 blocked tasks, ignoring
the value of the ncheck parameter.  This commit therefore substitutes
the value of ncheck for the hard-coded value of 10.  Because all callers
currently pass 10 as the number, this patch does not change behavior,
but it is clearly an accident waiting to happen.

Signed-off-by: Neeraj Upadhyay <[email protected]>
Reviewed-by: Mukesh Ojha <[email protected]>
Signed-off-by: Paul E. McKenney <[email protected]>
  • Loading branch information
Neeraj Upadhyay authored and Paul E. McKenney committed May 28, 2019
1 parent a188339 commit cd6d17b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/rcu/tree_plugin.h
Original file line number Diff line number Diff line change
Expand Up @@ -760,7 +760,7 @@ dump_blkd_tasks(struct rcu_node *rnp, int ncheck)
i = 0;
list_for_each(lhp, &rnp->blkd_tasks) {
pr_cont(" %p", lhp);
if (++i >= 10)
if (++i >= ncheck)
break;
}
pr_cont("\n");
Expand Down

0 comments on commit cd6d17b

Please sign in to comment.