mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-02-04 21:39:49 +00:00
Kieran Mansley - 14th July 2004
* Fixed whitespace indenting in parts of tcp_in.c * Changed adjustment of ssthresh in response to fast retransmit * Commented out iteration of unsent list when new ACK received as we no longer put all unacked data on unsent list when retransmitting
This commit is contained in:
parent
8d052ecf24
commit
c356f560e8
@ -709,9 +709,14 @@ tcp_receive(struct tcp_pcb *pcb)
|
||||
ntohl(pcb->unacked->tcphdr->seqno)));
|
||||
tcp_rexmit(pcb);
|
||||
/* Set ssthresh to max (FlightSize / 2, 2*SMSS) */
|
||||
pcb->ssthresh = LWIP_MAX((pcb->snd_max -
|
||||
/*pcb->ssthresh = LWIP_MAX((pcb->snd_max -
|
||||
pcb->lastack) / 2,
|
||||
2 * pcb->mss);
|
||||
2 * pcb->mss);*/
|
||||
/* Set ssthresh to half of the minimum of the currenct cwnd and the advertised window */
|
||||
if(pcb->cwnd > pcb->snd_wnd)
|
||||
pcb->ssthresh = pcb->snd_wnd / 2;
|
||||
else
|
||||
pcb->ssthresh = pcb->cwnd / 2;
|
||||
|
||||
pcb->cwnd = pcb->ssthresh + 3 * pcb->mss;
|
||||
pcb->flags |= TF_INFR;
|
||||
@ -808,6 +813,10 @@ tcp_receive(struct tcp_pcb *pcb)
|
||||
rationale is that lwIP puts all outstanding segments on the
|
||||
->unsent list after a retransmission, so these segments may
|
||||
in fact have been sent once. */
|
||||
/* KJM 13th July 2004
|
||||
I don't think is is necessary as we no longer move all unacked
|
||||
segments on the unsent queue when performing retransmit */
|
||||
/*
|
||||
while (pcb->unsent != NULL &&
|
||||
TCP_SEQ_LEQ(ntohl(pcb->unsent->tcphdr->seqno) + TCP_TCPLEN(pcb->unsent),
|
||||
ackno) &&
|
||||
@ -832,6 +841,7 @@ tcp_receive(struct tcp_pcb *pcb)
|
||||
pcb->snd_nxt = htonl(pcb->unsent->tcphdr->seqno);
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
/* End of ACK for new data processing. */
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user