Lines Matching refs:icsk
117 static void tcp_mtu_probing(struct inet_connection_sock *icsk, struct sock *sk) in tcp_mtu_probing() argument
123 if (!icsk->icsk_mtup.enabled) { in tcp_mtu_probing()
124 icsk->icsk_mtup.enabled = 1; in tcp_mtu_probing()
125 icsk->icsk_mtup.probe_timestamp = tcp_time_stamp; in tcp_mtu_probing()
126 tcp_sync_mss(sk, icsk->icsk_pmtu_cookie); in tcp_mtu_probing()
132 mss = tcp_mtu_to_mss(sk, icsk->icsk_mtup.search_low) >> 1; in tcp_mtu_probing()
136 icsk->icsk_mtup.search_low = tcp_mss_to_mtu(sk, mss); in tcp_mtu_probing()
137 tcp_sync_mss(sk, icsk->icsk_pmtu_cookie); in tcp_mtu_probing()
177 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_write_timeout() local
183 if (icsk->icsk_retransmits) { in tcp_write_timeout()
187 if (tp->syn_data && icsk->icsk_retransmits == 1) in tcp_write_timeout()
191 retry_until = icsk->icsk_syn_retries ? : sysctl_tcp_syn_retries; in tcp_write_timeout()
203 if (icsk->icsk_retransmits == sysctl_tcp_retries1) in tcp_write_timeout()
208 tcp_mtu_probing(icsk, sk); in tcp_write_timeout()
215 const bool alive = icsk->icsk_rto < TCP_RTO_MAX; in tcp_write_timeout()
227 syn_set ? 0 : icsk->icsk_user_timeout, syn_set)) { in tcp_write_timeout()
238 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_delack_timer_handler() local
243 !(icsk->icsk_ack.pending & ICSK_ACK_TIMER)) in tcp_delack_timer_handler()
246 if (time_after(icsk->icsk_ack.timeout, jiffies)) { in tcp_delack_timer_handler()
247 sk_reset_timer(sk, &icsk->icsk_delack_timer, icsk->icsk_ack.timeout); in tcp_delack_timer_handler()
250 icsk->icsk_ack.pending &= ~ICSK_ACK_TIMER; in tcp_delack_timer_handler()
264 if (!icsk->icsk_ack.pingpong) { in tcp_delack_timer_handler()
266 icsk->icsk_ack.ato = min(icsk->icsk_ack.ato << 1, icsk->icsk_rto); in tcp_delack_timer_handler()
271 icsk->icsk_ack.pingpong = 0; in tcp_delack_timer_handler()
272 icsk->icsk_ack.ato = TCP_ATO_MIN; in tcp_delack_timer_handler()
303 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_probe_timer() local
309 icsk->icsk_probes_out = 0; in tcp_probe_timer()
324 else if (icsk->icsk_user_timeout && in tcp_probe_timer()
325 (s32)(tcp_time_stamp - start_ts) > icsk->icsk_user_timeout) in tcp_probe_timer()
330 const bool alive = inet_csk_rto_backoff(icsk, TCP_RTO_MAX) < TCP_RTO_MAX; in tcp_probe_timer()
333 if (!alive && icsk->icsk_backoff >= max_probes) in tcp_probe_timer()
339 if (icsk->icsk_probes_out >= max_probes) { in tcp_probe_timer()
353 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_fastopen_synack_timer() local
354 int max_retries = icsk->icsk_syn_retries ? : in tcp_fastopen_synack_timer()
383 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_retransmit_timer() local
438 if (icsk->icsk_retransmits == 0) { in tcp_retransmit_timer()
441 if (icsk->icsk_ca_state == TCP_CA_Recovery) { in tcp_retransmit_timer()
446 } else if (icsk->icsk_ca_state == TCP_CA_Loss) { in tcp_retransmit_timer()
448 } else if ((icsk->icsk_ca_state == TCP_CA_Disorder) || in tcp_retransmit_timer()
466 if (!icsk->icsk_retransmits) in tcp_retransmit_timer()
467 icsk->icsk_retransmits = 1; in tcp_retransmit_timer()
469 min(icsk->icsk_rto, TCP_RESOURCE_PROBE_INTERVAL), in tcp_retransmit_timer()
489 icsk->icsk_backoff++; in tcp_retransmit_timer()
490 icsk->icsk_retransmits++; in tcp_retransmit_timer()
505 icsk->icsk_retransmits <= TCP_THIN_LINEAR_RETRIES) { in tcp_retransmit_timer()
506 icsk->icsk_backoff = 0; in tcp_retransmit_timer()
507 icsk->icsk_rto = min(__tcp_set_rto(tp), TCP_RTO_MAX); in tcp_retransmit_timer()
510 icsk->icsk_rto = min(icsk->icsk_rto << 1, TCP_RTO_MAX); in tcp_retransmit_timer()
512 inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS, icsk->icsk_rto, TCP_RTO_MAX); in tcp_retransmit_timer()
521 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_write_timer_handler() local
525 !icsk->icsk_pending) in tcp_write_timer_handler()
528 if (time_after(icsk->icsk_timeout, jiffies)) { in tcp_write_timer_handler()
529 sk_reset_timer(sk, &icsk->icsk_retransmit_timer, icsk->icsk_timeout); in tcp_write_timer_handler()
533 event = icsk->icsk_pending; in tcp_write_timer_handler()
543 icsk->icsk_pending = 0; in tcp_write_timer_handler()
547 icsk->icsk_pending = 0; in tcp_write_timer_handler()
595 struct inet_connection_sock *icsk = inet_csk(sk); in tcp_keepalive_timer() local
641 if ((icsk->icsk_user_timeout != 0 && in tcp_keepalive_timer()
642 elapsed >= icsk->icsk_user_timeout && in tcp_keepalive_timer()
643 icsk->icsk_probes_out > 0) || in tcp_keepalive_timer()
644 (icsk->icsk_user_timeout == 0 && in tcp_keepalive_timer()
645 icsk->icsk_probes_out >= keepalive_probes(tp))) { in tcp_keepalive_timer()
651 icsk->icsk_probes_out++; in tcp_keepalive_timer()