Re: Warning in net/ipv4/af_inet.c:154

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: David Miller
Date: Wednesday, May 26, 2010 - 12:56 am

From: Anton Blanchard <anton@samba.org>
Date: Wed, 26 May 2010 13:19:43 +1000


We take the lock properly for all of the skb_queue_rcv_skb() cases
but this rule isn't followed properly for skb_queue_err_skb().

Eric, look at even things like skb_tstamp_tx().  Nothing locks the
socket in those cases, yet we dip down into sock_queue_err_skb() and
thus invoke skb_set_owner_r which goes into sk_mem_charge() and does
the non-atomic update on ->sk_forward_alloc.

I am sure there are other cases with this problem involving
sock_queue_err_skb()...  ip_icmp_error() (via __udp4_lib_err()),
ipv6_icmp_error(), etc.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Warning in net/ipv4/af_inet.c:154, Anton Blanchard, (Tue May 25, 4:58 am)
Re: Warning in net/ipv4/af_inet.c:154, Eric Dumazet, (Tue May 25, 8:27 am)
Re: Warning in net/ipv4/af_inet.c:154, Anton Blanchard, (Tue May 25, 8:19 pm)
Re: Warning in net/ipv4/af_inet.c:154, Eric Dumazet, (Tue May 25, 10:18 pm)
Re: Warning in net/ipv4/af_inet.c:154, David Miller, (Wed May 26, 12:56 am)
Re: Warning in net/ipv4/af_inet.c:154, Eric Dumazet, (Wed May 26, 3:12 am)
Re: Warning in net/ipv4/af_inet.c:154, Anton Blanchard, (Wed May 26, 8:56 pm)
Re: Warning in net/ipv4/af_inet.c:154, David Miller, (Wed May 26, 9:06 pm)
Re: Warning in net/ipv4/af_inet.c:154, Eric Dumazet, (Wed May 26, 9:18 pm)
Re: Warning in net/ipv4/af_inet.c:154, David Miller, (Wed May 26, 9:21 pm)
Re: Warning in net/ipv4/af_inet.c:154, Eric Dumazet, (Wed May 26, 9:21 pm)
[PATCH] net: fix lock_sock_bh/unlock_sock_bh, Eric Dumazet, (Wed May 26, 10:06 pm)
Re: [PATCH] net: fix lock_sock_bh/unlock_sock_bh, Eric Dumazet, (Wed May 26, 10:20 pm)
Re: [PATCH] net: fix lock_sock_bh/unlock_sock_bh, David Miller, (Wed May 26, 10:23 pm)
Re: [PATCH] net: fix lock_sock_bh/unlock_sock_bh, Anton Blanchard, (Wed May 26, 11:09 pm)
Re: [PATCH] net: fix lock_sock_bh/unlock_sock_bh, David Miller, (Thu May 27, 12:29 am)
Re: Warning in net/ipv4/af_inet.c:154, David Miller, (Sat May 29, 12:21 am)