mbox series

[0/2] libtracefs: Make hist variable names unique

Message ID 20210812005546.910833-1-rostedt@goodmis.org (mailing list archive)
Headers show
Series libtracefs: Make hist variable names unique | expand

Message

Steven Rostedt Aug. 12, 2021, 12:55 a.m. UTC
From: "Steven Rostedt (VMware)" <rostedt@goodmis.org>

In order to be able to have API that can do onmax() and onchange() as well
as include the .save() and .snapshot() actions, we need to make sure that
the variable names are unique even between different events.

The first adds a "randomness" to the name, and the second patch fixes an
issue where the "end" event fields are saved in the same name as they are
called, then the ".save" action can not be used on them.

Steven Rostedt (VMware) (2):
  libtracefs: Add random number to keep synthetic variables unique
  libtracefs: Have end event variables not be the end event field name

 src/tracefs-hist.c | 35 +++++++++++++++++++++++++----------
 1 file changed, 25 insertions(+), 10 deletions(-)