Re: [patch 1/2] KVM: convert custom marker based tracing to event traces

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jun 15, 2009 at 04:03:10PM -0400, Steven Rostedt wrote:
> 
> On Mon, 15 Jun 2009, Marcelo Tosatti wrote:
> 
> > This allows use of the powerful ftrace infrastructure.
> > 
> > See Documentation/trace/ for usage information.
> > 
> > Signed-off-by: Marcelo Tosatti <mtosatti@xxxxxxxxxx>
> > 
> > Index: kvm/arch/x86/kvm/svm.c
> > ===================================================================
> > --- kvm.orig/arch/x86/kvm/svm.c
> > +++ kvm/arch/x86/kvm/svm.c
> > @@ -29,6 +29,9 @@
> >  #include <asm/desc.h>
> >  
> >  #include <asm/virtext.h>
> > +#include "svm-trace.h"
> > +#define CREATE_TRACE_POINTS
> > +#include <trace/events/kvm/x86-arch.h>
> >  
> >  #define __ex(x) __kvm_handle_fault_on_reboot(x)
> >  
> 
> 
> > Index: kvm/arch/x86/kvm/vmx.c
> > ===================================================================
> > --- kvm.orig/arch/x86/kvm/vmx.c
> > +++ kvm/arch/x86/kvm/vmx.c
> > @@ -34,6 +34,10 @@
> >  #include <asm/virtext.h>
> >  #include <asm/mce.h>
> >  
> > +#include "vmx-trace.h"
> > +#define CREATE_TRACE_POINTS
> > +#include <trace/events/kvm/x86-arch.h>
> > +
> >  #define __ex(x) __kvm_handle_fault_on_reboot(x)
> >  
> >  MODULE_AUTHOR("Qumranet");
> 
> > Index: kvm/arch/x86/kvm/x86.c
> > ===================================================================
> > --- kvm.orig/arch/x86/kvm/x86.c
> > +++ kvm/arch/x86/kvm/x86.c
> > @@ -37,6 +37,8 @@
> >  #include <linux/iommu.h>
> >  #include <linux/intel-iommu.h>
> >  #include <linux/cpufreq.h>
> > +#define CREATE_TRACE_POINTS
> > +#include <trace/events/kvm/x86.h>
> >  
> >  #include <asm/uaccess.h>
> >  #include <asm/msr.h>
> > @@ -347,9 +349,6 @@ EXPORT_SYMBOL_GPL(kvm_set_cr0);
> 
> 
> > Index: kvm/include/trace/events/kvm/x86-arch.h
> > ===================================================================
> > --- /dev/null
> > +++ kvm/include/trace/events/kvm/x86-arch.h
> 
> 
> One suggestion. Instead of putting in arch specific trace points into 
> generic code, you can put these into arch/x86/kvm/trace.h ?
> 
> Then you can in the Makefile add:
> 
> CFLAGS_x86.o := -I.
> CFLAGS_svm.o := -I.
> CFLAGS_vmx.o := -I.
> 
> Or better yet, have a single file called trace.c:
> 
> in the Makefile:
> CFLAGS_trace.o := -I.
> obj-$(EVENT_TRACING) += trace.o
> 
> in trace.c:
> 
> #define CREATE_TRACE_POINTS
> #include "trace.h"
> #include "trace-arch.h"
> 
> 
> Then have the kvm/x86.h moved to trace.h
> and the kvm/arch-x86.h move to trace-arch.h
> 
> Just change the "TRACE_INCLUDE_FILE" to include the proper name.
> 
> -- Steve

Similar to http://patchwork.kernel.org/patch/23829/, but moving the
x86 tracepoint definitions to arch/x86/kvm/ ?

I thought the point of include/trace/ was to have all tracepoints
definitions in a single directory?
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux