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  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, 12 Jan 2007 13:19:48 +0100
From:	Jarek Poplawski <jarkao2@...pl>
To:	Stephen Hemminger <shemminger@...l.org>
Cc:	David Miller <davem@...emloft.net>, greearb@...delatech.com,
	herbert@...dor.apana.org.au, dlstevens@...ibm.com,
	netdev@...r.kernel.org
Subject: Re: RCU info

On Thu, Jan 11, 2007 at 09:42:13AM -0800, Stephen Hemminger wrote:
> Paul McKenney has given lots of talks on RCU see:
> 	http://www.rdrop.com/users/paulmck/RCU/
> 
> and look in Documentation/RCU
 
I've read a lot of this but it's sometimes confusing e.g.:

>From Documentation/RCU/checklist.txt:

>9.      All RCU list-traversal primitives, which include
>        list_for_each_rcu(), list_for_each_entry_rcu(),
>        list_for_each_continue_rcu(), and list_for_each_safe_rcu(),
>        must be within an RCU read-side critical section.  RCU
>        read-side critical sections are delimited by rcu_read_lock()
>        and rcu_read_unlock(), or by similar primitives such as
>        rcu_read_lock_bh() and rcu_read_unlock_bh().

So "All" and "must be"!

>        Use of the _rcu() list-traversal primitives outside of an
>        RCU read-side critical section causes no harm other than
>        a slight performance degradation on Alpha CPUs.  It can
>        also be quite helpful in reducing code bloat when common
>        code is shared between readers and updaters.

... or not all and not must be?


I think, probably because of examples in those docs -  mostly with 
spin_locks (or without preemption), I've got wrong conviction that
writers (or more often readers and writers) in their reading part
aren't allowed to be preempted or block also. But after rethinking
yesterday explanation of David Miller I undestood the writers have
more possibilities and individual analyzis is required each time.

Many thanks once more to everyone,

Jarek P. 
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists