[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20150630010811.GB22559@redhat.com>
Date: Tue, 30 Jun 2015 03:08:11 +0200
From: Oleg Nesterov <oleg@...hat.com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: paulmck@...ux.vnet.ibm.com, tj@...nel.org, mingo@...hat.com,
der.herr@...r.at, dave@...olabs.net, riel@...hat.com,
viro@...IV.linux.org.uk, torvalds@...ux-foundation.org,
linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH 0/6] stop_machine: kill stop_cpus_mutex and
stop_cpus_lock
On 06/29, Peter Zijlstra wrote:
>
> On Mon, Jun 29, 2015 at 06:02:51AM +0200, Oleg Nesterov wrote:
>
> > If we change stop_two_cpus() to use stop_work_alloc_one() it can use
> > cpu_online(),
>
> So the one user of this actually needs cpu_active(); we do not want to
> go move tasks to an inactive cpu.
>
> So if you change this to cpu_online() we need to audit the user is doing
> the stricter test.
Hmm. But the user (migrate_swap_stop) should check cpu_active() anyway?
The cpu_active() checks in stop_two_cpus() can only help to ensure that
multi_cpu_stop() won't hang. CPU_DOWN_PREPARE can deactivate either CPU
right after the check?
Or stop_two_cpus() needs get_online_cpus(). Or I missed something.
Oleg.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists