[for-linus][PATCH 0/4] tracing: Fixes for v7.2
From: Steven Rostedt
Date: Fri Jul 10 2026 - 21:21:04 EST
tracing fixes for v7.2:
- Add selftest that tests deferred event teardown
- Fix leak in error path of trace_remote_alloc_buffer()
If page allocation fails, the desc->nr_cpus is not incremented for the
current CPU and the allocations done for it are not freed.
- Fix allocation length in trace_remote_alloc_buffer()
The logic to calculate the struct_len was doing a double count and setting
the value too large. Calculate the size upfront to fix the error and
simplify the logic.
- Fix sparse CPU masks in ring_buffer_desc()
If there are sparse CPUs (gaps in the numbering), the ring_buffer_desc()
will fail as it tests the CPU number against the number of CPUs that are
used.
git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git
trace/fixes
Head SHA1: 601ddaceb861be7eb557278109966320a6f3478c
Michael Bommarito (1):
selftests/user_events: Wait for deferred event teardown after unregister
Vincent Donnefort (3):
tracing/remotes: Fix leak in trace_remote_alloc_buffer() error path
tracing/remotes: Fix struct_len in trace_remote_alloc_buffer()
ring-buffer: Allow sparse CPU masks in ring_buffer_desc()
----
kernel/trace/ring_buffer.c | 5 +----
kernel/trace/trace_remote.c | 18 +++++----------
tools/testing/selftests/user_events/abi_test.c | 29 ++++++++++++++++++++++++-
tools/testing/selftests/user_events/perf_test.c | 26 +++++++++++++++++++---
4 files changed, 58 insertions(+), 20 deletions(-)