mbox series

[0/4] libtracefs: Add more iterator helpers

Message ID 20221115034712.2447458-1-rostedt@goodmis.org (mailing list archive)
Headers show
Series libtracefs: Add more iterator helpers | expand

Message

Steven Rostedt Nov. 15, 2022, 3:47 a.m. UTC
From: "Steven Rostedt (Google)" <rostedt@goodmis.org>

Add follow event and missed events callback helper to make it simpler to follow
events using the tracefs_iterate_raw_events() function.

Also change tracefs_iterate_raw_events() to use the tracefs_cpu_buffered_read()
that will read via splice and is much more efficient than using single reads.

Steven Rostedt (Google) (4):
  libtracefs: Use tracefs_cpu_read() for tracefs_iterate_raw_events()
  libtracefs: Split out iterator functions from man page
  libtracefs: Add tracefs_follow_event() API
  libtracefs: Add tracefs_follow_missed_events() API

 Documentation/libtracefs-events.txt   |  32 +--
 Documentation/libtracefs-iterator.txt | 228 ++++++++++++++++++++
 include/tracefs-local.h               |  12 ++
 include/tracefs.h                     |  11 +
 src/tracefs-events.c                  | 292 +++++++++++++++++++++-----
 5 files changed, 490 insertions(+), 85 deletions(-)
 create mode 100644 Documentation/libtracefs-iterator.txt