Commit 23fcfcf8 authored by Andrii Nakryiko's avatar Andrii Nakryiko Committed by Alexei Starovoitov

perf: use generic bpf_program__set_type() to set BPF prog type

bpf_program__set_<type>() APIs are deprecated, use generic
bpf_program__set_type() APIs instead.
Signed-off-by: default avatarAndrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/r/20220124194254.2051434-8-andrii@kernel.orgSigned-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
parent 61afd3da
...@@ -656,11 +656,11 @@ int bpf__probe(struct bpf_object *obj) ...@@ -656,11 +656,11 @@ int bpf__probe(struct bpf_object *obj)
} }
if (priv->is_tp) { if (priv->is_tp) {
bpf_program__set_tracepoint(prog); bpf_program__set_type(prog, BPF_PROG_TYPE_TRACEPOINT);
continue; continue;
} }
bpf_program__set_kprobe(prog); bpf_program__set_type(prog, BPF_PROG_TYPE_KPROBE);
pev = &priv->pev; pev = &priv->pev;
err = convert_perf_probe_events(pev, 1); err = convert_perf_probe_events(pev, 1);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment