From: Steven Rostedt <rostedt@goodmis.org>
To: Juergen Gross <jgross@suse.com>
Cc: linux-kernel@vger.kernel.org, x86@kernel.org,
virtualization@lists.linux-foundation.org,
linux-trace-kernel@vger.kernel.org,
Ajay Kaher <akaher@vmware.com>,
Alexey Makhalov <amakhalov@vmware.com>,
VMware PV-Drivers Reviewers <pv-drivers@vmware.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
Dave Hansen <dave.hansen@linux.intel.com>,
"H. Peter Anvin" <hpa@zytor.com>,
Boris Ostrovsky <boris.ostrovsky@oracle.com>,
Masami Hiramatsu <mhiramat@kernel.org>,
xen-devel@lists.xenproject.org
Subject: Re: [PATCH 2/3] x86/xen: move paravirt lazy code
Date: Wed, 13 Sep 2023 09:26:46 -0400 [thread overview]
Message-ID: <20230913092646.5b087871@gandalf.local.home> (raw)
In-Reply-To: <20230913113828.18421-3-jgross@suse.com>
On Wed, 13 Sep 2023 13:38:27 +0200
Juergen Gross <jgross@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.
-- Steve
> );
> #define DEFINE_XEN_MC_BATCH(name) \
> DEFINE_EVENT(xen_mc__batch, name, \
> - TP_PROTO(enum paravirt_lazy_mode mode), \
> + TP_PROTO(enum xen_lazy_mode mode), \
> TP_ARGS(mode))
>
> DEFINE_XEN_MC_BATCH(xen_mc_batch);
next prev parent reply other threads:[~2023-09-13 13:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-13 11:38 [PATCH 0/3] xen: cleanup and fix lazy mode handling Juergen Gross
2023-09-13 11:38 ` [PATCH 2/3] x86/xen: move paravirt lazy code Juergen Gross
2023-09-13 13:26 ` Steven Rostedt [this message]
2023-09-13 13:36 ` Juergen Gross
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230913092646.5b087871@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=akaher@vmware.com \
--cc=amakhalov@vmware.com \
--cc=boris.ostrovsky@oracle.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=jgross@suse.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=mingo@redhat.com \
--cc=pv-drivers@vmware.com \
--cc=tglx@linutronix.de \
--cc=virtualization@lists.linux-foundation.org \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox