diff options
| author | Yuchung Cheng <[email protected]> | 2018-11-29 00:06:44 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2018-12-01 01:22:41 +0000 |
| commit | ec641b39457e17774313b66697a8a1dc070257bd (patch) | |
| tree | 62a5fc5cec4d106106a348f020e319734c252971 /net/ipv4/tcp_output.c | |
| parent | tcp: fix off-by-one bug on aborting window-probing socket (diff) | |
| download | kernel-ec641b39457e17774313b66697a8a1dc070257bd.tar.gz kernel-ec641b39457e17774313b66697a8a1dc070257bd.zip | |
tcp: fix SNMP under-estimation on failed retransmission
Previously the SNMP counter LINUX_MIB_TCPRETRANSFAIL is not counting
the TSO/GSO properly on failed retransmission. This patch fixes that.
Signed-off-by: Yuchung Cheng <[email protected]>
Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: Neal Cardwell <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/ipv4/tcp_output.c')
| -rw-r--r-- | net/ipv4/tcp_output.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index 3f510cad0b3e..68b5326f7321 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c @@ -2920,7 +2920,7 @@ int __tcp_retransmit_skb(struct sock *sk, struct sk_buff *skb, int segs) TCP_SKB_CB(skb)->sacked |= TCPCB_EVER_RETRANS; trace_tcp_retransmit_skb(sk, skb); } else if (err != -EBUSY) { - NET_INC_STATS(sock_net(sk), LINUX_MIB_TCPRETRANSFAIL); + NET_ADD_STATS(sock_net(sk), LINUX_MIB_TCPRETRANSFAIL, segs); } return err; } |
