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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 24 Feb 2015 13:45:32 -0500
From:	Steven Rostedt <rostedt@...dmis.org>
To:	LKML <linux-kernel@...r.kernel.org>
Cc:	Ingo Molnar <mingo@...nel.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Clark Williams <williams@...hat.com>,
	linux-rt-users <linux-rt-users@...r.kernel.org>,
	Mike Galbraith <umgwanakikbuti@...il.com>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	Jörn Engel <joern@...estorage.com>
Subject: Re: [RFC][PATCH v2] sched/rt: Use IPI to trigger RT task push
 migration instead of pulling

On Tue, 24 Feb 2015 13:39:46 -0500
Steven Rostedt <rostedt@...dmis.org> wrote:
  
> +static void tell_cpu_to_push(int cpu, struct rq *rq, int prio)
> +{
> +	/* We should never be here if the IPI is already out. */
> +	BUG_ON(rq->rt.push_csd_pending);
> +
> +	rq->rt.push_csd_pending = 1;
> +	rq->rt.push_csd_cpu = cpu;
> +	/* Save the prio that we used to find this CPU */
> +	rq->rt.push_csd_prio = prio;
> +
> +	/* Make sure csd_cpu is visible before we send the ipi */
> +	smp_mb();
> +
> +	smp_call_function_single_async(cpu, &rq->rt.push_csd);
> +}



> +	rt_rq->push_csd_cpu = next_cpu;
> +	rt_rq->push_csd_prio = next_prio;
> +
> +	/* Make sure the next cpu is seen on remote CPU */
> +	smp_mb();

BTW, would a smp_wmb() be enough here. I was a little paranoid about
the irq work and smp_call_functon above some how leaking before the
barrier. I'm probably just being too paranoid, and these can be
switched to smp_wmb(). But for now I'll just keep being a freak.

-- Steve


> +
> +	irq_work_queue_on(&rt_rq->push_csd_work, next_cpu);
> +
> +	return;
> +

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ