Subject: [PATCH 1/5] tcp_diag: Don't report max ack backlog in wqueue

From: Pavel Emelyanov <[email-masked]>
Date: Wed, 28 Dec 2011 17:36:28 +0400

This is not correct and actually makes ss work differently on proc
vs netlink -- in the former case 0 is reported.

Signed-off-by: Pavel Emelyanov <[email-masked]>

---
 net/ipv4/tcp_diag.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/net/ipv4/tcp_diag.c b/net/ipv4/tcp_diag.c
index 8cd357a..3f2e2ef 100644
--- a/net/ipv4/tcp_diag.c
+++ b/net/ipv4/tcp_diag.c
@@ -25,7 +25,7 @@ static void tcp_diag_get_info(struct sock *sk, struct inet_diag_msg *r,
 
 	if (sk->sk_state == TCP_LISTEN) {
 		r->idiag_rqueue = sk->sk_ack_backlog;
-		r->idiag_wqueue = sk->sk_max_ack_backlog;
+		r->idiag_wqueue = 0;
 	} else {
 		r->idiag_rqueue = max_t(int, tp->rcv_nxt - tp->copied_seq, 0);
 		r->idiag_wqueue = tp->write_seq - tp->snd_una;
-- 
1.5.5.6