diff options
Diffstat (limited to 'kernel/bpf/syscall.c')
-rw-r--r-- | kernel/bpf/syscall.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c index 4c53cbd3329d..7713cf39795a 100644 --- a/kernel/bpf/syscall.c +++ b/kernel/bpf/syscall.c | |||
@@ -1,13 +1,5 @@ | |||
1 | // SPDX-License-Identifier: GPL-2.0-only | ||
1 | /* Copyright (c) 2011-2014 PLUMgrid, http://plumgrid.com | 2 | /* Copyright (c) 2011-2014 PLUMgrid, http://plumgrid.com |
2 | * | ||
3 | * This program is free software; you can redistribute it and/or | ||
4 | * modify it under the terms of version 2 of the GNU General Public | ||
5 | * License as published by the Free Software Foundation. | ||
6 | * | ||
7 | * This program is distributed in the hope that it will be useful, but | ||
8 | * WITHOUT ANY WARRANTY; without even the implied warranty of | ||
9 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
10 | * General Public License for more details. | ||
11 | */ | 3 | */ |
12 | #include <linux/bpf.h> | 4 | #include <linux/bpf.h> |
13 | #include <linux/bpf_trace.h> | 5 | #include <linux/bpf_trace.h> |
@@ -1584,6 +1576,8 @@ bpf_prog_load_check_attach_type(enum bpf_prog_type prog_type, | |||
1584 | case BPF_CGROUP_INET6_CONNECT: | 1576 | case BPF_CGROUP_INET6_CONNECT: |
1585 | case BPF_CGROUP_UDP4_SENDMSG: | 1577 | case BPF_CGROUP_UDP4_SENDMSG: |
1586 | case BPF_CGROUP_UDP6_SENDMSG: | 1578 | case BPF_CGROUP_UDP6_SENDMSG: |
1579 | case BPF_CGROUP_UDP4_RECVMSG: | ||
1580 | case BPF_CGROUP_UDP6_RECVMSG: | ||
1587 | return 0; | 1581 | return 0; |
1588 | default: | 1582 | default: |
1589 | return -EINVAL; | 1583 | return -EINVAL; |
@@ -1892,6 +1886,8 @@ static int bpf_prog_attach(const union bpf_attr *attr) | |||
1892 | case BPF_CGROUP_INET6_CONNECT: | 1886 | case BPF_CGROUP_INET6_CONNECT: |
1893 | case BPF_CGROUP_UDP4_SENDMSG: | 1887 | case BPF_CGROUP_UDP4_SENDMSG: |
1894 | case BPF_CGROUP_UDP6_SENDMSG: | 1888 | case BPF_CGROUP_UDP6_SENDMSG: |
1889 | case BPF_CGROUP_UDP4_RECVMSG: | ||
1890 | case BPF_CGROUP_UDP6_RECVMSG: | ||
1895 | ptype = BPF_PROG_TYPE_CGROUP_SOCK_ADDR; | 1891 | ptype = BPF_PROG_TYPE_CGROUP_SOCK_ADDR; |
1896 | break; | 1892 | break; |
1897 | case BPF_CGROUP_SOCK_OPS: | 1893 | case BPF_CGROUP_SOCK_OPS: |
@@ -1977,6 +1973,8 @@ static int bpf_prog_detach(const union bpf_attr *attr) | |||
1977 | case BPF_CGROUP_INET6_CONNECT: | 1973 | case BPF_CGROUP_INET6_CONNECT: |
1978 | case BPF_CGROUP_UDP4_SENDMSG: | 1974 | case BPF_CGROUP_UDP4_SENDMSG: |
1979 | case BPF_CGROUP_UDP6_SENDMSG: | 1975 | case BPF_CGROUP_UDP6_SENDMSG: |
1976 | case BPF_CGROUP_UDP4_RECVMSG: | ||
1977 | case BPF_CGROUP_UDP6_RECVMSG: | ||
1980 | ptype = BPF_PROG_TYPE_CGROUP_SOCK_ADDR; | 1978 | ptype = BPF_PROG_TYPE_CGROUP_SOCK_ADDR; |
1981 | break; | 1979 | break; |
1982 | case BPF_CGROUP_SOCK_OPS: | 1980 | case BPF_CGROUP_SOCK_OPS: |
@@ -2028,6 +2026,8 @@ static int bpf_prog_query(const union bpf_attr *attr, | |||
2028 | case BPF_CGROUP_INET6_CONNECT: | 2026 | case BPF_CGROUP_INET6_CONNECT: |
2029 | case BPF_CGROUP_UDP4_SENDMSG: | 2027 | case BPF_CGROUP_UDP4_SENDMSG: |
2030 | case BPF_CGROUP_UDP6_SENDMSG: | 2028 | case BPF_CGROUP_UDP6_SENDMSG: |
2029 | case BPF_CGROUP_UDP4_RECVMSG: | ||
2030 | case BPF_CGROUP_UDP6_RECVMSG: | ||
2031 | case BPF_CGROUP_SOCK_OPS: | 2031 | case BPF_CGROUP_SOCK_OPS: |
2032 | case BPF_CGROUP_DEVICE: | 2032 | case BPF_CGROUP_DEVICE: |
2033 | case BPF_CGROUP_SYSCTL: | 2033 | case BPF_CGROUP_SYSCTL: |