mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-21 01:03:42 +00:00
Fix tcp_lro_rx_ipv4() for drivers that do not set CSUM_IP_CHECKED.
Specifcially, in_cksum_hdr() returns 0 (not 0xffff) when the IPv4 checksum is correct. Without this fix, the tcp_lro code will reject good IPv4 traffic from drivers that do not implement IPv4 header harder csum offload. Sponsored by: Myricom Inc. MFC after: 7 days
This commit is contained in:
parent
07b9a28adb
commit
e5ca1ffab5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=247104
|
@ -333,7 +333,7 @@ tcp_lro_rx_ipv4(struct lro_ctrl *lc, struct mbuf *m, struct ip *ip4,
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
csum = in_cksum_hdr(ip4);
|
csum = in_cksum_hdr(ip4);
|
||||||
if (__predict_false((csum ^ 0xffff) != 0)) {
|
if (__predict_false((csum) != 0)) {
|
||||||
lc->lro_bad_csum++;
|
lc->lro_bad_csum++;
|
||||||
return (TCP_LRO_CANNOT);
|
return (TCP_LRO_CANNOT);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue