On 13.09.23 15:26, Steven Rostedt wrote:
On Wed, 13 Sep 2023 13:38:27 +0200 Juergen Gross <jgr...@suse.com> wrote:diff --git a/include/trace/events/xen.h b/include/trace/events/xen.h index 44a3f565264d..0577f0cdd231 100644 --- a/include/trace/events/xen.h +++ b/include/trace/events/xen.h @@ -6,26 +6,26 @@ #define _TRACE_XEN_H#include <linux/tracepoint.h>-#include <asm/paravirt_types.h> +#include <asm/xen/hypervisor.h> #include <asm/xen/trace_types.h>struct multicall_entry; /* Multicalls */DECLARE_EVENT_CLASS(xen_mc__batch, - TP_PROTO(enum paravirt_lazy_mode mode), + TP_PROTO(enum xen_lazy_mode mode), TP_ARGS(mode), TP_STRUCT__entry( - __field(enum paravirt_lazy_mode, mode) + __field(enum xen_lazy_mode, mode) ), TP_fast_assign(__entry->mode = mode), TP_printk("start batch LAZY_%s", - (__entry->mode == PARAVIRT_LAZY_MMU) ? "MMU" : - (__entry->mode == PARAVIRT_LAZY_CPU) ? "CPU" : "NONE") + (__entry->mode == XEN_LAZY_MMU) ? "MMU" : + (__entry->mode == XEN_LAZY_CPU) ? "CPU" : "NONE")There's helper functions that make the above easier to implement as well as exports the symbols so that user space can parse this better: TRACE_DEFINE_ENUM(XEN_LAZY_NONE); TRACE_DEFINE_ENUM(XEN_LAZY_MMU); TRACE_DEFINE_ENUM(XEN_LAZY_CPU); [..] TP_printk("start batch LAZY_%s", __print_symbolic(mode, { XEN_LAZY_NONE, "NONE" }, { XEN_LAZY_MMU, "MMU }, { XEN_LAZY_CPU, "CPU" })) Then user space parsers that read the raw data can convert these events into something humans can read.
Thanks. I'll add that to another patch I'm just writing for cleaning up include/trace/events/xen.h (some defined trace events are no longer used). Juergen
OpenPGP_0xB0DE9DD628BF132F.asc
Description: OpenPGP public key
OpenPGP_signature.asc
Description: OpenPGP digital signature
_______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization