mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 16:44:10 +08:00
selftests/bpf: Move ENOTSUPP from bpf_util.h
Moving the definition of ENOTSUPP into bpf_util.h to remove the duplicated definitions in multiple files. Signed-off-by: Hou Tao <houtao1@huawei.com> Link: https://lore.kernel.org/r/20241106063542.357743-3-houtao@huaweicloud.com Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
This commit is contained in:
parent
b9e9ed90b1
commit
503cfb103c
@ -67,5 +67,8 @@ static inline void bpf_strlcpy(char *dst, const char *src, size_t sz)
|
||||
#define sys_gettid() syscall(SYS_gettid)
|
||||
#endif
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
#define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
#endif /* __BPF_UTIL__ */
|
||||
|
@ -16,10 +16,6 @@
|
||||
#include "tcp_ca_kfunc.skel.h"
|
||||
#include "bpf_cc_cubic.skel.h"
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
#define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
static const unsigned int total_bytes = 10 * 1024 * 1024;
|
||||
static int expected_stg = 0xeB9F;
|
||||
|
||||
|
@ -10,10 +10,6 @@
|
||||
#include "cgroup_helpers.h"
|
||||
#include "network_helpers.h"
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
#define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
static struct btf *btf;
|
||||
|
||||
static __u32 query_prog_cnt(int cgroup_fd, const char *attach_func)
|
||||
|
@ -23,10 +23,6 @@
|
||||
#include "getpeername_unix_prog.skel.h"
|
||||
#include "network_helpers.h"
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
# define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
#define TEST_NS "sock_addr"
|
||||
#define TEST_IF_PREFIX "test_sock_addr"
|
||||
#define TEST_IPV4 "127.0.0.4"
|
||||
|
@ -26,10 +26,6 @@
|
||||
#include "test_maps.h"
|
||||
#include "testing_helpers.h"
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
#define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
int skips;
|
||||
|
||||
static struct bpf_map_create_opts map_opts = { .sz = sizeof(map_opts) };
|
||||
|
@ -42,10 +42,6 @@
|
||||
#include "../../../include/linux/filter.h"
|
||||
#include "testing_helpers.h"
|
||||
|
||||
#ifndef ENOTSUPP
|
||||
#define ENOTSUPP 524
|
||||
#endif
|
||||
|
||||
#define MAX_INSNS BPF_MAXINSNS
|
||||
#define MAX_EXPECTED_INSNS 32
|
||||
#define MAX_UNEXPECTED_INSNS 32
|
||||
|
Loading…
Reference in New Issue
Block a user