diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-07-09 13:49:47 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-07-09 13:49:47 -0400 |
commit | c3931a87db9e840dc20f3b962668d477eaeb2f75 (patch) | |
tree | bf92c17ec96ed25b3407435b28be9da2110475bc /tools/perf | |
parent | c8b2ba83fb01336f094226895087b644df0ec397 (diff) | |
parent | dbf580623d5fee785218d1a47a2bcdf36d85c0e9 (diff) |
Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull perf fixes from Thomas Gleixner:
"A couple of fixes for perf and kprobes:
- Add he missing exclude_kernel attribute for the precise_ip level so
!CAP_SYS_ADMIN users get the proper results.
- Warn instead of failing completely when perf has no unwind support
for a particular architectiure built in.
- Ensure that jprobes are at function entry and not at some random
place"
* 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
kprobes: Ensure that jprobe probepoints are at function entry
kprobes: Simplify register_jprobes()
kprobes: Rename [arch_]function_offset_within_entry() to [arch_]kprobe_on_func_entry()
perf unwind: Do not fail due to missing unwind support
perf evsel: Set attr.exclude_kernel when probing max attr.precise_ip
Diffstat (limited to 'tools/perf')
-rw-r--r-- | tools/perf/util/evsel.c | 1 | ||||
-rw-r--r-- | tools/perf/util/unwind-libunwind.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index 6f4882f8d61f..87b431886670 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c | |||
@@ -273,6 +273,7 @@ struct perf_evsel *perf_evsel__new_cycles(void) | |||
273 | struct perf_event_attr attr = { | 273 | struct perf_event_attr attr = { |
274 | .type = PERF_TYPE_HARDWARE, | 274 | .type = PERF_TYPE_HARDWARE, |
275 | .config = PERF_COUNT_HW_CPU_CYCLES, | 275 | .config = PERF_COUNT_HW_CPU_CYCLES, |
276 | .exclude_kernel = 1, | ||
276 | }; | 277 | }; |
277 | struct perf_evsel *evsel; | 278 | struct perf_evsel *evsel; |
278 | 279 | ||
diff --git a/tools/perf/util/unwind-libunwind.c b/tools/perf/util/unwind-libunwind.c index 6d542a4e0648..8aef572d0889 100644 --- a/tools/perf/util/unwind-libunwind.c +++ b/tools/perf/util/unwind-libunwind.c | |||
@@ -50,7 +50,7 @@ int unwind__prepare_access(struct thread *thread, struct map *map, | |||
50 | 50 | ||
51 | if (!ops) { | 51 | if (!ops) { |
52 | pr_err("unwind: target platform=%s is not supported\n", arch); | 52 | pr_err("unwind: target platform=%s is not supported\n", arch); |
53 | return -1; | 53 | return 0; |
54 | } | 54 | } |
55 | out_register: | 55 | out_register: |
56 | unwind__register_ops(thread, ops); | 56 | unwind__register_ops(thread, ops); |