mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 05:31:08 -04:00
perf core: Add perf_callchain_store_context() helper
We need have different helpers to account how many contexts we have in the sample and for real addresses, so do it now as a prep patch, to ease review. Cc: David Ahern <[email protected]> Cc: Frederic Weisbecker <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Peter Zijlstra <[email protected]> Link: http://lkml.kernel.org/n/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
This commit is contained in:
1 parent
3b1fff0803
commit
3e4de4ec4c
3 files changed
+7
-5
No files matched your search
@@ -1079,6 +1079,8 @@ extern void put_callchain_buffers(void);
|
||||
|
||||
extern int sysctl_perf_event_max_stack;
|
||||
|
||||
#define perf_callchain_store_context(ctx, context) perf_callchain_store(ctx, context)
|
||||
|
||||
static inline int perf_callchain_store(struct perf_callchain_entry_ctx *ctx, u64 ip)
|
||||
{
|
||||
if (ctx->nr < ctx->max_stack) {
|
||||
|
||||
Reference in new issue
Block a user