[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-019e579d395733d14097c2d29c8c43226dad1617@git.kernel.org>
Date: Thu, 8 Sep 2016 02:48:16 -0700
From: tip-bot for Josh Poimboeuf <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: keescook@...omium.org, peterz@...radead.org, tglx@...utronix.de,
luto@...capital.net, rostedt@...dmis.org, brgerst@...il.com,
hpa@...or.com, linux-kernel@...r.kernel.org, nilayvaish@...il.com,
jpoimboe@...hat.com, mingo@...nel.org,
torvalds@...ux-foundation.org, byungchul.park@....com,
fweisbec@...il.com
Subject: [tip:x86/asm] perf/x86: Check perf_callchain_store() error
Commit-ID: 019e579d395733d14097c2d29c8c43226dad1617
Gitweb: http://git.kernel.org/tip/019e579d395733d14097c2d29c8c43226dad1617
Author: Josh Poimboeuf <jpoimboe@...hat.com>
AuthorDate: Wed, 24 Aug 2016 11:50:14 -0500
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Thu, 8 Sep 2016 08:58:40 +0200
perf/x86: Check perf_callchain_store() error
Add a check to perf_callchain_kernel() so that it returns early if the
callchain entry array is already full.
Signed-off-by: Josh Poimboeuf <jpoimboe@...hat.com>
Cc: Andy Lutomirski <luto@...capital.net>
Cc: Brian Gerst <brgerst@...il.com>
Cc: Byungchul Park <byungchul.park@....com>
Cc: Frederic Weisbecker <fweisbec@...il.com>
Cc: Kees Cook <keescook@...omium.org>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Nilay Vaish <nilayvaish@...il.com>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Steven Rostedt <rostedt@...dmis.org>
Cc: Thomas Gleixner <tglx@...utronix.de>
Link: http://lkml.kernel.org/r/dce6d60bab08be2600efd90021d9b85620646161.1472057064.git.jpoimboe@redhat.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
arch/x86/events/core.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/arch/x86/events/core.c b/arch/x86/events/core.c
index d0efb5c..c1319ac 100644
--- a/arch/x86/events/core.c
+++ b/arch/x86/events/core.c
@@ -2277,7 +2277,8 @@ perf_callchain_kernel(struct perf_callchain_entry_ctx *entry, struct pt_regs *re
return;
}
- perf_callchain_store(entry, regs->ip);
+ if (perf_callchain_store(entry, regs->ip))
+ return;
dump_trace(NULL, regs, NULL, 0, &backtrace_ops, entry);
}
Powered by blists - more mailing lists