]> git.baikalelectronics.ru Git - kernel.git/commit
[TCP]: Move to new TSO segmenting scheme.
authorDavid S. Miller <davem@davemloft.net>
Tue, 5 Jul 2005 22:24:38 +0000 (15:24 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 5 Jul 2005 22:24:38 +0000 (15:24 -0700)
commitd6b88e4e23c7996300e916848dd1c102a0116a14
tree92082532651cddc6f0649a9d7ca9ca63e381d310
parent890b33fb46f16271d4a7a2d69c667090f95ae4b6
[TCP]: Move to new TSO segmenting scheme.

Make TSO segment transmit size decisions at send time not earlier.

The basic scheme is that we try to build as large a TSO frame as
possible when pulling in the user data, but the size of the TSO frame
output to the card is determined at transmit time.

This is guided by tp->xmit_size_goal.  It is always set to a multiple
of MSS and tells sendmsg/sendpage how large an SKB to try and build.

Later, tcp_write_xmit() and tcp_push_one() chop up the packet if
necessary and conditions warrant.  These routines can also decide to
"defer" in order to wait for more ACKs to arrive and thus allow larger
TSO frames to be emitted.

A general observation is that TSO elongates the pipe, thus requiring a
larger congestion window and larger buffering especially at the sender
side.  Therefore, it is important that applications 1) get a large
enough socket send buffer (this is accomplished by our dynamic send
buffer expansion code) 2) do large enough writes.

Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/tcp.h
include/net/tcp.h
net/ipv4/tcp.c
net/ipv4/tcp_input.c
net/ipv4/tcp_ipv4.c
net/ipv4/tcp_output.c
net/ipv6/tcp_ipv6.c