Skip to content

Commit a1661f7

Browse files
committed
bpf_features enum
1 parent 3e287cb commit a1661f7

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

kernel/bpf/verifier.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,11 @@ static const struct bpf_verifier_ops * const bpf_verifier_ops[] = {
4444
#undef BPF_LINK_TYPE
4545
};
4646

47+
enum bpf_features {
48+
BPF_FEAT_RDONLY_CAST_TO_VOID = 0,
49+
BPF_FEAT_TOTAL,
50+
};
51+
4752
struct bpf_mem_alloc bpf_global_percpu_ma;
4853
static bool bpf_global_percpu_ma_set;
4954

@@ -24439,6 +24444,8 @@ int bpf_check(struct bpf_prog **prog, union bpf_attr *attr, bpfptr_t uattr, __u3
2443924444
u32 log_true_size;
2444024445
bool is_priv;
2444124446

24447+
BTF_TYPE_EMIT(enum bpf_features);
24448+
2444224449
/* no program is valid */
2444324450
if (ARRAY_SIZE(bpf_verifier_ops) == 0)
2444424451
return -EINVAL;

0 commit comments

Comments
 (0)