From: Lawrence Brakmo Date: Sun, 2 Jul 2017 16:14:28 +0000 (-0700) Subject: bpf: fix to bpf_setsockops X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a5192c52377e6d283abb5dcd5d25d65bf2316f62;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git bpf: fix to bpf_setsockops Fixed build error due to misplaced "#ifdef CONFIG_INET" (moved 1 statement up). Signed-off-by: Lawrence Brakmo Signed-off-by: David S. Miller --- diff --git a/net/core/filter.c b/net/core/filter.c index 523b91d25025..e5c280aa5de6 100644 --- a/net/core/filter.c +++ b/net/core/filter.c @@ -2717,9 +2717,9 @@ BPF_CALL_5(bpf_setsockopt, struct bpf_sock_ops_kern *, bpf_sock, default: ret = -EINVAL; } +#ifdef CONFIG_INET } else if (level == SOL_TCP && sk->sk_prot->setsockopt == tcp_setsockopt) { -#ifdef CONFIG_INET if (optname == TCP_CONGESTION) { char name[TCP_CA_NAME_MAX]; @@ -2757,7 +2757,6 @@ BPF_CALL_5(bpf_setsockopt, struct bpf_sock_ops_kern *, bpf_sock, ret = -EINVAL; } } -#else ret = -EINVAL; #endif } else {