a7e7a35f | 01-Feb-2021 |
David Hanisch <titanic@dh-werder.de> |
tcp_send: avoid ip fragmentation of last segment of a tcp stream
With a LSO (large segment offload) capable network device, tcp data is sent in segments larger than mss. This works well normally and
tcp_send: avoid ip fragmentation of last segment of a tcp stream
With a LSO (large segment offload) capable network device, tcp data is sent in segments larger than mss. This works well normally and the network card splits the large segments into smaller ip packages not exceeding the mss.
The last segment of a stream, when fin flag is already set, takes a different code path (tcp_xmit_mp()). LSO is not possible here and not supported. If the segment is large (> mss) in this case, it is ip fragmented. This is not wanted.
The fix is to ensure the last segment of a tcp stream is below mss even in case of LSO.
(cherry picked from commit 72434ca23766cfa425b040bac615a51f16341693)
show more ...
|
d3c3f6c7 | 24-Nov-2020 |
David Hanisch <titanic@dh-werder.de> |
ipf/fastroute: fix wrong IP-Header checksum, support LSO
The function ire_send_wire_v4() is called twice in the course of ipf/fastroute, via 'quick .. to <if>'.
Checksums are prepared during the fi
ipf/fastroute: fix wrong IP-Header checksum, support LSO
The function ire_send_wire_v4() is called twice in the course of ipf/fastroute, via 'quick .. to <if>'.
Checksums are prepared during the first call. They must not be changed in the second. None of the two case (IXAF_SET_ULP_CKSUM set or not) works with offloading: Either the partial tcp cksum is calculated twice and wrong in the end, or the ip-header is calculated in software and the hardware later calculates it to zero.
In case of not-offloading the csum is already calculated. Header value must not be changed, namely ipha_ident must not be set again.
The origial ixa is lost when a package takes the fr_fastroute() path. In case of LSO ixa_fragsize was set to IP_MAXPACKET now it's the normal mtu. Pkgsize check must be skippted, too.
refs #4279
(cherry picked from commit bc91030d4fe6e89411348707603356ab2077b1c7)
show more ...
|
727e1839 | 15-Feb-2019 |
Dan McDonald <danmcd@joyent.com> |
10409 ipf sometimes freezes RFC 1323 transfers Reviewed by: Jason King <jbk@joyent.com> Reviewed by: Andy Fiddaman <andy@omniosce.org> Reviewed by: Cody Peter Mello <melloc@writev.io> Reviewed by: Ge
10409 ipf sometimes freezes RFC 1323 transfers Reviewed by: Jason King <jbk@joyent.com> Reviewed by: Andy Fiddaman <andy@omniosce.org> Reviewed by: Cody Peter Mello <melloc@writev.io> Reviewed by: Gergő Doma <domag02@gmail.com> Approved by: Robert Mustacchi <rm@joyent.com>
(cherry picked from commit 7df2681d192fcee541a58a00719b32f8e72ca29a)
show more ...
|
77dabb95 | 15-Aug-2019 |
Dan McDonald <danmcd@joyent.com> |
11556 ip_attr.c functions need to not dereference conn_ixa directly after lock drop Reviewed by: Jason King <jbk@joyent.com> Reviewed by: Mike Gerdts <mgerdts@joyent.com> Reviewed by: Andy Fiddaman <
11556 ip_attr.c functions need to not dereference conn_ixa directly after lock drop Reviewed by: Jason King <jbk@joyent.com> Reviewed by: Mike Gerdts <mgerdts@joyent.com> Reviewed by: Andy Fiddaman <andy@omniosce.org> Approved by: Gordon Ross <gwr@nexenta.com>
(cherry picked from commit 51a1f7c40f010b3ea320fda32ec43145b29f5579)
show more ...
|
58d7f9e6 | 18-Mar-2015 |
Robert Mustacchi <rm@joyent.com> |
5734 IPFGENITER needs to know when to hit the brakes Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com> Reviewed by: Dan McDonald <danmcd@omniti.com> Reviewed by: Richard Lowe <richlowe@richlowe.n
5734 IPFGENITER needs to know when to hit the brakes Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com> Reviewed by: Dan McDonald <danmcd@omniti.com> Reviewed by: Richard Lowe <richlowe@richlowe.net> Approved by: Garrett D'Amore <garrett@damore.org>
show more ...
|