aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/inet_diag.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/inet_diag.c')
-rw-r--r--net/ipv4/inet_diag.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/net/ipv4/inet_diag.c b/net/ipv4/inet_diag.c
index b04a6ee5a9a1..7eb83ebed2ec 100644
--- a/net/ipv4/inet_diag.c
+++ b/net/ipv4/inet_diag.c
@@ -839,15 +839,11 @@ static int inet_diag_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh)
839 839
840static DEFINE_MUTEX(inet_diag_mutex); 840static DEFINE_MUTEX(inet_diag_mutex);
841 841
842static void inet_diag_rcv(struct sock *sk, int len) 842static void inet_diag_rcv(struct sk_buff *skb)
843{ 843{
844 unsigned int qlen = 0; 844 mutex_lock(&inet_diag_mutex);
845 845 netlink_rcv_skb(skb, &inet_diag_rcv_msg);
846 do { 846 mutex_unlock(&inet_diag_mutex);
847 mutex_lock(&inet_diag_mutex);
848 qlen = netlink_run_queue(sk, qlen, &inet_diag_rcv_msg);
849 mutex_unlock(&inet_diag_mutex);
850 } while (qlen);
851} 847}
852 848
853static DEFINE_SPINLOCK(inet_diag_register_lock); 849static DEFINE_SPINLOCK(inet_diag_register_lock);