[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151005163906.GE26924@tassilo.jf.intel.com>
Date: Mon, 5 Oct 2015 09:39:06 -0700
From: Andi Kleen <ak@...ux.intel.com>
To: Andrey Ryabinin <aryabinin@...tuozzo.com>
Cc: Dmitry Vyukov <dvyukov@...gle.com>, Ingo Molnar <mingo@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>,
"x86@...nel.org" <x86@...nel.org>,
LKML <linux-kernel@...r.kernel.org>,
Andy Lutomirski <luto@...capital.net>,
Andrey Konovalov <andreyknvl@...gle.com>,
Kostya Serebryany <kcc@...gle.com>,
Alexander Potapenko <glider@...gle.com>,
kasan-dev <kasan-dev@...glegroups.com>,
Borislav Petkov <bp@...en8.de>,
Denys Vlasenko <dvlasenk@...hat.com>,
Sasha Levin <sasha.levin@...cle.com>,
Wolfram Gloger <wmglo@...t.med.uni-muenchen.de>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH] x86/process: Silence KASAN warnings in get_wchan()
> But, I think I have the solution.
> We could have some blacklist - list of function names which we should be ignored.
> In kasan_report() we could resolve return address to function name and compare it with name in list.
> If name in list -> ignore report.
I think annotating statements is cleaner than functions, even if it
is more code. Much better documentation
But if you really want to annotate on the function level:
It's better to annotate the function directly than some hidden away list.
This way there is some indication that there are races in there, which is
generally useful documentation.
__racy_function or similar.
Also central lists are generally annoying as they cause patch conflicts.
If disabling with an attribute doesn't work, you could put it into a special section
with __attribute__((section ...)) and check the start/end symbol before reporting.
That's how kprobes solves similar issues. It also has the advantage
that it stops inlining.
-Andi
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists