]> nv-tegra.nvidia Code Review - linux-2.6.git/commitdiff
Merge branch 'linus' into perfcounters/core-v2
authorIngo Molnar <mingo@elte.hu>
Mon, 6 Apr 2009 07:02:57 +0000 (09:02 +0200)
committerIngo Molnar <mingo@elte.hu>
Mon, 6 Apr 2009 07:02:57 +0000 (09:02 +0200)
Merge reason: we have gathered quite a few conflicts, need to merge upstream

Conflicts:
arch/powerpc/kernel/Makefile
arch/x86/ia32/ia32entry.S
arch/x86/include/asm/hardirq.h
arch/x86/include/asm/unistd_32.h
arch/x86/include/asm/unistd_64.h
arch/x86/kernel/cpu/common.c
arch/x86/kernel/irq.c
arch/x86/kernel/syscall_table_32.S
arch/x86/mm/iomap_32.c
include/linux/sched.h
kernel/Makefile

Signed-off-by: Ingo Molnar <mingo@elte.hu>
38 files changed:
1  2 
arch/powerpc/include/asm/hw_irq.h
arch/powerpc/include/asm/systbl.h
arch/powerpc/kernel/Makefile
arch/powerpc/kernel/asm-offsets.c
arch/powerpc/kernel/entry_64.S
arch/powerpc/kernel/irq.c
arch/powerpc/platforms/Kconfig.cputype
arch/x86/Kconfig
arch/x86/ia32/ia32entry.S
arch/x86/include/asm/hardirq.h
arch/x86/include/asm/hw_irq.h
arch/x86/include/asm/thread_info.h
arch/x86/include/asm/unistd_32.h
arch/x86/include/asm/unistd_64.h
arch/x86/kernel/apic/apic.c
arch/x86/kernel/cpu/Makefile
arch/x86/kernel/cpu/amd.c
arch/x86/kernel/cpu/common.c
arch/x86/kernel/entry_64.S
arch/x86/kernel/irq.c
arch/x86/kernel/irqinit_32.c
arch/x86/kernel/irqinit_64.c
arch/x86/kernel/signal.c
arch/x86/kernel/syscall_table_32.S
arch/x86/kernel/traps.c
drivers/acpi/processor_idle.c
drivers/char/sysrq.c
fs/exec.c
include/linux/init_task.h
include/linux/kernel_stat.h
include/linux/sched.h
include/linux/syscalls.h
init/Kconfig
kernel/Makefile
kernel/exit.c
kernel/fork.c
kernel/sched.c
kernel/sys.c

index e10f151c3db647b3e4f0c76835dba8879c942707,b7e034b0a6ddbd4bb9d491106e08b791ef3fac22..b43076ff92c9b82baa7a3bfbe35a7e9cbd5c21c1
@@@ -129,38 -129,7 +129,38 @@@ static inline int irqs_disabled_flags(u
   * interrupt-retrigger: should we handle this via lost interrupts and IPIs
   * or should we not care like we do now ? --BenH.
   */
- struct hw_interrupt_type;
+ struct irq_chip;
  
 +#ifdef CONFIG_PERF_COUNTERS
 +static inline unsigned long get_perf_counter_pending(void)
 +{
 +      unsigned long x;
 +
 +      asm volatile("lbz %0,%1(13)"
 +              : "=r" (x)
 +              : "i" (offsetof(struct paca_struct, perf_counter_pending)));
 +      return x;
 +}
 +
 +static inline void set_perf_counter_pending(int x)
 +{
 +      asm volatile("stb %0,%1(13)" : :
 +              "r" (x),
 +              "i" (offsetof(struct paca_struct, perf_counter_pending)));
 +}
 +
 +extern void perf_counter_do_pending(void);
 +
 +#else
 +
 +static inline unsigned long get_perf_counter_pending(void)
 +{
 +      return 0;
 +}
 +
 +static inline void set_perf_counter_pending(int x) {}
 +static inline void perf_counter_do_pending(void) {}
 +#endif /* CONFIG_PERF_COUNTERS */
 +
  #endif        /* __KERNEL__ */
  #endif        /* _ASM_POWERPC_HW_IRQ_H */
Simple merge
index 8e5e2c74971ea31540245ccda8bf7872da4e689a,71901fbda4a5649d737e7f37177da4fa46c3a666..9ba1bb731fccdba664e9397068280d9e7a599925
@@@ -94,8 -93,7 +93,9 @@@ obj-$(CONFIG_AUDIT)           += audit.
  obj64-$(CONFIG_AUDIT)         += compat_audit.o
  
  obj-$(CONFIG_DYNAMIC_FTRACE)  += ftrace.o
+ obj-$(CONFIG_FUNCTION_GRAPH_TRACER)   += ftrace.o
 +obj-$(CONFIG_PERF_COUNTERS)   += perf_counter.o power4-pmu.o ppc970-pmu.o \
 +                                 power5-pmu.o power5+-pmu.o power6-pmu.o
  
  obj-$(CONFIG_8XX_MINIMAL_FPEMU) += softemu8xx.o
  
Simple merge
Simple merge
Simple merge
Simple merge
index e4baa06bbceb7d0ee8d584b334a2a6ccde1bdc77,a505202086e8741a916e696ccfb664d3f3e0f8ef..19c61ef6ab578872299525bb7af74c06bb20e5ea
@@@ -825,8 -825,9 +825,10 @@@ ia32_sys_call_table
        .quad compat_sys_signalfd4
        .quad sys_eventfd2
        .quad sys_epoll_create1
 -      .quad sys_dup3                  /* 330 */
 +      .quad sys_dup3                          /* 330 */
        .quad sys_pipe2
        .quad sys_inotify_init1
+       .quad compat_sys_preadv
+       .quad compat_sys_pwritev
 +      .quad sys_perf_counter_open
  ia32_syscall_end:
index 46ebed797e4f307e8503603e0ef104e4464c3219,039db6aa8e0271951706ee20bd9b819098f8002a..25454427ceea9029a04006677796fd63cb9fe879
@@@ -12,7 -12,7 +12,8 @@@ typedef struct 
        unsigned int apic_timer_irqs;   /* arch dependent */
        unsigned int irq_spurious_count;
  #endif
+       unsigned int generic_irqs;      /* arch dependent */
 +      unsigned int apic_perf_irqs;
  #ifdef CONFIG_SMP
        unsigned int irq_resched_count;
        unsigned int irq_call_count;
index f39881b6b68b33f0f7ccdbe1efbacb121e216112,b762ea49bd703ab3b28958cf83b6908e825e57a4..ae80f64973e01c74d8381e2530a47fc88c16dab9
  
  /* Interrupt handlers registered during init_IRQ */
  extern void apic_timer_interrupt(void);
+ extern void generic_interrupt(void);
  extern void error_interrupt(void);
 +extern void perf_counter_interrupt(void);
 +
  extern void spurious_interrupt(void);
  extern void thermal_interrupt(void);
  extern void reschedule_interrupt(void);
Simple merge
index 7e47658b0a6f2cb12824655908cda3b7acf07112,6e72d74cf8dc74b7720f5cb79ba355a926e7fa6e..0b4d8c2b157d816c34da2b7b901b53ec051fe487
  #define __NR_dup3             330
  #define __NR_pipe2            331
  #define __NR_inotify_init1    332
+ #define __NR_preadv           333
+ #define __NR_pwritev          334
 +#define __NR_perf_counter_open        333
  
  #ifdef __KERNEL__
  
index 53025feaf88dc21d8ac0c79e7ab6f14fffa8bf91,f81829462325f6328a6e6d9c3667da02e9f616d0..d9aad876ad767b3ea80b4c7f3d672ff8b46ddb03
@@@ -653,8 -653,11 +653,12 @@@ __SYSCALL(__NR_dup3, sys_dup3
  __SYSCALL(__NR_pipe2, sys_pipe2)
  #define __NR_inotify_init1                    294
  __SYSCALL(__NR_inotify_init1, sys_inotify_init1)
 -
+ #define __NR_preadv                           295
+ __SYSCALL(__NR_preadv, sys_preadv)
+ #define __NR_pwritev                          296
+ __SYSCALL(__NR_pwritev, sys_pwritev)
 +#define __NR_perf_counter_open                295
 +__SYSCALL(__NR_perf_counter_open, sys_perf_counter_open)
  
  #ifndef __NO_STUBS
  #define __ARCH_WANT_OLD_READDIR
Simple merge
Simple merge
Simple merge
index b66af09a6c7de5783f2f597c6d6f372819714895,c4f667896c28f1a3eb7e6ae33341f5ba98f74c98..a86769efe0dff9dc5d075a3f13543f314331d29f
@@@ -1,30 -1,39 +1,40 @@@
- #include <linux/init.h>
- #include <linux/kernel.h>
- #include <linux/sched.h>
- #include <linux/string.h>
  #include <linux/bootmem.h>
+ #include <linux/linkage.h>
  #include <linux/bitops.h>
+ #include <linux/kernel.h>
  #include <linux/module.h>
- #include <linux/kgdb.h>
- #include <linux/topology.h>
+ #include <linux/percpu.h>
+ #include <linux/string.h>
  #include <linux/delay.h>
+ #include <linux/sched.h>
+ #include <linux/init.h>
+ #include <linux/kgdb.h>
  #include <linux/smp.h>
- #include <linux/percpu.h>
- #include <asm/i387.h>
- #include <asm/msr.h>
- #include <asm/io.h>
- #include <asm/linkage.h>
+ #include <linux/io.h>
+ #include <asm/stackprotector.h>
++#include <asm/perf_counter.h>
  #include <asm/mmu_context.h>
+ #include <asm/hypervisor.h>
+ #include <asm/processor.h>
+ #include <asm/sections.h>
+ #include <asm/topology.h>
+ #include <asm/cpumask.h>
+ #include <asm/pgtable.h>
+ #include <asm/atomic.h>
+ #include <asm/proto.h>
+ #include <asm/setup.h>
+ #include <asm/apic.h>
+ #include <asm/desc.h>
+ #include <asm/i387.h>
  #include <asm/mtrr.h>
+ #include <asm/numa.h>
+ #include <asm/asm.h>
+ #include <asm/cpu.h>
  #include <asm/mce.h>
- #include <asm/perf_counter.h>
+ #include <asm/msr.h>
  #include <asm/pat.h>
- #include <asm/asm.h>
- #include <asm/numa.h>
  #include <asm/smp.h>
- #include <asm/cpu.h>
- #include <asm/cpumask.h>
- #include <asm/apic.h>
  
  #ifdef CONFIG_X86_LOCAL_APIC
  #include <asm/uv/uv.h>
Simple merge
index 7c95c8918a8f9dfbab9bb4b40b103aa73a438ec1,3aaf7b9e3a8bd19405575502a2fbe9faaffba5b2..9c2754302ecce80c01a091354dc0d7ed34110b08
@@@ -55,13 -58,20 +58,24 @@@ static int show_other_interrupts(struc
        for_each_online_cpu(j)
                seq_printf(p, "%10u ", irq_stats(j)->apic_timer_irqs);
        seq_printf(p, "  Local timer interrupts\n");
+       seq_printf(p, "%*s: ", prec, "SPU");
+       for_each_online_cpu(j)
+               seq_printf(p, "%10u ", irq_stats(j)->irq_spurious_count);
+       seq_printf(p, "  Spurious interrupts\n");
 +      seq_printf(p, "CNT: ");
 +      for_each_online_cpu(j)
 +              seq_printf(p, "%10u ", irq_stats(j)->apic_perf_irqs);
 +      seq_printf(p, "  Performance counter interrupts\n");
  #endif
+       if (generic_interrupt_extension) {
+               seq_printf(p, "PLT: ");
+               for_each_online_cpu(j)
+                       seq_printf(p, "%10u ", irq_stats(j)->generic_irqs);
+               seq_printf(p, "  Platform interrupts\n");
+       }
  #ifdef CONFIG_SMP
-       seq_printf(p, "RES: ");
+       seq_printf(p, "%*s: ", prec, "RES");
        for_each_online_cpu(j)
                seq_printf(p, "%10u ", irq_stats(j)->irq_resched_count);
        seq_printf(p, "  Rescheduling interrupts\n");
@@@ -166,8 -165,10 +169,11 @@@ u64 arch_irq_stat_cpu(unsigned int cpu
  
  #ifdef CONFIG_X86_LOCAL_APIC
        sum += irq_stats(cpu)->apic_timer_irqs;
+       sum += irq_stats(cpu)->irq_spurious_count;
 +      sum += irq_stats(cpu)->apic_perf_irqs;
  #endif
+       if (generic_interrupt_extension)
+               sum += irq_stats(cpu)->generic_irqs;
  #ifdef CONFIG_SMP
        sum += irq_stats(cpu)->irq_resched_count;
        sum += irq_stats(cpu)->irq_call_count;
Simple merge
Simple merge
Simple merge
index b7607c4f2042bb5459bd776050bc3ba98d262d50,ff5c8736b491b8ff2c4835c5a19a51ad63633de1..c3ebbb9013792a179d8ab6a43483e6596047cd31
@@@ -332,4 -332,5 +332,6 @@@ ENTRY(sys_call_table
        .long sys_dup3                  /* 330 */
        .long sys_pipe2
        .long sys_inotify_init1
 +      .long sys_perf_counter_open
+       .long sys_preadv
+       .long sys_pwritev
Simple merge
Simple merge
Simple merge
diff --cc fs/exec.c
Simple merge
Simple merge
Simple merge
index 3aee42384f0eb594e3bf52f9227706d9134df65c,b94f3541f67be00802c28f22fa5b56f9e8c91e55..75b2fc5306d8ee13bbc85f3ca68df3fba88295ea
@@@ -68,10 -68,9 +68,10 @@@ struct sched_param 
  #include <linux/smp.h>
  #include <linux/sem.h>
  #include <linux/signal.h>
- #include <linux/fs_struct.h>
+ #include <linux/path.h>
  #include <linux/compiler.h>
  #include <linux/completion.h>
 +#include <linux/perf_counter.h>
  #include <linux/pid.h>
  #include <linux/percpu.h>
  #include <linux/topology.h>
@@@ -137,9 -137,9 +138,11 @@@ extern unsigned long nr_running(void)
  extern unsigned long nr_uninterruptible(void);
  extern unsigned long nr_active(void);
  extern unsigned long nr_iowait(void);
 +extern u64 cpu_nr_switches(int cpu);
 +extern u64 cpu_nr_migrations(int cpu);
  
+ extern unsigned long get_parent_ip(unsigned long addr);
  struct seq_file;
  struct cfs_rq;
  struct task_group;
@@@ -1055,8 -1048,10 +1051,11 @@@ struct sched_entity 
        u64                     last_wakeup;
        u64                     avg_overlap;
  
 -      u64                     nr_migrations;
 +      u64                     nr_migrations;
 +
+       u64                     start_runtime;
+       u64                     avg_wakeup;
  #ifdef CONFIG_SCHEDSTATS
        u64                     wait_start;
        u64                     wait_max;
Simple merge
diff --cc init/Kconfig
Simple merge
diff --cc kernel/Makefile
index 9ef39e5b02110cf2d5a3635a92bac13879b37665,bab1dffe37e94013d19795e33c2754f8ea0222c0..63c697529ca154d80426563e042b8dd28935ae93
@@@ -93,7 -93,7 +93,8 @@@ obj-$(CONFIG_HAVE_GENERIC_DMA_COHERENT
  obj-$(CONFIG_FUNCTION_TRACER) += trace/
  obj-$(CONFIG_TRACING) += trace/
  obj-$(CONFIG_SMP) += sched_cpupri.o
+ obj-$(CONFIG_SLOW_WORK) += slow-work.o
 +obj-$(CONFIG_PERF_COUNTERS) += perf_counter.o
  
  ifneq ($(CONFIG_SCHED_OMIT_FRAME_POINTER),y)
  # According to Alan Modra <alan@linuxcare.com.au>, the -fno-omit-frame-pointer is
diff --cc kernel/exit.c
Simple merge
diff --cc kernel/fork.c
Simple merge
diff --cc kernel/sched.c
index 78f4424b7c43ead77ade690982d3ed01b94b1ff9,bec249885e174c398c5e71aef05194579c9418dc..39e7086021697ddfbea15b4cf5cf6013953c3b08
@@@ -2429,9 -2460,10 +2505,11 @@@ static void __sched_fork(struct task_st
        p->se.exec_start                = 0;
        p->se.sum_exec_runtime          = 0;
        p->se.prev_sum_exec_runtime     = 0;
 +      p->se.nr_migrations             = 0;
        p->se.last_wakeup               = 0;
        p->se.avg_overlap               = 0;
+       p->se.start_runtime             = 0;
+       p->se.avg_wakeup                = sysctl_sched_wakeup_granularity;
  
  #ifdef CONFIG_SCHEDSTATS
        p->se.wait_start                = 0;
@@@ -2650,10 -2690,9 +2736,10 @@@ static void finish_task_switch(struct r
         */
        prev_state = prev->state;
        finish_arch_switch(prev);
 +      perf_counter_task_sched_in(current, cpu_of(rq));
        finish_lock_switch(rq, prev);
  #ifdef CONFIG_SMP
-       if (current->sched_class->post_schedule)
+       if (post_schedule)
                current->sched_class->post_schedule(rq);
  #endif
  
diff --cc kernel/sys.c
Simple merge