[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20221205072221.63e14cfb08531fc418ab6d1d@kernel.org>
Date: Mon, 5 Dec 2022 07:22:21 +0900
From: Masami Hiramatsu (Google) <mhiramat@...nel.org>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: LKML <linux-kernel@...r.kernel.org>, bpf@...r.kernel.org,
Borislav Petkov <bp@...en8.de>,
Alexei Starovoitov <alexei.starovoitov@...il.com>,
Steven Rostedt <rostedt@...dmis.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Peter Zijlstra <peterz@...radead.org>,
Kees Cook <keescook@...omium.org>,
Josh Poimboeuf <jpoimboe@...hat.com>,
KP Singh <kpsingh@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Florent Revest <revest@...omium.org>,
Christoph Hellwig <hch@...radead.org>,
Chris Mason <clm@...a.com>
Subject: Re: [PATCH] panic: Taint kernel if fault injection has been used
On Fri, 2 Dec 2022 07:33:11 +0100
Greg Kroah-Hartman <gregkh@...uxfoundation.org> wrote:
> On Fri, Dec 02, 2022 at 01:45:59PM +0900, Masami Hiramatsu (Google) wrote:
> > From: Masami Hiramatsu (Google) <mhiramat@...nel.org>
> >
> > Since the function error injection framework in the fault injection
> > subsystem can change the function code flow forcibly, it may cause
> > unexpected behavior (and that is the purpose of this feature) even
> > if it is applied to the ALLOW_ERROR_INJECTION functions.
> > So this feature must be used only for debugging or testing purpose.
> >
> > To identify this in the kernel oops message, add a new taint flag
> > for the fault injection. This taint flag will be set by either
> > function error injection is used or the BPF use the kprobe_override
> > on error injectable functions (identified by ALLOW_ERROR_INJECTION).
> >
> > Link: https://lore.kernel.org/all/20221121104403.1545f9b5@gandalf.local.home/T/#u
> >
> > Signed-off-by: Masami Hiramatsu (Google) <mhiramat@...nel.org>
> > ---
> > Documentation/admin-guide/tainted-kernels.rst | 5 +++++
> > include/linux/panic.h | 3 ++-
> > kernel/fail_function.c | 2 ++
> > kernel/panic.c | 1 +
> > kernel/trace/bpf_trace.c | 2 ++
> > 5 files changed, 12 insertions(+), 1 deletion(-)
>
> I think you forgot to also update tools/debugging/kernel-chktaint with
> this new entry :(
Oops, thanks for pointing!
Let me update the patch.
--
Masami Hiramatsu (Google) <mhiramat@...nel.org>
Powered by blists - more mailing lists