mirror of
https://github.com/torvalds/linux.git
synced 2024-11-10 06:01:57 +00:00
sched/core: Clear prev->dl_server in CFS pick fast path
In case the previous pick was a DL server pick, ->dl_server might be
set. Clear it in the fast path as well.
Fixes: 63ba8422f8
("sched/deadline: Introduce deadline servers")
Signed-off-by: Youssef Esmat <youssefesmat@google.com>
Signed-off-by: Daniel Bristot de Oliveira <bristot@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Juri Lelli <juri.lelli@redhat.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/7f7381ccba09efcb4a1c1ff808ed58385eccc222.1716811044.git.bristot@kernel.org
This commit is contained in:
parent
c245910049
commit
a741b82423
@ -5839,6 +5839,13 @@ __pick_next_task(struct rq *rq, struct task_struct *prev, struct rq_flags *rf)
|
||||
p = pick_next_task_idle(rq);
|
||||
}
|
||||
|
||||
/*
|
||||
* This is a normal CFS pick, but the previous could be a DL pick.
|
||||
* Clear it as previous is no longer picked.
|
||||
*/
|
||||
if (prev->dl_server)
|
||||
prev->dl_server = NULL;
|
||||
|
||||
/*
|
||||
* This is the fast path; it cannot be a DL server pick;
|
||||
* therefore even if @p == @prev, ->dl_server must be NULL.
|
||||
|
Loading…
Reference in New Issue
Block a user