X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=net%2Funix%2Faf_unix.c;h=3453e0053f76524841dce78153b2cd9338288fc2;hb=dd29c67dbbbf97c8aa786a502977856d8eb9a73d;hp=2206e6f8902d78a97cba87d52e7696f43b35bec6;hpb=c59f02f848672f92bcea90306240822239d68049;p=platform%2Fkernel%2Flinux-starfive.git diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index 2206e6f..3453e00 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -302,7 +302,7 @@ static void __unix_remove_socket(struct sock *sk) static void __unix_insert_socket(struct sock *sk) { - WARN_ON(!sk_unhashed(sk)); + DEBUG_NET_WARN_ON_ONCE(!sk_unhashed(sk)); sk_add_node(sk, &unix_socket_table[sk->sk_hash]); } @@ -554,9 +554,9 @@ static void unix_sock_destructor(struct sock *sk) u->oob_skb = NULL; } #endif - WARN_ON(refcount_read(&sk->sk_wmem_alloc)); - WARN_ON(!sk_unhashed(sk)); - WARN_ON(sk->sk_socket); + DEBUG_NET_WARN_ON_ONCE(refcount_read(&sk->sk_wmem_alloc)); + DEBUG_NET_WARN_ON_ONCE(!sk_unhashed(sk)); + DEBUG_NET_WARN_ON_ONCE(sk->sk_socket); if (!sock_flag(sk, SOCK_DEAD)) { pr_info("Attempt to release alive unix socket: %p\n", sk); return;