Re: [PATCH v3 05/18] rv: Add generic monitor event tracepoints and BPF kfuncs
From: Alexei Starovoitov
Date: Tue Dec 01 2026 - 00:06:34 EST
On Mon, Nov 30, 2026 at 02:56 AM Gabriele Monaco <gmonaco@xxxxxxxxxx> wrote:
> Especially the events channel has the potential to flood other bpf_printk
> readers, I'm not sure whether that's acceptable.
>
> We can apply filters for rv, but then any other user interested in bpf_printk
> would need to filter rv out.
Well, yes, but one filter drops them for all trace_pipe readers:
cd /sys/kernel/tracing/events/bpf_trace/bpf_trace_printk
echo '!(bpf_string ~ "rv: *")' > filter
trivial thing, so I really don't get the idea of introducing extra kfuncs
to behave like printk-s.
> If the amount of messages isn't an issue on the standard bpf_printk, we can just
> use that, users are going to need to parse strings either ways.
bpf_printk is based on ftrace/tracing/ring_buffer and it's definitely flood-proof.
Last time I checked it worked from NMI and from page fault handlers where
normal printk isn't an option.