From: Jielong Zhou Date: Mon, 7 Jan 2019 09:51:49 +0000 (+0800) Subject: l4p/tcp: fix dropping sequential packet X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=0852bebf375564057af778052506856409373242;p=tldk.git l4p/tcp: fix dropping sequential packet When grouping sequential rx packets, some packet may be dropped incorrectly because of total length of packets are larger than receive window size which is out of date. We do not drop the packet, but check it again with updated receive window size. Change-Id: I656864a5f029850da5148b07279a34f22081a342 Signed-off-by: Jielong Zhou --- diff --git a/lib/libtle_l4p/tcp_rxtx.c b/lib/libtle_l4p/tcp_rxtx.c index b12b974..3f4f324 100644 --- a/lib/libtle_l4p/tcp_rxtx.c +++ b/lib/libtle_l4p/tcp_rxtx.c @@ -1329,20 +1329,16 @@ rx_data_ack(struct tle_tcp_stream *s, struct dack_info *tack, ret = rx_check_seqack(&s->tcb, si[j].seq, si[j].ack, plen, ts); + if (ret != 0) + break; + /* account for segment received */ ack_info_update(tack, &si[j], ret != 0, plen, ts); - if (ret != 0) { - rp[k] = mb[j]; - rc[k] = -ret; - k++; - break; - } rte_pktmbuf_adj(mb[j], hlen); } n = j - i; - j += (ret != 0); /* account for OFO data */ if (seq != s->tcb.rcv.nxt)