Skip to content
Open

Master #10520

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions kernel/bpf/btf.c
Original file line number Diff line number Diff line change
Expand Up @@ -8681,6 +8681,7 @@ static int bpf_prog_type_to_kfunc_hook(enum bpf_prog_type prog_type)
return BTF_KFUNC_HOOK_STRUCT_OPS;
case BPF_PROG_TYPE_TRACING:
case BPF_PROG_TYPE_TRACEPOINT:
case BPF_PROG_TYPE_RAW_TRACEPOINT:
case BPF_PROG_TYPE_PERF_EVENT:
case BPF_PROG_TYPE_LSM:
return BTF_KFUNC_HOOK_TRACING;
Expand Down
2 changes: 1 addition & 1 deletion tools/testing/selftests/bpf/progs/dynptr_fail.c
Original file line number Diff line number Diff line change
Expand Up @@ -1465,7 +1465,7 @@ int xdp_invalid_data_slice2(struct xdp_md *xdp)
}

/* Only supported prog type can create skb-type dynptrs */
SEC("?raw_tp")
SEC("?xdp")
__failure __msg("calling kernel function bpf_dynptr_from_skb is not allowed")
int skb_invalid_ctx(void *ctx)
{
Expand Down
6 changes: 3 additions & 3 deletions tools/testing/selftests/bpf/progs/verifier_kfunc_prog_types.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ static void task_kfunc_load_test(void)
}

SEC("raw_tp")
__failure __msg("calling kernel function")
__success
int BPF_PROG(task_kfunc_raw_tp)
{
task_kfunc_load_test();
Expand Down Expand Up @@ -86,7 +86,7 @@ static void cgrp_kfunc_load_test(void)
}

SEC("raw_tp")
__failure __msg("calling kernel function")
__success
int BPF_PROG(cgrp_kfunc_raw_tp)
{
cgrp_kfunc_load_test();
Expand Down Expand Up @@ -138,7 +138,7 @@ static void cpumask_kfunc_load_test(void)
}

SEC("raw_tp")
__failure __msg("calling kernel function")
__success
int BPF_PROG(cpumask_kfunc_raw_tp)
{
cpumask_kfunc_load_test();
Expand Down
Loading