From: Eric Dumazet <eric.dumazet@gmail.com>
To: Stephen Hemminger <shemminger@vyatta.com>
Cc: Sean Hefty <sean.hefty@intel.com>,
"'Roland Dreier'" <rdreier@cisco.com>,
"David S. Miller" <davem@davemloft.net>,
Linux Netdev List <netdev@vger.kernel.org>,
Roland Dreier <rolandd@cisco.com>,
Hal Rosenstock <hal.rosenstock@gmail.com>,
linux-rdma <linux-rdma@vger.kernel.org>
Subject: Re: [PATCH] RDMA/addr: Use appropriate locking with for_each_netdev()
Date: Fri, 20 Nov 2009 06:43:46 +0100 [thread overview]
Message-ID: <4B062C92.4000001@gmail.com> (raw)
In-Reply-To: <20091119214047.1a966c79@nehalam>
Stephen Hemminger a écrit :
> On Fri, 20 Nov 2009 06:28:00 +0100
> Eric Dumazet <eric.dumazet@gmail.com> wrote:
>
>> + read_lock(&dev_base_lock);
>> for_each_netdev(&init_net, dev) {
>> if (ipv6_chk_addr(&init_net,
>> &((struct sockaddr_in6 *) addr)->sin6_addr,
>> @@ -139,6 +140,7 @@ int rdma_translate_ip(struct sockaddr *addr, struct rdma_dev_addr *dev_addr)
>> break;
>> }
>> }
>> + read_unlock(&dev_base_lock);
>
> what about for_each_netdev_rcu() here instead...
>
Yes, in 2.6.33 :)
For 2.6.32, we need this patch
Thanks
next prev parent reply other threads:[~2009-11-20 5:43 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-10 4:27 [PATCH] RDMA/addr: Use appropriate locking with for_each_netdev() Eric Dumazet
[not found] ` <4AF8EBA4.2070102-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-11-11 18:18 ` Sean Hefty
[not found] ` <D5E1FB213939498DBFFEB5A3B83C08AD-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2009-11-11 18:25 ` Roland Dreier
[not found] ` <adaocn8x6j7.fsf-BjVyx320WGW9gfZ95n9DRSW4+XlvGpQz@public.gmane.org>
2009-11-11 20:55 ` Sean Hefty
[not found] ` <8C10E584257A46DB9A0AD193520CF4A7-Zpru7NauK7drdx17CPfAsdBPR1lH4CV8@public.gmane.org>
2009-11-20 5:28 ` Eric Dumazet
[not found] ` <4B0628E0.6000404-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-11-20 5:40 ` Stephen Hemminger
2009-11-20 5:43 ` Eric Dumazet [this message]
2009-11-20 6:48 ` Roland Dreier
[not found] ` <adak4xl669z.fsf-BjVyx320WGW9gfZ95n9DRSW4+XlvGpQz@public.gmane.org>
2009-11-20 6:51 ` Eric Dumazet
2009-11-23 4:18 ` Roland Dreier
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=4B062C92.4000001@gmail.com \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=hal.rosenstock@gmail.com \
--cc=linux-rdma@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=rdreier@cisco.com \
--cc=rolandd@cisco.com \
--cc=sean.hefty@intel.com \
--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).