tcp: remove tp->lost_out guard to make joining diff nicer

The validity of the retransmit_high must then be ensured
if no L'ed skb exits!

This makes a minor change to behavior, we now have to
iterate the head to find out that the loop terminates.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Ilpo Järvinen 2008-09-20 21:23:49 -07:00 committed by David S. Miller
parent 61eb55f4db
commit 08ebd1721a
1 changed files with 37 additions and 36 deletions

View File

@ -2034,13 +2034,15 @@ void tcp_xmit_retransmit_queue(struct sock *sk)
struct sk_buff *skb; struct sk_buff *skb;
int mib_idx; int mib_idx;
if (!tp->lost_out)
tp->retransmit_high = tp->snd_una;
if (tp->retransmit_skb_hint) if (tp->retransmit_skb_hint)
skb = tp->retransmit_skb_hint; skb = tp->retransmit_skb_hint;
else else
skb = tcp_write_queue_head(sk); skb = tcp_write_queue_head(sk);
/* First pass: retransmit lost packets. */ /* First pass: retransmit lost packets. */
if (tp->lost_out) {
tcp_for_write_queue_from(skb, sk) { tcp_for_write_queue_from(skb, sk) {
__u8 sacked = TCP_SKB_CB(skb)->sacked; __u8 sacked = TCP_SKB_CB(skb)->sacked;
@ -2081,7 +2083,6 @@ void tcp_xmit_retransmit_queue(struct sock *sk)
inet_csk(sk)->icsk_rto, inet_csk(sk)->icsk_rto,
TCP_RTO_MAX); TCP_RTO_MAX);
} }
}
/* OK, demanded retransmission is finished. */ /* OK, demanded retransmission is finished. */
if (!tcp_can_forward_retransmit(sk)) if (!tcp_can_forward_retransmit(sk))