From: Peter Zijlstra <peterz@infradead.org>
To: Andrey Ryabinin <aryabinin@virtuozzo.com>,
Alexander Potapenko <glider@google.com>,
Dmitry Vyukov <dvyukov@google.com>,
linux-kernel@vger.kernel.org
Cc: Steven Rostedt <rostedt@goodmis.org>
Subject: Re: [PATCH] kasan: Respect /proc/sys/kernel/traceoff_on_warning
Date: Wed, 25 Jan 2017 15:28:52 +0100 [thread overview]
Message-ID: <20170125142852.GE6536@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <20170125142524.GQ6515@twins.programming.kicks-ass.net>
On Wed, Jan 25, 2017 at 03:25:24PM +0100, Peter Zijlstra wrote:
>
> After much waiting I finally reproduced a KASAN issue, only to find my
> trace-buffer empty of useful information because it got spooled out :/
>
> Make kasan_report honour the /proc/sys/kernel/traceoff_on_warning
> interface.
>
> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
> ---
Seems to compile better when you add the required header files...
mm/kasan/report.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/mm/kasan/report.c b/mm/kasan/report.c
index b82b3e2..3653ed1 100644
--- a/mm/kasan/report.c
+++ b/mm/kasan/report.c
@@ -24,6 +24,7 @@
#include <linux/types.h>
#include <linux/kasan.h>
#include <linux/module.h>
+#include <linux/ftrace.h>
#include <asm/sections.h>
@@ -300,6 +301,8 @@ void kasan_report(unsigned long addr, size_t size,
if (likely(!kasan_report_enabled()))
return;
+ disable_trace_on_warning();
+
info.access_addr = (void *)addr;
info.access_size = size;
info.is_write = is_write;
next prev parent reply other threads:[~2017-01-25 14:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-25 14:25 Peter Zijlstra
2017-01-25 14:28 ` Peter Zijlstra [this message]
2017-01-25 14:32 ` Alexander Potapenko
2017-01-25 14:35 ` Peter Zijlstra
2017-01-25 14:37 ` Alexander Potapenko
2017-01-30 19:18 ` Steven Rostedt
2017-01-25 14:38 ` Alexander Potapenko
2017-01-25 15:29 ` kbuild test robot
2017-01-25 16:41 ` [PATCH v2] " Andrey Ryabinin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170125142852.GE6536@twins.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=aryabinin@virtuozzo.com \
--cc=dvyukov@google.com \
--cc=glider@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome