Martin KaFai Lau 82f45c6c4a bpf: tcp: Do not limit cb_flags when creating child sk from listen sk
The commit 0813a841566f ("bpf: tcp: Allow bpf prog to write and parse TCP header option")
unnecessarily introduced bpf_skops_init_child() which limited the child
sk from inheriting all bpf_sock_ops_cb_flags of the listen sk.  That
breaks existing user expectation.

This patch removes the bpf_skops_init_child() and just allows
sock_copy() to do its job to copy everything from listen sk to
the child sk.

Fixes: 0813a841566f ("bpf: tcp: Allow bpf prog to write and parse TCP header option")
Reported-by: Stanislav Fomichev <sdf@google.com>
Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20201002013448.2542025-1-kafai@fb.com
2020-10-02 11:34:48 -07:00
..
2020-03-12 15:55:00 -07:00
2020-03-12 15:55:00 -07:00
2020-08-24 17:31:20 -07:00
2020-08-31 12:33:34 -07:00
2020-03-30 13:45:04 -07:00
2020-08-31 12:33:34 -07:00
2020-03-16 18:26:54 -07:00
2020-09-25 17:17:14 -07:00
2020-09-30 14:21:30 -07:00
2020-03-16 18:26:55 -07:00
2020-09-30 14:21:30 -07:00
2020-08-24 17:31:20 -07:00