All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 00/10] cxl: add monitor support for trace events
@ 2022-11-08 18:29 Dave Jiang
  2022-11-08 18:29 ` [PATCH v4 01/10] cxl: add helper function to parse trace event to json object Dave Jiang
                   ` (9 more replies)
  0 siblings, 10 replies; 26+ messages in thread
From: Dave Jiang @ 2022-11-08 18:29 UTC (permalink / raw)
  To: linux-cxl
  Cc: dan.j.williams, ira.weiny, vishal.l.verma, alison.schofield, rostedt

This patch series for ndctl implements the monitor command for the cxl tool.
The initial implementation will collect CXL trace events emitted by the
kernel. libtraceevent and libtracefs will be used to parse the trace
event buffer. The monitor will pend on an epoll fd and wait for new event
entries to be posted. The output will be in json format. By default the events
are emitted to stdio, but can also be logged to a file. Each event is converted
to a JSON object and logged as such. All the fields exported are read by the
monitor code and added to the JSON object.

v4:
- Fix num_to_json for less than int size (Ira)
- Use TEP_FIELD flags to determine data type. (Steve)
- Use tracefs_event_enable() instad of directly toggle sysfs via lib calls (Steve)
- Remove tracefs_trace_is_on() in disable() call (Steve)
- Update to use tep_data_pid() (Steve)

v3:
- Change uuid parsing from u8[] to uuid_t (Alison)
- Add event_name to event_ctx for filtering (Alison)
- Add event_pid to event_ctx for filtering (Alison)
- Add parse_event callback to event_ctx for filtering (Alison)

v2:
- Simplify logging functions (Nathan)
- Drop ndctl prefix (Vishal)
- Reduce to single trace event system (Alison)
- Add systemd startup file
- Add man page

---

Alison Schofield (1):
      cxl: add an optional pid check to event parsing

Dave Jiang (9):
      cxl: add helper function to parse trace event to json object
      cxl: add helper to parse through all current events
      cxl: add common function to enable event trace
      cxl: add common function to disable event trace
      cxl: add monitor function for event trace events
      cxl: add logging functions for monitor
      cxl: add monitor command to cxl
      cxl: add systemd service for monitor
      cxl: add man page documentation for monitor


 Documentation/cxl/cxl-monitor.txt |  77 +++++++++
 cxl/builtin.h                     |   1 +
 cxl/cxl-monitor.service           |   9 +
 cxl/cxl.c                         |   1 +
 cxl/event_trace.c                 | 263 ++++++++++++++++++++++++++++++
 cxl/event_trace.h                 |  28 ++++
 cxl/meson.build                   |   8 +
 cxl/monitor.c                     | 240 +++++++++++++++++++++++++++
 meson.build                       |   3 +
 ndctl.spec.in                     |   1 +
 10 files changed, 631 insertions(+)
 create mode 100644 Documentation/cxl/cxl-monitor.txt
 create mode 100644 cxl/cxl-monitor.service
 create mode 100644 cxl/event_trace.c
 create mode 100644 cxl/event_trace.h
 create mode 100644 cxl/monitor.c

--


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

end of thread, other threads:[~2022-11-17 20:44 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-08 18:29 [PATCH v4 00/10] cxl: add monitor support for trace events Dave Jiang
2022-11-08 18:29 ` [PATCH v4 01/10] cxl: add helper function to parse trace event to json object Dave Jiang
2022-11-08 23:02   ` Verma, Vishal L
2022-11-09 21:27     ` Dave Jiang
2022-11-08 18:29 ` [PATCH v4 02/10] cxl: add helper to parse through all current events Dave Jiang
2022-11-08 23:45   ` Verma, Vishal L
2022-11-09 21:30     ` Dave Jiang
2022-11-08 18:30 ` [PATCH v4 03/10] cxl: add common function to enable event trace Dave Jiang
2022-11-08 18:30 ` [PATCH v4 04/10] cxl: add common function to disable " Dave Jiang
2022-11-08 23:47   ` Verma, Vishal L
2022-11-08 18:30 ` [PATCH v4 05/10] cxl: add monitor function for event trace events Dave Jiang
2022-11-17 18:37   ` Steven Rostedt
2022-11-17 20:29     ` Dave Jiang
2022-11-17 20:33       ` Steven Rostedt
2022-11-17 20:44         ` Dave Jiang
2022-11-08 18:30 ` [PATCH v4 06/10] cxl: add logging functions for monitor Dave Jiang
2022-11-09  0:31   ` Verma, Vishal L
2022-11-08 18:30 ` [PATCH v4 07/10] cxl: add monitor command to cxl Dave Jiang
2022-11-09  0:35   ` Verma, Vishal L
2022-11-08 18:30 ` [PATCH v4 08/10] cxl: add an optional pid check to event parsing Dave Jiang
2022-11-09  0:48   ` Verma, Vishal L
2022-11-09 22:44     ` Dave Jiang
2022-11-08 18:30 ` [PATCH v4 09/10] cxl: add systemd service for monitor Dave Jiang
2022-11-09  0:48   ` Verma, Vishal L
2022-11-08 18:30 ` [PATCH v4 10/10] cxl: add man page documentation " Dave Jiang
2022-11-09  0:58   ` Verma, Vishal L

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.