From: Peter Zijlstra Date: Mon, 1 Sep 2025 20:46:29 +0000 (+0200) Subject: sched/hrtick: Fix hrtick() vs. scheduling context X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e38e5299747b23015b00b0109891815db44a2f30;p=thirdparty%2Fkernel%2Fstable.git sched/hrtick: Fix hrtick() vs. scheduling context The sched_class::task_tick() method is called on the donor sched_class, and sched_tick() hands it rq->donor as argument, which is consistent. However, while hrtick() uses the donor sched_class, it then passes rq->curr, which is inconsistent. Fix it. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Ingo Molnar Acked-by: John Stultz Link: https://patch.msgid.link/20250918080205.442967033@infradead.org --- diff --git a/kernel/sched/core.c b/kernel/sched/core.c index fc358c1b6ca9..1711e9e50100 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -878,7 +878,7 @@ static enum hrtimer_restart hrtick(struct hrtimer *timer) rq_lock(rq, &rf); update_rq_clock(rq); - rq->donor->sched_class->task_tick(rq, rq->curr, 1); + rq->donor->sched_class->task_tick(rq, rq->donor, 1); rq_unlock(rq, &rf); return HRTIMER_NORESTART;