[PATCH 1/4] sched: Rename/clarify sched_class::task_tick(.queued) argument

From: Peter Zijlstra

Date: Fri Aug 28 2026 - 03:57:08 EST


For some reason the sched_class::task_tick() argument that indicates it being
an hrtick, is called @queued. I'm sure naming is hard and all, but lets fix
this.

Signed-off-by: Peter Zijlstra (Intel) <peterz@xxxxxxxxxxxxx>
---
kernel/sched/deadline.c | 4 ++--
kernel/sched/ext/ext.c | 2 +-
kernel/sched/fair.c | 12 ++++++------
kernel/sched/idle.c | 2 +-
kernel/sched/rt.c | 2 +-
kernel/sched/sched.h | 2 +-
6 files changed, 12 insertions(+), 12 deletions(-)

--- a/kernel/sched/deadline.c
+++ b/kernel/sched/deadline.c
@@ -2876,7 +2876,7 @@ static void put_prev_task_dl(struct rq *
* and everything must be accessed through the @rq and @curr passed in
* parameters.
*/
-static void task_tick_dl(struct rq *rq, struct task_struct *p, int queued)
+static void task_tick_dl(struct rq *rq, struct task_struct *p, int hrtick)
{
update_curr_dl(rq);

@@ -2886,7 +2886,7 @@ static void task_tick_dl(struct rq *rq,
* not being the leftmost task anymore. In that case NEED_RESCHED will
* be set and schedule() will start a new hrtick for the next task.
*/
- if (hrtick_enabled_dl(rq) && queued && p->dl.runtime > 0 &&
+ if (hrtick_enabled_dl(rq) && hrtick && p->dl.runtime > 0 &&
is_leftmost(&p->dl, &rq->dl))
start_hrtick_dl(rq, &p->dl);
}
--- a/kernel/sched/ext/ext.c
+++ b/kernel/sched/ext/ext.c
@@ -3787,7 +3787,7 @@ void scx_tick(struct rq *rq)
update_other_load_avgs(rq);
}

-static void task_tick_scx(struct rq *rq, struct task_struct *curr, int queued)
+static void task_tick_scx(struct rq *rq, struct task_struct *curr, int hrtick)
{
struct scx_sched *sch = scx_task_sched(curr);

--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -6542,7 +6542,7 @@ static void put_prev_entity(struct cfs_r
}

static void
-entity_tick(struct cfs_rq *cfs_rq, struct sched_entity *curr, int queued)
+entity_tick(struct cfs_rq *cfs_rq, struct sched_entity *curr, int hrtick)
{
/*
* Update run-time statistics of the 'current'.
@@ -6557,10 +6557,10 @@ entity_tick(struct cfs_rq *cfs_rq, struc

#ifdef CONFIG_SCHED_HRTICK
/*
- * queued ticks are scheduled to match the slice, so don't bother
+ * hrticks are scheduled to match the slice, so don't bother
* validating it and just reschedule.
*/
- if (queued) {
+ if (hrtick) {
resched_curr(rq_of(cfs_rq));
return;
}
@@ -15020,7 +15020,7 @@ static inline void task_tick_core(struct
* and everything must be accessed through the @rq and @curr passed in
* parameters.
*/
-static void task_tick_fair(struct rq *rq, struct task_struct *curr, int queued)
+static void task_tick_fair(struct rq *rq, struct task_struct *curr, int hrtick)
{
struct sched_entity *se = &curr->se;

@@ -15030,7 +15030,7 @@ static void task_tick_fair(struct rq *rq

for_each_sched_entity(se) {
cfs_rq = cfs_rq_of(se);
- entity_tick(cfs_rq, se, queued);
+ entity_tick(cfs_rq, se, hrtick);

weight = __calc_prop_weight(cfs_rq, se, weight);
}
@@ -15039,7 +15039,7 @@ static void task_tick_fair(struct rq *rq
reweight_eevdf(cfs_rq, se, weight, se->on_rq);
}

- if (queued)
+ if (hrtick)
return;

if (static_branch_unlikely(&sched_numa_balancing))
--- a/kernel/sched/idle.c
+++ b/kernel/sched/idle.c
@@ -535,7 +535,7 @@ dequeue_task_idle(struct rq *rq, struct
* and everything must be accessed through the @rq and @curr passed in
* parameters.
*/
-static void task_tick_idle(struct rq *rq, struct task_struct *curr, int queued)
+static void task_tick_idle(struct rq *rq, struct task_struct *curr, int hrtick)
{
update_curr_idle(rq);
}
--- a/kernel/sched/rt.c
+++ b/kernel/sched/rt.c
@@ -2538,7 +2538,7 @@ static inline void watchdog(struct rq *r
* and everything must be accessed through the @rq and @curr passed in
* parameters.
*/
-static void task_tick_rt(struct rq *rq, struct task_struct *p, int queued)
+static void task_tick_rt(struct rq *rq, struct task_struct *p, int hrtick)
{
struct sched_rt_entity *rt_se = &p->rt;

--- a/kernel/sched/sched.h
+++ b/kernel/sched/sched.h
@@ -2718,7 +2718,7 @@ struct sched_class {
* sched_tick: rq->lock
* sched_tick_remote: rq->lock
*/
- void (*task_tick)(struct rq *rq, struct task_struct *p, int queued);
+ void (*task_tick)(struct rq *rq, struct task_struct *p, int hrtick);
/*
* sched_cgroup_fork: p->pi_lock
*/