[for-linus][PATCH 0/2] ftrace: Fixes for v6.13

Steven Rostedt posted 2 patches 1 year, 1 month ago
There is a newer version of this series
[for-linus][PATCH 0/2] ftrace: Fixes for v6.13
Posted by Steven Rostedt 1 year, 1 month ago
Fixes for ftrace in v6.13:

- Add needed READ_ONCE() around access to the fgraph array element

  The updates to the fgraph array can happen when callbacks are registered
  and unregistered. The __ftrace_return_to_handler() can handle reading
  either the old value or the new value. But once it reads that value
  it must stay consistent otherwise the check that looks to see if the
  value is a stub may show false, but if the compiler decides to re-read
  after that check, it can be true which can cause the code to crash
  later on.

- Make function profiler use the top level ops for filtering again

  When function graph became available for instances, its filter ops became
  independent from the top level set_ftrace_filter. In the process the
  function profiler received its own filter ops as well. But the function
  profiler uses the top level set_ftrace_filter file and does not have one
  of its own. In giving it its own filter ops, it lost any user interface
  it once had. Make it use the top level set_ftrace_filter file again.
  This fixes a regression.