* [stable request] 6.18: tracing/kprobes: Skip setup_boot_kprobe_events() when no cmdline event
[not found] <CAEF_Rj9AGCqWh4TeX0y1sOoF5g7jEh_Xhp_EnKPSEQ9thU3mmg@mail.gmail.com>
@ 2026-11-21 2:03 ` André Freitag
2026-11-21 15:27 ` Sasha Levin
0 siblings, 1 reply; 2+ messages in thread
From: André Freitag @ 2026-11-21 2:03 UTC (permalink / raw)
To: stable; +Cc: tianyaxiong, rostedt, mhiramat
Hi,
please consider this upstream commit for 6.18.y:
2cdfe39dc944 ("tracing/kprobes: Skip setup_boot_kprobe_events() when
no cmdline event")
Without it, init_kprobe_trace() always calls setup_boot_kprobe_events(), whose
enable_boot_kprobe_events() takes event_mutex even when no
kprobe_event= is given, and so
waits for the asynchronous tracefs event setup that holds that lock.
On KVM guests (Cloud Hypervisor, 2 vCPU, 6.18.57,
CONFIG_KPROBE_EVENTS=y, no kprobe_event=
on the command line), initcall_debug shows init_kprobe_trace taking
about 130 ms, the
largest initcall. With 2cdfe39dc944 applied it takes 1 us, and kernel
start to userspace
goes from about 317 ms to about 251 ms (three boots each).
The commit applies cleanly to 6.18.57 and 6.18.64 (four added lines in
kernel/trace/trace_kprobe.c) and has no dependencies.
Thanks,
André Freitag
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [stable request] 6.18: tracing/kprobes: Skip setup_boot_kprobe_events() when no cmdline event
2026-11-21 2:03 ` [stable request] 6.18: tracing/kprobes: Skip setup_boot_kprobe_events() when no cmdline event André Freitag
@ 2026-11-21 15:27 ` Sasha Levin
0 siblings, 0 replies; 2+ messages in thread
From: Sasha Levin @ 2026-11-21 15:27 UTC (permalink / raw)
To: stable; +Cc: Sasha Levin, tianyaxiong, rostedt, mhiramat, André Freitag
> please consider this upstream commit for 6.18.y:
>
> 2cdfe39dc944 ("tracing/kprobes: Skip setup_boot_kprobe_events() when
> no cmdline event")
This is a boot-time optimization rather than a fix, and it has no Fixes: or
stable tag upstream, so I'm going to pass on it for 6.18.
--
Thanks,
Sasha
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-21 15:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <CAEF_Rj9AGCqWh4TeX0y1sOoF5g7jEh_Xhp_EnKPSEQ9thU3mmg@mail.gmail.com>
2026-11-21 2:03 ` [stable request] 6.18: tracing/kprobes: Skip setup_boot_kprobe_events() when no cmdline event André Freitag
2026-11-21 15:27 ` Sasha Levin
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.