mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [for-linus][PATCH 0/3] tracing: More fixes for v7.3
@ 2026-10-16 13:32 Steven Rostedt
  2026-10-16 13:32 ` [for-linus][PATCH 1/3] tracing: Fix crash in print_graph_function_event() Steven Rostedt
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Steven Rostedt @ 2026-10-16 13:32 UTC (permalink / raw)
  To: linux-kernel
  Cc: Masami Hiramatsu, Mark Rutland, Mathieu Desnoyers, Andrew Morton,
	Hao Ge, Taeyang Lee


tracing fixes for v7.3:

- Fix a crash in print_graph_function_event()

  When a tracer does not define static or default flags the
  tr->current_trace_flags is set to NULL. If the ring buffer is
  not cleared when switching tracers, the previous tracers events
  could be read. The function_graph entries will dereference the
  tr->current_trace_flags and cause a crash.

  Set the tr->current_trace_flags to a empty set of flags to prevent
  it from being NULL.

- Separate tracing filter predicate count from allocation

  The amount allocated for the predicate program is the number of predicates
  defined plus two for adding "true" and "false" at the end. The nr_preds is
  incremented by two to accommodate the booleans but is then used as the
  limit check for number of predicates. This is incorrect as it is now two
  higher than what is expected.

  Use a separate variable for the size of the predicate array.

- Fix the filter operator stack check

  The operator stack increments the pointer and then writes the content onto
  the stack. The check for overflow compared the current pointer to see if
  it was greater than the stack size before doing so. This is an off by 2
  error as the write will be at the size - 1 and the compare is done before
  the increment. Adjust the check accordingly.

  git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git
trace/fixes

Head SHA1: c47a7b11bcb3d45e29723afcf6336866476b1d08


Hao Ge (1):
      tracing: Fix crash in print_graph_function_event()

Taeyang Lee (2):
      tracing: Keep the predicate limit separate from program capacity
      tracing: Check operator stack capacity before pushing

----
 kernel/trace/trace.c               | 20 ++++++++++++++++++--
 kernel/trace/trace_events_filter.c |  9 ++++-----
 2 files changed, 22 insertions(+), 7 deletions(-)

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-10-16 13:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-16 13:32 [for-linus][PATCH 0/3] tracing: More fixes for v7.3 Steven Rostedt
2026-10-16 13:32 ` [for-linus][PATCH 1/3] tracing: Fix crash in print_graph_function_event() Steven Rostedt
2026-10-16 13:32 ` [for-linus][PATCH 2/3] tracing: Keep the predicate limit separate from program capacity Steven Rostedt
2026-10-16 13:32 ` [for-linus][PATCH 3/3] tracing: Check operator stack capacity before pushing Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®