Page MenuHomeFreeBSD

D29825.diff
No OneTemporary

D29825.diff

diff --git a/sys/netinet/tcp_sack.c b/sys/netinet/tcp_sack.c
--- a/sys/netinet/tcp_sack.c
+++ b/sys/netinet/tcp_sack.c
@@ -497,7 +497,7 @@
tcp_sackhole_insert(struct tcpcb *tp, tcp_seq start, tcp_seq end,
struct sackhole *after)
{
- struct sackhole *hole;
+ struct sackhole *hole, *tail;
/* Allocate a new SACK hole. */
hole = tcp_sackhole_alloc(tp, start, end);
@@ -508,7 +508,15 @@
if (after != NULL)
TAILQ_INSERT_AFTER(&tp->snd_holes, after, hole, scblink);
else
- TAILQ_INSERT_TAIL(&tp->snd_holes, hole, scblink);
+ /*
+ * With Rescue Retransmission, new holes may need to
+ * be inserted just before the tail.
+ */
+ if (((tail = TAILQ_LAST_FAST(&tp->snd_holes, sackhole,
+ scblink)) != NULL) && SEQ_LEQ(end, tail->start))
+ TAILQ_INSERT_BEFORE(tail, hole, scblink);
+ else
+ TAILQ_INSERT_TAIL(&tp->snd_holes, hole, scblink);
/* Update SACK hint. */
if (tp->sackhint.nexthole == NULL)

File Metadata

Mime Type
text/plain
Expires
Mon, Nov 18, 9:45 PM (21 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14705200
Default Alt Text
D29825.diff (936 B)

Event Timeline