|
@@ -484,11 +484,12 @@ void tcp_retransmit_timer(struct sock *sk)
|
|
|
goto out_reset_timer;
|
|
|
}
|
|
|
|
|
|
+ __NET_INC_STATS(sock_net(sk), LINUX_MIB_TCPTIMEOUTS);
|
|
|
if (tcp_write_timeout(sk))
|
|
|
goto out;
|
|
|
|
|
|
if (icsk->icsk_retransmits == 0) {
|
|
|
- int mib_idx;
|
|
|
+ int mib_idx = 0;
|
|
|
|
|
|
if (icsk->icsk_ca_state == TCP_CA_Recovery) {
|
|
|
if (tcp_is_sack(tp))
|
|
@@ -503,10 +504,9 @@ void tcp_retransmit_timer(struct sock *sk)
|
|
|
mib_idx = LINUX_MIB_TCPSACKFAILURES;
|
|
|
else
|
|
|
mib_idx = LINUX_MIB_TCPRENOFAILURES;
|
|
|
- } else {
|
|
|
- mib_idx = LINUX_MIB_TCPTIMEOUTS;
|
|
|
}
|
|
|
- __NET_INC_STATS(sock_net(sk), mib_idx);
|
|
|
+ if (mib_idx)
|
|
|
+ __NET_INC_STATS(sock_net(sk), mib_idx);
|
|
|
}
|
|
|
|
|
|
tcp_enter_loss(sk);
|