From: Marc Aurele La France <tsi-yfeSBMgouQgsA/PxXw9srA@public.gmane.org>
To: Eric Dumazet <eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Roland Dreier <roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>,
netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: RCU'ed dst_get_neighbour()
Date: Tue, 29 Nov 2011 15:32:35 -0700 (Mountain Standard Time) [thread overview]
Message-ID: <alpine.WNT.2.00.1111291527360.228@TSI> (raw)
In-Reply-To: <1322602283.2596.25.camel@edumazet-laptop>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 3486 bytes --]
On Tue, 29 Nov 2011, Eric Dumazet wrote:
> Le mardi 29 novembre 2011 à 22:17 +0100, Eric Dumazet a écrit :
>> Le mardi 29 novembre 2011 à 14:00 -0700, Marc Aurele La France a écrit :
>>> On Tue, 29 Nov 2011, Eric Dumazet wrote:
>>>> Oh well, I forgot one rcu_read_unlock(), I'll send a V2...
>>> This also doesn't address the other dst_get_neighbour() instances
>>> introduced by
>>> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=69cce1d1404968f78b177a0314f5822d5afdbbfb
>> Oh well, a complete audit is needed, and I have no choice but doing it.
> Here is the result of this audit, please double check and test it, I
> only compiled this.
> [PATCH V2] drivers/infiniband: fix lockdep splats
> commit f2c31e32b37 (net: fix NULL dereferences in check_peer_redir())
> forgot to take care of infiniband uses of dst neighbours.
> Many thanks to Marc Aurele who provided a nice bug report and feedback.
> Reported-by: Marc Aurele La France <tsi-yfeSBMgouQgsA/PxXw9srA@public.gmane.org>
> Signed-off-by: Eric Dumazet <eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> CC: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
> CC: Roland Dreier <roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
> ---
> drivers/infiniband/core/addr.c | 9 +++++--
> drivers/infiniband/hw/cxgb3/iwch_cm.c | 4 +++
> drivers/infiniband/hw/cxgb4/cm.c | 6 +++++
> drivers/infiniband/hw/nes/nes_cm.c | 6 +++--
> drivers/infiniband/ulp/ipoib/ipoib_main.c | 18 +++++++++------
> drivers/infiniband/ulp/ipoib/ipoib_multicast.c | 6 +++--
> 6 files changed, 35 insertions(+), 14 deletions(-)
This looks good to me, although I'm a little iffy on your use of
dst_get_neighbour_raw(), but that could be just me.
But your audit is incomplete, a grep of 3.1.3 for dst_get_neighbour() and
dst_get_neighbour_raw() reveals occurrences in ...
drivers/scsi/cxgbi/cxgb3i/cxgb3i.c
drivers/scsi/cxgbi/cxgb4i/cxgb4i.c
drivers/scsi/cxgbi/libcxgbi.c
drivers/s390/net/qeth_l3_main.c
drivers/net/cxgb3/cxgb3_offload.c
drivers/infiniband/hw/cxgb3/iwch_cm.c
drivers/infiniband/hw/nes/nes_cm.c
drivers/infiniband/hw/cxgb4/cm.c
drivers/infiniband/core/addr.c
drivers/infiniband/ulp/ipoib/ipoib_main.c
drivers/infiniband/ulp/ipoib/ipoib_multicast.c
include/net/dst.h
net/atm/clip.c
net/sched/sch_teql.c
net/core/neighbour.c
net/ipv4/ip_gre.c
net/ipv4/ip_output.c
net/ipv4/route.c
net/xfrm/xfrm_policy.c
net/bridge/br_netfilter.c
net/decnet/dn_neigh.c
net/decnet/dn_route.c
net/ipv6/sit.c
net/ipv6/addrconf.c
net/ipv6/route.c
net/ipv6/ndisc.c
net/ipv6/ip6_output.c
net/ipv6/ip6_fib.c
(I'd list them all here, but I'm having issues with my MUA when I do so.)
Marc.
+----------------------------------+----------------------------------+
| Marc Aurele La France | work: 1-780-492-9310 |
| Academic Information and | fax: 1-780-492-1729 |
| Communications Technologies | email: tsi-yfeSBMgouQgsA/PxXw9srA@public.gmane.org |
| 352 General Services Building +----------------------------------+
| University of Alberta | |
| Edmonton, Alberta | Standard disclaimers apply |
| T6G 2H1 | |
| CANADA | |
+----------------------------------+----------------------------------+
next prev parent reply other threads:[~2011-11-29 22:32 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <alpine.WNT.2.00.1111291027320.1036@TSI>
[not found] ` <1322589661.2596.2.camel@edumazet-laptop>
2011-11-29 20:43 ` RCU'ed dst_get_neighbour() Eric Dumazet
2011-11-29 20:47 ` Roland Dreier
[not found] ` <CAG4TOxNJfr3X1p358LBWdNQKdkw8KOSekcKpNu6K5_phPEiR4A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-11-29 20:53 ` Eric Dumazet
2011-11-29 20:56 ` Roland Dreier
2011-11-29 21:00 ` Marc Aurele La France
2011-11-29 21:17 ` Eric Dumazet
2011-11-29 21:31 ` Eric Dumazet
2011-11-29 21:35 ` Roland Dreier
[not found] ` <CAL1RGDUcYJKBSCthTL1AFgpRvzjoaEpHjGFhratKP-98ufRKnw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-11-30 1:17 ` Marc Aurele La France
2011-11-30 2:00 ` Roland Dreier
2011-11-30 5:15 ` Marc Aurele La France
2011-11-30 5:26 ` Eric Dumazet
2011-11-30 12:16 ` Marc Aurele La France
2011-11-29 22:32 ` Marc Aurele La France [this message]
2011-11-29 22:42 ` Eric Dumazet
2011-11-29 23:03 ` Marc Aurele La France
2011-11-29 23:11 ` Eric Dumazet
2011-11-29 23:24 ` [PATCH net-next] net: proper locking in skb_update_prio() Eric Dumazet
2011-11-30 11:41 ` Neil Horman
2011-11-29 23:24 ` RCU'ed dst_get_neighbour() David Miller
[not found] ` <20111129.182441.956675970003939556.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2011-11-29 23:25 ` Eric Dumazet
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=alpine.WNT.2.00.1111291527360.228@TSI \
--to=tsi-yfesbmgouqgsa/pxxw9sra@public.gmane.org \
--cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
--cc=eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
/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