sched/core: Clear prev->dl_server in CFS pick fast path
commita741b82423upstream. 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 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
6cdec86523
commit
782d5a758d
@@ -5827,6 +5827,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.
|
||||
|
||||
Reference in New Issue
Block a user