diff options
author | Ingo Molnar <mingo@kernel.org> | 2016-04-13 09:57:03 +0300 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-04-13 09:57:03 +0300 |
commit | 889fac6d67d46a5e781c08fb26fec9016db1c307 (patch) | |
tree | 7e01d04928f7ce343afff5b77ba13c2f3d083326 /include/linux/perf_event.h | |
parent | dad38ca64a252144b4ccdfe9730a3fe2b7c61957 (diff) | |
parent | bf16200689118d19de1b8d2a3c314fc21f5dc7bb (diff) | |
download | linux-889fac6d67d46a5e781c08fb26fec9016db1c307.tar.xz |
Merge tag 'v4.6-rc3' into perf/core, to refresh the tree
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/perf_event.h')
-rw-r--r-- | include/linux/perf_event.h | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index 4065ca2d7149..b8b195fbe787 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h @@ -977,11 +977,20 @@ DECLARE_PER_CPU(struct perf_callchain_entry, perf_callchain_entry); extern void perf_callchain_user(struct perf_callchain_entry *entry, struct pt_regs *regs); extern void perf_callchain_kernel(struct perf_callchain_entry *entry, struct pt_regs *regs); +extern struct perf_callchain_entry * +get_perf_callchain(struct pt_regs *regs, u32 init_nr, bool kernel, bool user, + bool crosstask, bool add_mark); +extern int get_callchain_buffers(void); +extern void put_callchain_buffers(void); -static inline void perf_callchain_store(struct perf_callchain_entry *entry, u64 ip) +static inline int perf_callchain_store(struct perf_callchain_entry *entry, u64 ip) { - if (entry->nr < PERF_MAX_STACK_DEPTH) + if (entry->nr < PERF_MAX_STACK_DEPTH) { entry->ip[entry->nr++] = ip; + return 0; + } else { + return -1; /* no more room, stop walking the stack */ + } } extern int sysctl_perf_event_paranoid; |