Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

sched_ext: Fix some comments in ext.c

This commit update balance_scx() in the comments to balance_one().

Signed-off-by: Zqiang <qiang.zhang@linux.dev>
Reviewed-by: Andrea Righi <arighi@nvidia.com>
Signed-off-by: Tejun Heo <tj@kernel.org>

authored by

Zqiang and committed by
Tejun Heo
12494e5e b0101ccb

+5 -5
+5 -5
kernel/sched/ext.c
··· 1577 1577 * 1578 1578 * @p may go through multiple stopping <-> running transitions between 1579 1579 * here and put_prev_task_scx() if task attribute changes occur while 1580 - * balance_scx() leaves @rq unlocked. However, they don't contain any 1580 + * balance_one() leaves @rq unlocked. However, they don't contain any 1581 1581 * information meaningful to the BPF scheduler and can be suppressed by 1582 1582 * skipping the callbacks if the task is !QUEUED. 1583 1583 */ ··· 2372 2372 * preempted, and it regaining control of the CPU. 2373 2373 * 2374 2374 * ->cpu_release() complements ->cpu_acquire(), which is emitted the 2375 - * next time that balance_scx() is invoked. 2375 + * next time that balance_one() is invoked. 2376 2376 */ 2377 2377 if (!rq->scx.cpu_released) { 2378 2378 if (SCX_HAS_OP(sch, cpu_release)) { ··· 2478 2478 } 2479 2479 2480 2480 /* 2481 - * If balance_scx() is telling us to keep running @prev, replenish slice 2481 + * If balance_one() is telling us to keep running @prev, replenish slice 2482 2482 * if necessary and keep running @prev. Otherwise, pop the first one 2483 2483 * from the local DSQ. 2484 2484 */ ··· 4025 4025 * 4026 4026 * - ops.dispatch() is ignored. 4027 4027 * 4028 - * - balance_scx() does not set %SCX_RQ_BAL_KEEP on non-zero slice as slice 4028 + * - balance_one() does not set %SCX_RQ_BAL_KEEP on non-zero slice as slice 4029 4029 * can't be trusted. Whenever a tick triggers, the running task is rotated to 4030 4030 * the tail of the queue with core_sched_at touched. 4031 4031 * ··· 6069 6069 /* 6070 6070 * A successfully consumed task can be dequeued before it starts 6071 6071 * running while the CPU is trying to migrate other dispatched 6072 - * tasks. Bump nr_tasks to tell balance_scx() to retry on empty 6072 + * tasks. Bump nr_tasks to tell balance_one() to retry on empty 6073 6073 * local DSQ. 6074 6074 */ 6075 6075 dspc->nr_tasks++;