Re: [PATCH RFC bpf-next 07/31] bpf: Add support to attach inlined functions with kprobe multi link

From: Alexei Starovoitov

Date: Wed Dec 02 2026 - 20:51:43 EST


On Wed, Dec 02, 2026 at 04:30 AM Jiri Olsa <jolsa@xxxxxxxxxx> wrote:
> + if (!kallsyms_lookup_size_offset(addr, &size, &offset))
> + return false;
> + addr -= offset;
> + return ftrace_location_range(addr, addr + size - 1);

gcc moves unlikely paths of foo() into foo.cold, which has no fentry call.
An instance in foo.cold is skipped, though foo() is traceable.
With the strict flag from patch 14 it fails the attach.
within_notrace_func() handles this case since
commit c7411a1a126f ("tracing/kprobe: Check whether the non-suffixed
symbol is notrace").
can we reuse it ?