From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Stephen Hemminger <shemminger@vyatta.com>,
Jiri Pirko <jpirko@redhat.com>,
netdev@vger.kernel.org, davem@davemloft.net, kaber@trash.net
Subject: Re: [PATCH net-next-2.6] net: replace hooks in __netif_receive_skb V5
Date: Wed, 2 Jun 2010 13:43:45 -0700 [thread overview]
Message-ID: <20100602204345.GE2385@linux.vnet.ibm.com> (raw)
In-Reply-To: <1275491722.2725.184.camel@edumazet-laptop>
On Wed, Jun 02, 2010 at 05:15:22PM +0200, Eric Dumazet wrote:
> Le mercredi 02 juin 2010 à 08:07 -0700, Stephen Hemminger a écrit :
> > On Wed, 2 Jun 2010 09:52:08 +0200
> > Jiri Pirko <jpirko@redhat.com> wrote:
> >
> > > +
> > > + err = netdev_rx_handler_register(dev, macvlan_handle_frame);
> > > + if (err) {
> > > + rcu_assign_pointer(dev->macvlan_port, NULL);
> > > + kfree(port);
> > > + }
> > > +
> > > + return err;
> > > }
> >
> > Rcu assign is not necessary here for because the hook didn't
> > get registered so there is no way for other CPU to see it.
> >
>
> Thats a valid point, but we should use it, and not care of this litle
> detail. Compiler generates same code anyway, since NULL value is tested
> by rcu_assign_pointer().
>
> If we dont use rcu_assign_pointer() ourself, Paul or Arnd will put it
> one day or another :)
>
> http://lkml.org/lkml/2010/6/1/290
Some year soon, I hope. ;-)
Thanx, Paul
next prev parent reply other threads:[~2010-06-02 20:43 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-27 18:08 [PATCH net-next-2.6] net: replace hooks in __netif_receive_skb V2 Jiri Pirko
2010-05-27 20:08 ` Stephen Hemminger
2010-05-28 5:51 ` Jiri Pirko
2010-05-28 6:12 ` [PATCH net-next-2.6] net: replace hooks in __netif_receive_skb V3 Jiri Pirko
2010-05-28 7:02 ` Eric Dumazet
2010-05-28 7:33 ` [PATCH net-next-2.6] net: replace hooks in __netif_receive_skb V4 Jiri Pirko
2010-06-01 15:28 ` net: replace hooks in __netif_receive_skb (v4) Stephen Hemminger
2010-06-01 15:41 ` Jiri Pirko
2010-06-01 16:10 ` Stephen Hemminger
2010-06-02 7:02 ` Jiri Pirko
2010-06-01 16:13 ` Fischer, Anna
2010-06-02 6:50 ` Jiri Pirko
2010-06-02 7:24 ` net: " Jiri Pirko
2010-06-02 7:52 ` [PATCH net-next-2.6] net: replace hooks in __netif_receive_skb V5 Jiri Pirko
2010-06-02 14:11 ` David Miller
2010-06-02 15:07 ` Stephen Hemminger
2010-06-02 15:15 ` Eric Dumazet
2010-06-02 20:43 ` Paul E. McKenney [this message]
2010-06-02 16:20 ` Fischer, Anna
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100602204345.GE2385@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=jpirko@redhat.com \
--cc=kaber@trash.net \
--cc=netdev@vger.kernel.org \
--cc=shemminger@vyatta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).