perf: Drop useless check for ignored frame
authorFrederic Weisbecker <fweisbec@gmail.com>
Thu, 31 Dec 2009 04:53:03 +0000 (05:53 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 13 Jan 2010 09:09:08 +0000 (10:09 +0100)
The check that ignores the debug and nmi stack frames is useless
now that we have a frame pointer that makes us start at the
right place. We don't anymore have to deal with these.

Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <1262235183-5320-2-git-send-regression-fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/include/asm/stacktrace.h
arch/x86/kernel/cpu/perf_event.c
arch/x86/kernel/dumpstack_32.c
arch/x86/kernel/dumpstack_64.c

index 35e89122a42f53191bdce81156417b305fe005ac..4dab78edbad9ff7315a8c30aebeb734f4e87da1e 100644 (file)
@@ -3,8 +3,6 @@
 
 extern int kstack_depth_to_print;
 
-int x86_is_stack_id(int id, char *name);
-
 struct thread_info;
 struct stacktrace_ops;
 
index d616c06e99b4098f9836b28ecd200194bfcd1445..b1bb8c550526ac36a8e1af514cf3ca74d7dc6c69 100644 (file)
@@ -2297,7 +2297,6 @@ void callchain_store(struct perf_callchain_entry *entry, u64 ip)
 
 static DEFINE_PER_CPU(struct perf_callchain_entry, pmc_irq_entry);
 static DEFINE_PER_CPU(struct perf_callchain_entry, pmc_nmi_entry);
-static DEFINE_PER_CPU(int, in_ignored_frame);
 
 
 static void
@@ -2313,10 +2312,6 @@ static void backtrace_warning(void *data, char *msg)
 
 static int backtrace_stack(void *data, char *name)
 {
-       per_cpu(in_ignored_frame, smp_processor_id()) =
-                       x86_is_stack_id(NMI_STACK, name) ||
-                       x86_is_stack_id(DEBUG_STACK, name);
-
        return 0;
 }
 
@@ -2324,9 +2319,6 @@ static void backtrace_address(void *data, unsigned long addr, int reliable)
 {
        struct perf_callchain_entry *entry = data;
 
-       if (per_cpu(in_ignored_frame, smp_processor_id()))
-               return;
-
        if (reliable)
                callchain_store(entry, addr);
 }
index ae775ca47b25c463fb8688cd4e47a92efa6a1a1e..11540a189d9311e6a0fb4c44e685fc82799fdd0e 100644 (file)
 
 #include "dumpstack.h"
 
-/* Just a stub for now */
-int x86_is_stack_id(int id, char *name)
-{
-       return 0;
-}
 
 void dump_trace(struct task_struct *task, struct pt_regs *regs,
                unsigned long *stack, unsigned long bp,
index 0ad9597073f5a53aabb5f3dbbd85ea4cae947d60..676bc051252e7729bb0918d7607a837a56484e4f 100644 (file)
@@ -33,11 +33,6 @@ static char x86_stack_ids[][8] = {
 #endif
 };
 
-int x86_is_stack_id(int id, char *name)
-{
-       return x86_stack_ids[id - 1] == name;
-}
-
 static unsigned long *in_exception_stack(unsigned cpu, unsigned long stack,
                                         unsigned *usedp, char **idp)
 {