Skip to content

Commit

Permalink
[TCP]: Set default congestion control correctly for incoming connecti…
Browse files Browse the repository at this point in the history
…ons.

Patch from Joel Sing to fix the default congestion control algorithm
for incoming connections. If a new congestion control handler is added
(via module), it should become the default for new
connections. Instead, the incoming connections use reno. The cause is
incorrect initialisation causes the tcp_init_congestion_control()
function to return after the initial if test fails.

Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Acked-by: Ian McDonald <imcdnzl@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Stephen Hemminger authored and David S. Miller committed Sep 21, 2005
1 parent 78c6671 commit 7957aed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ipv4/tcp_minisocks.c
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ struct sock *tcp_create_openreq_child(struct sock *sk, struct request_sock *req,
newtp->frto_counter = 0;
newtp->frto_highmark = 0;

newicsk->icsk_ca_ops = &tcp_reno;
newicsk->icsk_ca_ops = &tcp_init_congestion_ops;

tcp_set_ca_state(newsk, TCP_CA_Open);
tcp_init_xmit_timers(newsk);
Expand Down

0 comments on commit 7957aed

Please sign in to comment.