[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110802103216.GB2352@linux.vnet.ibm.com>
Date: Tue, 2 Aug 2011 03:32:16 -0700
From: "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
To: David Miller <davem@...emloft.net>
Cc: shemminger@...tta.com, eric.dumazet@...il.com, mchan@...adcom.com,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] rcu: convert uses of rcu_assign_pointer(x, NULL) to
RCU_INIT_POINTER
On Mon, Aug 01, 2011 at 10:44:01PM -0700, David Miller wrote:
> From: Stephen Hemminger <shemminger@...tta.com>
> Date: Mon, 1 Aug 2011 09:19:00 -0700
>
> > When assigning a NULL value to an RCU protected pointer, no barrier
> > is needed. The rcu_assign_pointer, used to handle that but will soon
> > change to not handle the special case.
> >
> > Convert all rcu_assign_pointer of NULL value.
> >
> > //smpl
> > @@ expression P; @@
> >
> > - rcu_assign_pointer(P, NULL)
> > + RCU_INIT_POINTER(P, NULL)
> >
> > // </smpl>
> >
> >
> > Signed-off-by: Stephen Hemminger <shemminger@...tta.com>
>
> Acked-by: David S. Miller <davem@...emloft.net>
Very good, thank you!
This patch does not depend on Eric's earlier patch because
RCU_INIT_POINTER() already exists. So although I would be happy to
carry this patch, there is no reason I can see not to run it up through
net-next. Either way, the Coccinelle script does look generally
useful. ;-)
If you would prefer me to carry it, please let me know. Otherwise:
Acked-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>
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