aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/cpu
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-07-10 17:25:03 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-07-10 17:25:03 -0400
commit85be928c4101670f99cdd7c927798aa4dcbb3168 (patch)
tree91befa19ca6da9edf74040bd1fd0cf68ab0cea4c /arch/x86/kernel/cpu
parentd86ee4809d0329d4aa0d0f2c76c2295a16862799 (diff)
parent805d127d62472f17c7d79baa001a7651afe2fa47 (diff)
Merge branch 'perfcounters-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'perfcounters-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (50 commits) perf report: Add "Fractal" mode output - support callchains with relative overhead rate perf_counter tools: callchains: Manage the cumul hits on the fly perf report: Change default callchain parameters perf report: Use a modifiable string for default callchain options perf report: Warn on callchain output request from non-callchain file x86: atomic64: Inline atomic64_read() again x86: atomic64: Clean up atomic64_sub_and_test() and atomic64_add_negative() x86: atomic64: Improve atomic64_xchg() x86: atomic64: Export APIs to modules x86: atomic64: Improve atomic64_read() x86: atomic64: Code atomic(64)_read and atomic(64)_set in C not CPP x86: atomic64: Fix unclean type use in atomic64_xchg() x86: atomic64: Make atomic_read() type-safe x86: atomic64: Reduce size of functions x86: atomic64: Improve atomic64_add_return() x86: atomic64: Improve cmpxchg8b() x86: atomic64: Improve atomic64_read() x86: atomic64: Move the 32-bit atomic64_t implementation to a .c file x86: atomic64: The atomic64_t data type should be 8 bytes aligned on 32-bit too perf report: Annotate variable initialization ...
Diffstat (limited to 'arch/x86/kernel/cpu')
-rw-r--r--arch/x86/kernel/cpu/perf_counter.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/x86/kernel/cpu/perf_counter.c b/arch/x86/kernel/cpu/perf_counter.c
index d4cf4ce19aac..36c3dc7b8991 100644
--- a/arch/x86/kernel/cpu/perf_counter.c
+++ b/arch/x86/kernel/cpu/perf_counter.c
@@ -1561,6 +1561,7 @@ void callchain_store(struct perf_callchain_entry *entry, u64 ip)
1561 1561
1562static DEFINE_PER_CPU(struct perf_callchain_entry, irq_entry); 1562static DEFINE_PER_CPU(struct perf_callchain_entry, irq_entry);
1563static DEFINE_PER_CPU(struct perf_callchain_entry, nmi_entry); 1563static DEFINE_PER_CPU(struct perf_callchain_entry, nmi_entry);
1564static DEFINE_PER_CPU(int, in_nmi_frame);
1564 1565
1565 1566
1566static void 1567static void
@@ -1576,7 +1577,9 @@ static void backtrace_warning(void *data, char *msg)
1576 1577
1577static int backtrace_stack(void *data, char *name) 1578static int backtrace_stack(void *data, char *name)
1578{ 1579{
1579 /* Process all stacks: */ 1580 per_cpu(in_nmi_frame, smp_processor_id()) =
1581 x86_is_stack_id(NMI_STACK, name);
1582
1580 return 0; 1583 return 0;
1581} 1584}
1582 1585
@@ -1584,6 +1587,9 @@ static void backtrace_address(void *data, unsigned long addr, int reliable)
1584{ 1587{
1585 struct perf_callchain_entry *entry = data; 1588 struct perf_callchain_entry *entry = data;
1586 1589
1590 if (per_cpu(in_nmi_frame, smp_processor_id()))
1591 return;
1592
1587 if (reliable) 1593 if (reliable)
1588 callchain_store(entry, addr); 1594 callchain_store(entry, addr);
1589} 1595}