Re: [PATCH v2 bpf-next 11/14] libbpf: add user_ctx to perf_event, kprobe, uprobe, and tp attach APIs
From: Rafael David Tinoco <hidden>
Date: 2021-07-30 01:12:06
From: Rafael David Tinoco <hidden>
Date: 2021-07-30 01:12:06
On Mon, Jul 26, 2021, at 13:12, Andrii Nakryiko wrote:
Wire through user_ctx for all attach APIs that use perf_event_open under the
hood:
- for kprobes, extend existing bpf_kprobe_opts with user_ctx field;
- for perf_event, uprobe, and tracepoint APIs, add their _opts variants and
pass user_ctx through opts.
For kernel that don't support BPF_LINK_CREATE for perf_events, and thus
user_ctx is not supported either, return error and log warning for user.
Cc: Rafael David Tinoco <redacted>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>I think this one is fuzzy in v2. Checking them now for my purposes. Thanks for CC'ing.