tcp rack: simplify computation of rsm start and end
While there, also fix the setting of the SYN related flag. Reviewed by: rrs MFC after: 1 week Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D35862
This commit is contained in:
parent
93b8510c36
commit
1abc27dd52
@ -12610,14 +12610,11 @@ rack_init(struct tcpcb *tp)
|
||||
rsm->r_rtr_bytes = 0;
|
||||
if (tp->t_flags & TF_SENTFIN)
|
||||
rsm->r_flags |= RACK_HAS_FIN;
|
||||
rsm->r_end = tp->snd_max;
|
||||
if (tp->snd_una == tp->iss) {
|
||||
/* The data space is one beyond snd_una */
|
||||
if ((tp->snd_una == tp->iss) &&
|
||||
!TCPS_HAVEESTABLISHED(tp->t_state))
|
||||
rsm->r_flags |= RACK_HAS_SYN;
|
||||
rsm->r_start = tp->iss;
|
||||
rsm->r_end = rsm->r_start + (tp->snd_max - tp->snd_una);
|
||||
} else
|
||||
rsm->r_start = tp->snd_una;
|
||||
rsm->r_start = tp->snd_una;
|
||||
rsm->r_end = tp->snd_max;
|
||||
rsm->r_dupack = 0;
|
||||
if (rack->rc_inp->inp_socket->so_snd.sb_mb != NULL) {
|
||||
rsm->m = sbsndmbuf(&rack->rc_inp->inp_socket->so_snd, 0, &rsm->soff);
|
||||
|
Loading…
Reference in New Issue
Block a user