Merge branch 'upstream/xen-tracing2' of git://git.kernel.org/pub/scm/linux/kernel...
authorLinus Torvalds <torvalds@linux-foundation.org>
Sun, 24 Jul 2011 16:06:47 +0000 (09:06 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 24 Jul 2011 16:06:47 +0000 (09:06 -0700)
* 'upstream/xen-tracing2' of git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen:
  xen/trace: use class for multicall trace
  xen/trace: convert mmu events to use DECLARE_EVENT_CLASS()/DEFINE_EVENT()
  xen/multicall: move *idx fields to start of mc_buffer
  xen/multicall: special-case singleton hypercalls
  xen/multicalls: add unlikely around slowpath in __xen_mc_entry()
  xen/multicalls: disable MC_DEBUG
  xen/mmu: tune pgtable alloc/release
  xen/mmu: use extend_args for more mmuext updates
  xen/trace: add tlb flush tracepoints
  xen/trace: add segment desc tracing
  xen/trace: add xen_pgd_(un)pin tracepoints
  xen/trace: add ptpage alloc/release tracepoints
  xen/trace: add mmu tracepoints
  xen/trace: add multicall tracing
  xen/trace: set up tracepoint skeleton
  xen/multicalls: remove debugfs stats
  trace/xen: add skeleton for Xen trace events

1  2 
arch/x86/xen/Makefile
arch/x86/xen/enlighten.c

diff --combined arch/x86/xen/Makefile
@@@ -13,10 -13,10 +13,10 @@@ CFLAGS_mmu.o                       := $(nostackp
  obj-y         := enlighten.o setup.o multicalls.o mmu.o irq.o \
                        time.o xen-asm.o xen-asm_$(BITS).o \
                        grant-table.o suspend.o platform-pci-unplug.o \
-                       p2m.o
+                       p2m.o trace.o
  
  obj-$(CONFIG_SMP)             += smp.o
  obj-$(CONFIG_PARAVIRT_SPINLOCKS)+= spinlock.o
  obj-$(CONFIG_XEN_DEBUG_FS)    += debugfs.o
 -
 +obj-$(CONFIG_XEN_DOM0)                += vga.o
  obj-$(CONFIG_SWIOTLB_XEN)     += pci-swiotlb-xen.o
diff --combined arch/x86/xen/enlighten.c
@@@ -341,6 -341,8 +341,8 @@@ static void xen_set_ldt(const void *add
        struct mmuext_op *op;
        struct multicall_space mcs = xen_mc_entry(sizeof(*op));
  
+       trace_xen_cpu_set_ldt(addr, entries);
        op = mcs.args;
        op->cmd = MMUEXT_SET_LDT;
        op->arg1.linear_addr = (unsigned long)addr;
@@@ -496,6 -498,8 +498,8 @@@ static void xen_write_ldt_entry(struct 
        xmaddr_t mach_lp = arbitrary_virt_to_machine(&dt[entrynum]);
        u64 entry = *(u64 *)ptr;
  
+       trace_xen_cpu_write_ldt_entry(dt, entrynum, entry);
        preempt_disable();
  
        xen_mc_flush();
@@@ -565,6 -569,8 +569,8 @@@ static void xen_write_idt_entry(gate_de
        unsigned long p = (unsigned long)&dt[entrynum];
        unsigned long start, end;
  
+       trace_xen_cpu_write_idt_entry(dt, entrynum, g);
        preempt_disable();
  
        start = __this_cpu_read(idt_desc.address);
@@@ -619,6 -625,8 +625,8 @@@ static void xen_load_idt(const struct d
        static DEFINE_SPINLOCK(lock);
        static struct trap_info traps[257];
  
+       trace_xen_cpu_load_idt(desc);
        spin_lock(&lock);
  
        __get_cpu_var(idt_desc) = *desc;
  static void xen_write_gdt_entry(struct desc_struct *dt, int entry,
                                const void *desc, int type)
  {
+       trace_xen_cpu_write_gdt_entry(dt, entry, desc, type);
        preempt_disable();
  
        switch (type) {
  static void __init xen_write_gdt_entry_boot(struct desc_struct *dt, int entry,
                                            const void *desc, int type)
  {
+       trace_xen_cpu_write_gdt_entry(dt, entry, desc, type);
        switch (type) {
        case DESC_LDT:
        case DESC_TSS:
  static void xen_load_sp0(struct tss_struct *tss,
                         struct thread_struct *thread)
  {
-       struct multicall_space mcs = xen_mc_entry(0);
+       struct multicall_space mcs;
+       mcs = xen_mc_entry(0);
        MULTI_stack_switch(mcs.mc, __KERNEL_DS, thread->sp0);
        xen_mc_issue(PARAVIRT_LAZY_CPU);
  }
@@@ -1248,14 -1262,6 +1262,14 @@@ asmlinkage void __init xen_start_kernel
                if (pci_xen)
                        x86_init.pci.arch_init = pci_xen_init;
        } else {
 +              const struct dom0_vga_console_info *info =
 +                      (void *)((char *)xen_start_info +
 +                               xen_start_info->console.dom0.info_off);
 +
 +              xen_init_vga(info, xen_start_info->console.dom0.info_size);
 +              xen_start_info->console.domU.mfn = 0;
 +              xen_start_info->console.domU.evtchn = 0;
 +
                /* Make sure ACS will be enabled */
                pci_request_acs();
        }