[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 11 Dec 2013 20:22:12 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: eric.dumazet@...il.com
Cc: sbohrer@...advisors.com, netdev@...r.kernel.org
Subject: Re: [PATCH] udp: ipv4: must add synchronization in
udp_sk_rx_dst_set()
From: Eric Dumazet <eric.dumazet@...il.com>
Date: Wed, 11 Dec 2013 14:46:51 -0800
> From: Eric Dumazet <edumazet@...gle.com>
>
> Unlike TCP, UDP input path does not hold the socket lock.
>
> Before messing with sk->sk_rx_dst, we must use a spinlock, otherwise
> multiple cpus could leak a refcount.
>
> This patch also takes care of renewing a stale dst entry.
> (When the sk->sk_rx_dst would not be used by IP early demux)
>
> Fixes: 421b3885bf6d ("udp: ipv4: Add udp early demux")
> Signed-off-by: Eric Dumazet <edumazet@...gle.com>
Applied.
Longterm, perhaps a candidate for using xchg() instead of this
spinlock?
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists