HomeFreeBSD

tcp: Correctly compute the retransmit length for all 64-bit platforms.

Description

tcp: Correctly compute the retransmit length for all 64-bit platforms.

When the TCP sequence number subtracted is greater than 232 minus
the window size, or 2
31 minus the window size, the use of unsigned
long as an intermediate variable, may result in an incorrect retransmit
length computation on all 64-bit platforms.

While at it create a helper macro to facilitate the computation of
the difference between two TCP sequence numbers.

Differential Revision: https://reviews.freebsd.org/D35388
Reviewed by: rscheff
MFC after: 3 days
Sponsored by: NVIDIA Networking

Details

Provenance
hselaskyAuthored on Jun 2 2022, 6:33 PM
Reviewer
rscheff
Differential Revision
D35388: tcp: Correctly compute the retransmit length for all 64-bit platforms.
Parents
rG1326017849ee: hwpmc: Add IDs for few more Intel Atom CPUs.
Branches
Unknown
Tags
Unknown