summaryrefslogtreecommitdiff
path: root/tools/include
diff options
context:
space:
mode:
authorMartin KaFai Lau <kafai@fb.com>2020-08-20 22:00:27 +0300
committerAlexei Starovoitov <ast@kernel.org>2020-08-25 00:35:00 +0300
commitca584ba070864c606f3a54faaafe774726d5b4a1 (patch)
treeb3288fe9d41eb22da482f526b897e561afab3bdc /tools/include
parent2b8ee4f05d4f6a6c427ad30dd6c1bb49eb2efd3b (diff)
downloadlinux-ca584ba070864c606f3a54faaafe774726d5b4a1.tar.xz
tcp: bpf: Add TCP_BPF_RTO_MIN for bpf_setsockopt
This patch adds bpf_setsockopt(TCP_BPF_RTO_MIN) to allow bpf prog to set the min rto of a connection. It could be used together with the earlier patch which has added bpf_setsockopt(TCP_BPF_DELACK_MAX). A later selftest patch will communicate the max delay ack in a bpf tcp header option and then the receiving side can use bpf_setsockopt(TCP_BPF_RTO_MIN) to set a shorter rto. Signed-off-by: Martin KaFai Lau <kafai@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Reviewed-by: Eric Dumazet <edumazet@google.com> Acked-by: John Fastabend <john.fastabend@gmail.com> Link: https://lore.kernel.org/bpf/20200820190027.2884170-1-kafai@fb.com
Diffstat (limited to 'tools/include')
-rw-r--r--tools/include/uapi/linux/bpf.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index 7b905cb0213e..1ae20058b574 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -4258,6 +4258,7 @@ enum {
TCP_BPF_IW = 1001, /* Set TCP initial congestion window */
TCP_BPF_SNDCWND_CLAMP = 1002, /* Set sndcwnd_clamp */
TCP_BPF_DELACK_MAX = 1003, /* Max delay ack in usecs */
+ TCP_BPF_RTO_MIN = 1004, /* Min delay ack in usecs */
};
struct bpf_perf_event_value {