Skip to content

Commit 2279563

Browse files
arighihtejun
authored andcommitted
sched_ext: Include task weight in the error state dump
Report the task weight when dumping the task state during an error exit. Moreover, adjust the output format to display dsq_vtime, slice, and weight on the same line. This can help identify whether certain tasks were excessively prioritized or de-prioritized due to large niceness gaps. Signed-off-by: Andrea Righi <arighi@nvidia.com> Signed-off-by: Tejun Heo <tj@kernel.org>
1 parent be8ee18 commit 2279563

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

kernel/sched/ext.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5277,9 +5277,10 @@ static void scx_dump_task(struct seq_buf *s, struct scx_dump_ctx *dctx,
52775277
scx_get_task_state(p), p->scx.flags & ~SCX_TASK_STATE_MASK,
52785278
p->scx.dsq_flags, ops_state & SCX_OPSS_STATE_MASK,
52795279
ops_state >> SCX_OPSS_QSEQ_SHIFT);
5280-
dump_line(s, " sticky/holding_cpu=%d/%d dsq_id=%s dsq_vtime=%llu slice=%llu",
5281-
p->scx.sticky_cpu, p->scx.holding_cpu, dsq_id_buf,
5282-
p->scx.dsq_vtime, p->scx.slice);
5280+
dump_line(s, " sticky/holding_cpu=%d/%d dsq_id=%s",
5281+
p->scx.sticky_cpu, p->scx.holding_cpu, dsq_id_buf);
5282+
dump_line(s, " dsq_vtime=%llu slice=%llu weight=%u",
5283+
p->scx.dsq_vtime, p->scx.slice, p->scx.weight);
52835284
dump_line(s, " cpus=%*pb", cpumask_pr_args(p->cpus_ptr));
52845285

52855286
if (SCX_HAS_OP(dump_task)) {

0 commit comments

Comments
 (0)