diff options
author | David S. Miller <davem@davemloft.net> | 2013-02-05 14:12:20 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-02-05 14:12:20 -0500 |
commit | 188d1f76d0dd3715ceeadfa31376867c3395eb41 (patch) | |
tree | b8976427ec21d3c346f2a993160b368c620c249a /net/ipv4 | |
parent | 577ae39ddb037242964f5fe87fd50b0b89e3263b (diff) | |
parent | bf414b369f158bb527f9f29174ada815f961b44c (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
drivers/net/ethernet/intel/e1000e/ethtool.c
drivers/net/vmxnet3/vmxnet3_drv.c
drivers/net/wireless/iwlwifi/dvm/tx.c
net/ipv6/route.c
The ipv6 route.c conflict is simple, just ignore the 'net' side change
as we fixed the same problem in 'net-next' by eliminating cached
neighbours from ipv6 routes.
The e1000e conflict is an addition of a new statistic in the ethtool
code, trivial.
The vmxnet3 conflict is about one change in 'net' removing a guarding
conditional, whilst in 'net-next' we had a netdev_info() conversion.
The iwlwifi conflict is dealing with a WARN_ON() conversion in
'net-next' vs. a revert happening in 'net'.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/tcp_cong.c | 14 | ||||
-rw-r--r-- | net/ipv4/tcp_input.c | 6 | ||||
-rw-r--r-- | net/ipv4/tcp_ipv4.c | 6 |
3 files changed, 18 insertions, 8 deletions
diff --git a/net/ipv4/tcp_cong.c b/net/ipv4/tcp_cong.c index 291f2ed7cc31..cdf2e707bb10 100644 --- a/net/ipv4/tcp_cong.c +++ b/net/ipv4/tcp_cong.c | |||
@@ -310,6 +310,12 @@ void tcp_slow_start(struct tcp_sock *tp) | |||
310 | { | 310 | { |
311 | int cnt; /* increase in packets */ | 311 | int cnt; /* increase in packets */ |
312 | unsigned int delta = 0; | 312 | unsigned int delta = 0; |
313 | u32 snd_cwnd = tp->snd_cwnd; | ||
314 | |||
315 | if (unlikely(!snd_cwnd)) { | ||
316 | pr_err_once("snd_cwnd is nul, please report this bug.\n"); | ||
317 | snd_cwnd = 1U; | ||
318 | } | ||
313 | 319 | ||
314 | /* RFC3465: ABC Slow start | 320 | /* RFC3465: ABC Slow start |
315 | * Increase only after a full MSS of bytes is acked | 321 | * Increase only after a full MSS of bytes is acked |
@@ -324,7 +330,7 @@ void tcp_slow_start(struct tcp_sock *tp) | |||
324 | if (sysctl_tcp_max_ssthresh > 0 && tp->snd_cwnd > sysctl_tcp_max_ssthresh) | 330 | if (sysctl_tcp_max_ssthresh > 0 && tp->snd_cwnd > sysctl_tcp_max_ssthresh) |
325 | cnt = sysctl_tcp_max_ssthresh >> 1; /* limited slow start */ | 331 | cnt = sysctl_tcp_max_ssthresh >> 1; /* limited slow start */ |
326 | else | 332 | else |
327 | cnt = tp->snd_cwnd; /* exponential increase */ | 333 | cnt = snd_cwnd; /* exponential increase */ |
328 | 334 | ||
329 | /* RFC3465: ABC | 335 | /* RFC3465: ABC |
330 | * We MAY increase by 2 if discovered delayed ack | 336 | * We MAY increase by 2 if discovered delayed ack |
@@ -334,11 +340,11 @@ void tcp_slow_start(struct tcp_sock *tp) | |||
334 | tp->bytes_acked = 0; | 340 | tp->bytes_acked = 0; |
335 | 341 | ||
336 | tp->snd_cwnd_cnt += cnt; | 342 | tp->snd_cwnd_cnt += cnt; |
337 | while (tp->snd_cwnd_cnt >= tp->snd_cwnd) { | 343 | while (tp->snd_cwnd_cnt >= snd_cwnd) { |
338 | tp->snd_cwnd_cnt -= tp->snd_cwnd; | 344 | tp->snd_cwnd_cnt -= snd_cwnd; |
339 | delta++; | 345 | delta++; |
340 | } | 346 | } |
341 | tp->snd_cwnd = min(tp->snd_cwnd + delta, tp->snd_cwnd_clamp); | 347 | tp->snd_cwnd = min(snd_cwnd + delta, tp->snd_cwnd_clamp); |
342 | } | 348 | } |
343 | EXPORT_SYMBOL_GPL(tcp_slow_start); | 349 | EXPORT_SYMBOL_GPL(tcp_slow_start); |
344 | 350 | ||
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 492c7cfe1453..e376aa9591bc 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -3482,7 +3482,8 @@ static bool tcp_process_frto(struct sock *sk, int flag) | |||
3482 | ((tp->frto_counter >= 2) && (flag & FLAG_RETRANS_DATA_ACKED))) | 3482 | ((tp->frto_counter >= 2) && (flag & FLAG_RETRANS_DATA_ACKED))) |
3483 | tp->undo_marker = 0; | 3483 | tp->undo_marker = 0; |
3484 | 3484 | ||
3485 | if (!before(tp->snd_una, tp->frto_highmark)) { | 3485 | if (!before(tp->snd_una, tp->frto_highmark) || |
3486 | !tcp_packets_in_flight(tp)) { | ||
3486 | tcp_enter_frto_loss(sk, (tp->frto_counter == 1 ? 2 : 3), flag); | 3487 | tcp_enter_frto_loss(sk, (tp->frto_counter == 1 ? 2 : 3), flag); |
3487 | return true; | 3488 | return true; |
3488 | } | 3489 | } |
@@ -5647,8 +5648,7 @@ static bool tcp_rcv_fastopen_synack(struct sock *sk, struct sk_buff *synack, | |||
5647 | * the remote receives only the retransmitted (regular) SYNs: either | 5648 | * the remote receives only the retransmitted (regular) SYNs: either |
5648 | * the original SYN-data or the corresponding SYN-ACK is lost. | 5649 | * the original SYN-data or the corresponding SYN-ACK is lost. |
5649 | */ | 5650 | */ |
5650 | syn_drop = (cookie->len <= 0 && data && | 5651 | syn_drop = (cookie->len <= 0 && data && tp->total_retrans); |
5651 | inet_csk(sk)->icsk_retransmits); | ||
5652 | 5652 | ||
5653 | tcp_fastopen_cache_set(sk, mss, cookie, syn_drop); | 5653 | tcp_fastopen_cache_set(sk, mss, cookie, syn_drop); |
5654 | 5654 | ||
diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index 5a1cfc692df0..0eaf685bddc9 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c | |||
@@ -496,6 +496,7 @@ void tcp_v4_err(struct sk_buff *icmp_skb, u32 info) | |||
496 | * errors returned from accept(). | 496 | * errors returned from accept(). |
497 | */ | 497 | */ |
498 | inet_csk_reqsk_queue_drop(sk, req, prev); | 498 | inet_csk_reqsk_queue_drop(sk, req, prev); |
499 | NET_INC_STATS_BH(sock_net(sk), LINUX_MIB_LISTENDROPS); | ||
499 | goto out; | 500 | goto out; |
500 | 501 | ||
501 | case TCP_SYN_SENT: | 502 | case TCP_SYN_SENT: |
@@ -1501,8 +1502,10 @@ int tcp_v4_conn_request(struct sock *sk, struct sk_buff *skb) | |||
1501 | * clogging syn queue with openreqs with exponentially increasing | 1502 | * clogging syn queue with openreqs with exponentially increasing |
1502 | * timeout. | 1503 | * timeout. |
1503 | */ | 1504 | */ |
1504 | if (sk_acceptq_is_full(sk) && inet_csk_reqsk_queue_young(sk) > 1) | 1505 | if (sk_acceptq_is_full(sk) && inet_csk_reqsk_queue_young(sk) > 1) { |
1506 | NET_INC_STATS_BH(sock_net(sk), LINUX_MIB_LISTENOVERFLOWS); | ||
1505 | goto drop; | 1507 | goto drop; |
1508 | } | ||
1506 | 1509 | ||
1507 | req = inet_reqsk_alloc(&tcp_request_sock_ops); | 1510 | req = inet_reqsk_alloc(&tcp_request_sock_ops); |
1508 | if (!req) | 1511 | if (!req) |
@@ -1667,6 +1670,7 @@ drop_and_release: | |||
1667 | drop_and_free: | 1670 | drop_and_free: |
1668 | reqsk_free(req); | 1671 | reqsk_free(req); |
1669 | drop: | 1672 | drop: |
1673 | NET_INC_STATS_BH(sock_net(sk), LINUX_MIB_LISTENDROPS); | ||
1670 | return 0; | 1674 | return 0; |
1671 | } | 1675 | } |
1672 | EXPORT_SYMBOL(tcp_v4_conn_request); | 1676 | EXPORT_SYMBOL(tcp_v4_conn_request); |