From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: "Masami Hiramatsu (Google)" <mhiramat@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
bpf@vger.kernel.org, Borislav Petkov <bp@alien8.de>,
Alexei Starovoitov <alexei.starovoitov@gmail.com>,
Steven Rostedt <rostedt@goodmis.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>,
Peter Zijlstra <peterz@infradead.org>,
Kees Cook <keescook@chromium.org>,
Josh Poimboeuf <jpoimboe@redhat.com>,
KP Singh <kpsingh@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Florent Revest <revest@chromium.org>,
Christoph Hellwig <hch@infradead.org>, Chris Mason <clm@meta.com>
Subject: Re: [PATCH] panic: Taint kernel if fault injection has been used
Date: Fri, 2 Dec 2022 07:33:11 +0100 [thread overview]
Message-ID: <Y4mcJ61TPBgvBEWr@kroah.com> (raw)
In-Reply-To: <166995635931.455067.17768077948832448089.stgit@devnote3>
On Fri, Dec 02, 2022 at 01:45:59PM +0900, Masami Hiramatsu (Google) wrote:
> From: Masami Hiramatsu (Google) <mhiramat@kernel.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@kernel.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 :(
next prev parent reply other threads:[~2022-12-02 6:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-02 4:45 [PATCH] panic: Taint kernel if fault injection has been used Masami Hiramatsu (Google)
2022-12-02 6:33 ` Greg Kroah-Hartman [this message]
2022-12-04 22:22 ` Masami Hiramatsu
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=Y4mcJ61TPBgvBEWr@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=akpm@linux-foundation.org \
--cc=alexei.starovoitov@gmail.com \
--cc=bp@alien8.de \
--cc=bpf@vger.kernel.org \
--cc=clm@meta.com \
--cc=hch@infradead.org \
--cc=jpoimboe@redhat.com \
--cc=keescook@chromium.org \
--cc=kpsingh@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mhiramat@kernel.org \
--cc=peterz@infradead.org \
--cc=revest@chromium.org \
--cc=rostedt@goodmis.org \
--cc=torvalds@linux-foundation.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