summaryrefslogtreecommitdiff
path: root/Documentation/dev-tools
diff options
context:
space:
mode:
authorMarco Elver <elver@google.com>2026-02-25 21:36:05 +0100
committerAndrew Morton <akpm@linux-foundation.org>2026-04-05 13:53:06 -0700
commitda735962d05c4e7ffc68e02c0cb2459f837a0f51 (patch)
treecf2cf9bc66483ab9a557a710d876c56ee0659e09 /Documentation/dev-tools
parent3efb9800557b855b493dc98d22c5e57974ac1593 (diff)
downloadlwn-da735962d05c4e7ffc68e02c0cb2459f837a0f51.tar.gz
lwn-da735962d05c4e7ffc68e02c0cb2459f837a0f51.zip
kfence: add kfence.fault parameter
Add kfence.fault parameter to control the behavior when a KFENCE error is detected (similar in spirit to kasan.fault=<mode>). The supported modes for kfence.fault=<mode> are: - report: print the error report and continue (default). - oops: print the error report and oops. - panic: print the error report and panic. In particular, the 'oops' mode offers a trade-off between no mitigation on report and panicking outright (if panic_on_oops is not set). Link: https://lkml.kernel.org/r/20260225203639.3159463-1-elver@google.com Signed-off-by: Marco Elver <elver@google.com> Reviewed-by: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Kees Cook <kees@kernel.org> Cc: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'Documentation/dev-tools')
-rw-r--r--Documentation/dev-tools/kfence.rst7
1 files changed, 7 insertions, 0 deletions
diff --git a/Documentation/dev-tools/kfence.rst b/Documentation/dev-tools/kfence.rst
index 541899353865..b03d1201ddae 100644
--- a/Documentation/dev-tools/kfence.rst
+++ b/Documentation/dev-tools/kfence.rst
@@ -81,6 +81,13 @@ tables being allocated.
Error reports
~~~~~~~~~~~~~
+The boot parameter ``kfence.fault`` can be used to control the behavior when a
+KFENCE error is detected:
+
+- ``kfence.fault=report``: Print the error report and continue (default).
+- ``kfence.fault=oops``: Print the error report and oops.
+- ``kfence.fault=panic``: Print the error report and panic.
+
A typical out-of-bounds access looks like this::
==================================================================