summaryrefslogtreecommitdiffstats
path: root/kernel/sched/idle.c
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2024-08-14 00:25:56 +0200
committerPeter Zijlstra <peterz@infradead.org>2024-09-03 15:26:32 +0200
commitb2d70222dbf2a2ff7a972a685d249a5d75afa87f (patch)
tree44cd70aefffd4238abb82da3cbe6ff79c39e12e3 /kernel/sched/idle.c
parentsched: Rework dl_server (diff)
downloadlinux-b2d70222dbf2a2ff7a972a685d249a5d75afa87f.tar.xz
linux-b2d70222dbf2a2ff7a972a685d249a5d75afa87f.zip
sched: Add put_prev_task(.next)
In order to tell the previous sched_class what the next task is, add put_prev_task(.next). Notable SCX will use this to: 1) determine the next task will leave the SCX sched class and push the current task to another CPU if possible. 2) statistics on how often and which other classes preempt it Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lore.kernel.org/r/20240813224016.367421076@infradead.org
Diffstat (limited to 'kernel/sched/idle.c')
-rw-r--r--kernel/sched/idle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched/idle.c b/kernel/sched/idle.c
index a343e1c97f56..7a105a0123aa 100644
--- a/kernel/sched/idle.c
+++ b/kernel/sched/idle.c
@@ -450,7 +450,7 @@ static void wakeup_preempt_idle(struct rq *rq, struct task_struct *p, int flags)
resched_curr(rq);
}
-static void put_prev_task_idle(struct rq *rq, struct task_struct *prev)
+static void put_prev_task_idle(struct rq *rq, struct task_struct *prev, struct task_struct *next)
{
dl_server_update_idle_time(rq, prev);
}