From mboxrd@z Thu Jan 1 00:00:00 1970 From: George Dunlap Subject: Re: [PATCH 4 of 4] Add a trace hypercall to allow tracing from dom0 or domU Date: Fri, 15 Jul 2011 17:49:06 +0100 Message-ID: <1310748546.448.106.camel@elijah> References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Olaf Hering Cc: George Dunlap , "xen-devel@lists.xensource.com" , Keir Fraser List-Id: xen-devel@lists.xenproject.org On Fri, 2011-07-15 at 16:38 +0100, Olaf Hering wrote: > diff -r 6e4aef7b5051 -r f72dcd1b8bbd xen/include/public/trace.h > --- a/xen/include/public/trace.h > +++ b/xen/include/public/trace.h > @@ -26,6 +26,8 @@ > #ifndef __XEN_PUBLIC_TRACE_H__ > #define __XEN_PUBLIC_TRACE_H__ > > +#include "xen.h" > + > #define TRACE_EXTRA_MAX 7 > #define TRACE_EXTRA_SHIFT 28 > > @@ -65,6 +67,7 @@ > #define TRC_LOST_RECORDS (TRC_GEN + 1) > #define TRC_TRACE_WRAP_BUFFER (TRC_GEN + 2) > #define TRC_TRACE_CPU_CHANGE (TRC_GEN + 3) > +#define TRC_TRACE_GUEST_HYPERCALL (TRC_GEN + 4) Looks like perhaps a leftover from an earlier patch? :-) > diff -r 6e4aef7b5051 -r f72dcd1b8bbd xen/include/public/xen.h > --- a/xen/include/public/xen.h > +++ b/xen/include/public/xen.h > @@ -94,6 +94,7 @@ DEFINE_XEN_GUEST_HANDLE(xen_pfn_t); > #define __HYPERVISOR_kexec_op 37 > #define __HYPERVISOR_tmem_op 38 > #define __HYPERVISOR_xc_reserved_op 39 /* reserved for XenClient */ > +#define __HYPERVISOR_xentrace_op 40 Seems unnecessary to make a whole hypercall just for this one thing, but I'll defer to Keir's judgement on that. At very least, it should accept an "op" command, of which "trace" is just one, so that it's expandable in the future without breaking backwards compatibility. Other than that, looks good -- thanks for doing this. -George