lkml.org 
[lkml]   [2019]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RT 1/8] sched: migrate_enable: Use sleeping_lock to indicate involuntary sleep
On Sat, 27 Jul 2019 00:56:31 -0500
Scott Wood <swood@redhat.com> wrote:

> Without this, rcu_note_context_switch() will complain if an RCU read
> lock is held when migrate_enable() calls stop_one_cpu().
>
> Signed-off-by: Scott Wood <swood@redhat.com>
>

> index d3c6542b306f..c3407707e367 100644
> --- a/kernel/sched/core.c
> +++ b/kernel/sched/core.c
> @@ -7405,7 +7405,9 @@ void migrate_enable(void)
> unpin_current_cpu();
> preempt_lazy_enable();
> preempt_enable();

This looks like it needs a comment to explain why this is.

-- Steve

> + sleeping_lock_inc();
> stop_one_cpu(task_cpu(p), migration_cpu_stop, &arg);
> + sleeping_lock_dec();
> return;
> }
> }

\
 
 \ /
  Last update: 2019-07-29 15:29    [W:0.192 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site