lkml.org 
[lkml]   [2022]   [Jul]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v6 2/2] sched/rt: Trying to push current task when target disable migrating
From
On 12/07/2022 17:05, Schspa Shi wrote:

[...]

> diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c
> index 7bd3e6ecbe45e..e2d7b085a93d9 100644
> --- a/kernel/sched/rt.c
> +++ b/kernel/sched/rt.c
> @@ -2136,6 +2136,12 @@ static int push_rt_task(struct rq *rq, bool pull)
> */
> task = pick_next_pushable_task(rq);
> if (task == next_task) {
> + /*
> + * If next task has now disabled migrating, see if we
> + * can push the current task.
> + */
> + if (unlikely(is_migration_disabled(task)))

Doesn't this need a `put_task_struct(next_task)`?

> + goto retry;
> /*
> * The task hasn't migrated, and is still the next
> * eligible task, but we failed to find a run-queue

Why not introduce in push_dl_task() as well?

\
 
 \ /
  Last update: 2022-07-13 12:03    [W:0.068 / U:2.224 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site