diff options
author | Daniel Borkmann <daniel@iogearbox.net> | 2017-06-11 00:50:46 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-06-10 19:05:46 -0400 |
commit | 966789fb8636a35c3263076fea382263c5e56802 (patch) | |
tree | 67625e38b67da7ef4662d3d96bda323e55744ff4 /net | |
parent | f735b64926da36aadc0737d29dde587ac1e2e2c2 (diff) | |
download | linux-966789fb8636a35c3263076fea382263c5e56802.tar.gz linux-966789fb8636a35c3263076fea382263c5e56802.tar.bz2 linux-966789fb8636a35c3263076fea382263c5e56802.zip |
bpf: remove cg_skb_func_proto and use sk_filter_func_proto directly
Since cg_skb_func_proto() doesn't do anything else than just calling
into sk_filter_func_proto(), remove it and set sk_filter_func_proto()
directly for .get_func_proto callback.
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/core/filter.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/net/core/filter.c b/net/core/filter.c index 946f758d44f2..4867391126e4 100644 --- a/net/core/filter.c +++ b/net/core/filter.c @@ -2775,12 +2775,6 @@ xdp_func_proto(enum bpf_func_id func_id) } static const struct bpf_func_proto * -cg_skb_func_proto(enum bpf_func_id func_id) -{ - return sk_filter_func_proto(func_id); -} - -static const struct bpf_func_proto * lwt_inout_func_proto(enum bpf_func_id func_id) { switch (func_id) { @@ -3344,7 +3338,7 @@ const struct bpf_verifier_ops xdp_prog_ops = { }; const struct bpf_verifier_ops cg_skb_prog_ops = { - .get_func_proto = cg_skb_func_proto, + .get_func_proto = sk_filter_func_proto, .is_valid_access = sk_filter_is_valid_access, .convert_ctx_access = bpf_convert_ctx_access, .test_run = bpf_prog_test_run_skb, |