Changeset View
Changeset View
Standalone View
Standalone View
sys/netinet/tcp_stacks/rack.c
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
Show First 20 Lines • Show All 17,323 Lines • ▼ Show 20 Lines | if ((IN_FASTRECOVERY(tp->t_flags) == 0) || rack->rack_no_prr) { | ||||
if ((rack->r_ctl.rc_tlp_new_data + sb_offset) > tp->snd_wnd) { | if ((rack->r_ctl.rc_tlp_new_data + sb_offset) > tp->snd_wnd) { | ||||
if (tp->snd_wnd > sb_offset) | if (tp->snd_wnd > sb_offset) | ||||
len = tp->snd_wnd - sb_offset; | len = tp->snd_wnd - sb_offset; | ||||
else | else | ||||
len = 0; | len = 0; | ||||
} else { | } else { | ||||
len = rack->r_ctl.rc_tlp_new_data; | len = rack->r_ctl.rc_tlp_new_data; | ||||
} | } | ||||
rack->r_ctl.rc_tlp_new_data = 0; | |||||
} else { | } else { | ||||
len = rack_what_can_we_send(tp, rack, cwnd_to_use, avail, sb_offset); | len = rack_what_can_we_send(tp, rack, cwnd_to_use, avail, sb_offset); | ||||
} | } | ||||
if ((rack->r_ctl.crte == NULL) && IN_FASTRECOVERY(tp->t_flags) && (len > segsiz)) { | if ((rack->r_ctl.crte == NULL) && IN_FASTRECOVERY(tp->t_flags) && (len > segsiz)) { | ||||
/* | /* | ||||
* For prr=off, we need to send only 1 MSS | * For prr=off, we need to send only 1 MSS | ||||
* at a time. We do this because another sack could | * at a time. We do this because another sack could | ||||
* be arriving that causes us to send retransmits and | * be arriving that causes us to send retransmits and | ||||
▲ Show 20 Lines • Show All 1,626 Lines • ▼ Show 20 Lines | if (error == 0) { | ||||
} else { | } else { | ||||
if (cwnd_to_use > tp->snd_ssthresh) { | if (cwnd_to_use > tp->snd_ssthresh) { | ||||
/* Set we sent in CA */ | /* Set we sent in CA */ | ||||
rack->rc_gp_saw_ca = 1; | rack->rc_gp_saw_ca = 1; | ||||
} else { | } else { | ||||
/* Set we sent in SS */ | /* Set we sent in SS */ | ||||
rack->rc_gp_saw_ss = 1; | rack->rc_gp_saw_ss = 1; | ||||
} | } | ||||
} | |||||
if (doing_tlp && (rsm == NULL)) { | |||||
/* Make sure new data TLP cnt is clear */ | |||||
rack->r_ctl.rc_tlp_new_data = 0; | |||||
} | } | ||||
if (TCPS_HAVEESTABLISHED(tp->t_state) && | if (TCPS_HAVEESTABLISHED(tp->t_state) && | ||||
(tp->t_flags & TF_SACK_PERMIT) && | (tp->t_flags & TF_SACK_PERMIT) && | ||||
tp->rcv_numsacks > 0) | tp->rcv_numsacks > 0) | ||||
tcp_clean_dsack_blocks(tp); | tcp_clean_dsack_blocks(tp); | ||||
tot_len_this_send += len; | tot_len_this_send += len; | ||||
if (len == 0) | if (len == 0) | ||||
counter_u64_add(rack_out_size[TCP_MSS_ACCT_SNDACK], 1); | counter_u64_add(rack_out_size[TCP_MSS_ACCT_SNDACK], 1); | ||||
▲ Show 20 Lines • Show All 2,032 Lines • Show Last 20 Lines |