[PATCH] add an RCU version of list splicing
authorCorey Minyard <minyard@acm.org>
Sat, 10 Feb 2007 09:45:42 +0000 (01:45 -0800)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Sun, 11 Feb 2007 18:51:31 +0000 (10:51 -0800)
commit3678d62f028689abc8ac5693b254e48f605f94ba
tree7a897ae6d308411586c274e23f940b4d280b7ff1
parent16cf5b39b81b95d1e3d81df3ba8c82cadf54f551
[PATCH] add an RCU version of list splicing

This patch is in support of the IPMI driver.  I have tested this with the
IPMI driver changes coming in the next patch.

Add a list_splice_init_rcu() function to splice an RCU-protected list into
another list.  This takes the sync function as an argument, so one would do
something like:

INIT_LIST_HEAD(&list);
list_splice_init_rcu(&source, &dest, synchronize_rcu);

The idea being to keep the RCU API proliferation down to a dull roar.

[akpm@osdl.org: build fix]
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Signed-off-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/list.h