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] [day] [month] [year] [list]
Date:	Fri, 10 Sep 2010 09:05:25 -0700
From:	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
To:	Peter Zijlstra <peterz@...radead.org>
Cc:	Frederic Weisbecker <fweisbec@...il.com>, mingo@...hat.com,
	hpa@...or.com, paulus@...ba.org, linux-kernel@...r.kernel.org,
	eranian@...glemail.com, yanmin_zhang@...ux.intel.com,
	robert.richter@....com, ming.m.lin@...el.com, tglx@...utronix.de,
	mingo@...e.hu, linux-tip-commits@...r.kernel.org
Subject: Re: [tip:perf/core] perf: Per-pmu-per-cpu contexts

On Fri, Sep 10, 2010 at 05:46:34PM +0200, Peter Zijlstra wrote:
> On Fri, 2010-09-10 at 08:37 -0700, Paul E. McKenney wrote:
> > > So, you say below that it works because synchronize_srcu(), that
> > > waits for qs after touching pmus, implies synchronize_sched(), right?
> > 
> > Ook...  My current plans to fold SRCU into TREE_RCU would invalidate
> > this assumption.
> > 
> > Maybe we need some sort of primitive that concurrently waits for
> > multiple types of RCU grace periods? 
> 
> Nah, but I was thinking that any kind of preemptible rcu sync would
> imply a sched rcu sync.

Ah!

Although disabling interrupts will block preemptible RCU grace periods
in current implementations (but please don't rely on this!), disabling
preemption will -not- block preemptible RCU grace periods, even given
current TREE_PREEMPT_RCU and TINY_PREEMPT_RCU implementations.  Current
SRCU grace periods are blocked by disabling preemption, but folding it
into the tree/tiny implementations would make SRCU grace periods be no
longer blocked by disabling preemption.

This might change if RCU priority boosting is enabled, due to RCU
grace-period computation and callback invocation moving to a kthread,
but I won't have the guts to make TREE_RCU use kthread by default for
some time.  (Probably a year or so trouble-free experience with RCU
priority boosting/kthreads.)

> If not strictly implied I'd have no problem simply writing:
> 
>   synchronize_rcu_sched();
>   synchronize_srcu();

If that works for you, then we are set!  The only reason to introduce
a combined primitive would be if the latency of the above was too large.

							Thanx, Paul
--
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