aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/event.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-12-14 13:13:22 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-14 13:13:22 -0500
commit2205afa7d13ec716935dfd4b8ff71059ee7aeb0c (patch)
tree19e63ed8040e8a82c3cdd331458d246247466a28 /tools/perf/util/event.c
parent491424c0f46c282a854b88830212bdb0763e93dc (diff)
parent2cd9046cc53dd2625e2cf5854d6cbb1ba61de914 (diff)
Merge branch 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: perf sched: Fix build failure on sparc perf bench: Add "all" pseudo subsystem and "all" pseudo suite perf tools: Introduce perf_session class perf symbols: Ditch dso->find_symbol perf symbols: Allow lookups by symbol name too perf symbols: Add missing "Variables" entry to map_type__name perf symbols: Add support for 'variable' symtabs perf symbols: Introduce ELF counterparts to symbol_type__is_a perf symbols: Introduce symbol_type__is_a perf symbols: Rename kthreads to kmaps, using another abstraction for it perf tools: Allow building for ARM hw-breakpoints: Handle bad modify_user_hw_breakpoint off-case return value perf tools: Allow cross compiling tracing, slab: Fix no callsite ifndef CONFIG_KMEMTRACE tracing, slab: Define kmem_cache_alloc_notrace ifdef CONFIG_TRACING Trivial conflict due to different fixes to modify_user_hw_breakpoint() in include/linux/hw_breakpoint.h
Diffstat (limited to 'tools/perf/util/event.c')
-rw-r--r--tools/perf/util/event.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/tools/perf/util/event.c b/tools/perf/util/event.c
index 4dcecafa85dc..ba0de90cd3d4 100644
--- a/tools/perf/util/event.c
+++ b/tools/perf/util/event.c
@@ -254,13 +254,14 @@ void thread__find_addr_location(struct thread *self, u8 cpumode,
254 struct addr_location *al, 254 struct addr_location *al,
255 symbol_filter_t filter) 255 symbol_filter_t filter)
256{ 256{
257 struct thread *thread = al->thread = self; 257 struct map_groups *mg = &self->mg;
258 258
259 al->thread = self;
259 al->addr = addr; 260 al->addr = addr;
260 261
261 if (cpumode & PERF_RECORD_MISC_KERNEL) { 262 if (cpumode & PERF_RECORD_MISC_KERNEL) {
262 al->level = 'k'; 263 al->level = 'k';
263 thread = kthread; 264 mg = kmaps;
264 } else if (cpumode & PERF_RECORD_MISC_USER) 265 } else if (cpumode & PERF_RECORD_MISC_USER)
265 al->level = '.'; 266 al->level = '.';
266 else { 267 else {
@@ -270,7 +271,7 @@ void thread__find_addr_location(struct thread *self, u8 cpumode,
270 return; 271 return;
271 } 272 }
272try_again: 273try_again:
273 al->map = thread__find_map(thread, type, al->addr); 274 al->map = map_groups__find(mg, type, al->addr);
274 if (al->map == NULL) { 275 if (al->map == NULL) {
275 /* 276 /*
276 * If this is outside of all known maps, and is a negative 277 * If this is outside of all known maps, and is a negative
@@ -281,8 +282,8 @@ try_again:
281 * "[vdso]" dso, but for now lets use the old trick of looking 282 * "[vdso]" dso, but for now lets use the old trick of looking
282 * in the whole kernel symbol list. 283 * in the whole kernel symbol list.
283 */ 284 */
284 if ((long long)al->addr < 0 && thread != kthread) { 285 if ((long long)al->addr < 0 && mg != kmaps) {
285 thread = kthread; 286 mg = kmaps;
286 goto try_again; 287 goto try_again;
287 } 288 }
288 al->sym = NULL; 289 al->sym = NULL;