lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190730092240.42383953@gandalf.local.home>
Date:   Tue, 30 Jul 2019 09:22:40 -0400
From:   Steven Rostedt <rostedt@...dmis.org>
To:     Peter Zijlstra <peterz@...radead.org>
Cc:     mingo@...nel.org, juri.lelli@...hat.com,
        linux-kernel@...r.kernel.org, dietmar.eggemann@....com,
        luca.abeni@...tannapisa.it, bristot@...hat.com,
        balsini@...roid.com, dvyukov@...gle.com, tglx@...utronix.de,
        vpillai@...italocean.com,
        Valentin Schneider <valentin.schneider@....com>,
        Aaron Lu <aaron.lwe@...il.com>, keescook@...omium.org,
        Pawan Gupta <pawan.kumar.gupta@...ux.intel.com>,
        Phil Auld <pauld@...hat.com>, torvalds@...ux-foundation.org,
        Tim Chen <tim.c.chen@...ux.intel.com>, fweisbec@...il.com,
        subhra.mazumdar@...cle.com,
        Julien Desfossez <jdesfossez@...italocean.com>, pjt@...gle.com,
        Nishanth Aravamudan <naravamudan@...italocean.com>,
        Aubrey Li <aubrey.intel@...il.com>,
        Mel Gorman <mgorman@...hsingularity.net>, kerrnel@...gle.com,
        Paolo Bonzini <pbonzini@...hat.com>
Subject: Re: [RFC][PATCH 02/13] stop_machine: Fix stop_cpus_in_progress
 ordering

On Fri, 26 Jul 2019 16:54:11 +0200
Peter Zijlstra <peterz@...radead.org> wrote:

> Make sure the entire for loop has stop_cpus_in_progress set.


>  kernel/stop_machine.c |    2 ++
>  1 file changed, 2 insertions(+)
> 
> --- a/kernel/stop_machine.c
> +++ b/kernel/stop_machine.c
> @@ -383,6 +383,7 @@ static bool queue_stop_cpus_work(const s
>  	 */
>  	preempt_disable();
>  	stop_cpus_in_progress = true;
> +	barrier();

Like smp_mb() shouldn't barrier() have a comment to what is being
ordered and why?

-- Steve

>  	for_each_cpu(cpu, cpumask) {
>  		work = &per_cpu(cpu_stopper.stop_work, cpu);
>  		work->fn = fn;
> @@ -391,6 +392,7 @@ static bool queue_stop_cpus_work(const s
>  		if (cpu_stop_queue_work(cpu, work))
>  			queued = true;
>  	}
> +	barrier();
>  	stop_cpus_in_progress = false;
>  	preempt_enable();
>  
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ