lkml.org 
[lkml]   [2022]   [Sep]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 3/3] doc/vm: add information about page_table_check=panic
Date
The default behavior of page table check was changed from panicking
kernel to printing a warning.

Add a note how to still panic the kernel when error is detected.

Signed-off-by: Pasha Tatashin <pasha.tatashin@soleen.com>
---
Documentation/mm/page_table_check.rst | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/Documentation/mm/page_table_check.rst b/Documentation/mm/page_table_check.rst
index 1a09472f10a3..9306cd75647c 100644
--- a/Documentation/mm/page_table_check.rst
+++ b/Documentation/mm/page_table_check.rst
@@ -16,13 +16,13 @@ Page table check performs extra verifications at the time when new pages become
accessible from the userspace by getting their page table entries (PTEs PMDs
etc.) added into the table.

-In case of detected corruption, the kernel is crashed. There is a small
-performance and memory overhead associated with the page table check. Therefore,
-it is disabled by default, but can be optionally enabled on systems where the
-extra hardening outweighs the performance costs. Also, because page table check
-is synchronous, it can help with debugging double map memory corruption issues,
-by crashing kernel at the time wrong mapping occurs instead of later which is
-often the case with memory corruptions bugs.
+In case of detected corruption, a warning is printed or kernel is crashed. There
+is a small performance and memory overhead associated with the page table check.
+Therefore, it is disabled by default, but can be optionally enabled on systems
+where the extra hardening outweighs the performance costs. Also, because page
+table check is synchronous, it can help with debugging double map memory
+corruption issues, by crashing kernel at the time wrong mapping occurs instead
+of later which is often the case with memory corruptions bugs.

Double mapping detection logic
==============================
@@ -52,5 +52,7 @@ Build kernel with:

- Boot with 'page_table_check=on' kernel parameter.

+- Boot with 'page_table_check=panic' in order to panic when error is detected.
+
Optionally, build kernel with PAGE_TABLE_CHECK_ENFORCED in order to have page
table support without extra kernel parameter.
--
2.37.2.789.g6183377224-goog
\
 
 \ /
  Last update: 2022-09-11 12:00    [W:0.488 / U:0.232 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site