HomeFreeBSD

Historically we have two fields in tcpcb to describe sender MSS: t_maxopd,

Description

Historically we have two fields in tcpcb to describe sender MSS: t_maxopd,
and t_maxseg. This dualism emerged with T/TCP, but was not properly cleaned
up after T/TCP removal. After all permutations over the years the result is
that t_maxopd stores a minimum of peer offered MSS and MTU reduced by minimum
protocol header. And t_maxseg stores (t_maxopd - TCPOLEN_TSTAMP_APPA) if
timestamps are in action, or is equal to t_maxopd otherwise. That's a very
rough estimate of MSS reduced by options length. Throughout the code it
was used in places, where preciseness was not important, like cwnd or
ssthresh calculations.

With this change:

  • t_maxopd goes away.
  • t_maxseg now stores MSS not adjusted by options.
  • new function tcp_maxseg() is provided, that calculates MSS reduced by options length. The functions gives a better estimate, since it takes into account SACK state as well.

Reviewed by: jtl
Differential Revision: https://reviews.freebsd.org/D3593

Details

Provenance
glebiusAuthored on
Reviewer
jtl
Differential Revision
D3593: Retire t_maxopd, leave t_maxseg.
Parents
rS293283: Update lldb to trunk r256945.
Branches
Unknown
Tags
Unknown