From: Wei Wang <[email protected]> Date: Wed, 4 Oct 2017 10:03:44 -0700
> From: Wei Wang <[email protected]> > > Currently in the TCP code, the initialization sequence for cached > metrics, congestion control, BPF, etc, after successful connection > is very inconsistent. This introduces inconsistent bevhavior and is > prone to bugs. The current call sequence is as follows: ... > This commit uniforms the above functions to have the following sequence: > tcp_mtup_init(sk); > icsk->icsk_af_ops->rebuild_header(sk); > tcp_init_metrics(sk); > tcp_call_bpf(sk, BPF_SOCK_OPS_ACTIVE/PASSIVE_ESTABLISHED_CB); > tcp_init_congestion_control(sk); > tcp_init_buffer_space(sk); > This sequence is the same as the (1) active case. We pick this sequence > because this order correctly allows BPF to override the settings > including congestion control module and initial cwnd, etc from > the route, and then allows the CC module to see those settings. > > Suggested-by: Neal Cardwell <[email protected]> > Tested-by: Neal Cardwell <[email protected]> > Signed-off-by: Wei Wang <[email protected]> > Acked-by: Neal Cardwell <[email protected]> > Acked-by: Yuchung Cheng <[email protected]> > Acked-by: Eric Dumazet <[email protected]> Nice change, applied, thanks.
