regresion v5.13-rc1+ - page_poison broken since 51cba1ebc60d

From: Dominik Brodowski <linux@dominikbrodowski.net>
Date: 2021-06-08 16:52:25
Also in: linux-hardening

Hi Kees, Andrey,

a "git bisect" points to commit 51cba1ebc60d ("init_on_alloc: Optimize
static branches") as breaking page poisoning ("page_poison=on"). Starting
with this commit, booting -- with this option enabled on the kernel command
line -- hangs quite early, before anything meaningful is printed. Booting
51cba1ebc60d without this option proceeds just fine.

Since 1bb5eab30d68 ("kasan, mm: integrate page_alloc init with HW_TAGS") the
behaviour becomes different: Since that commit, booting with
"page_poison=on" and "slub_debug=P" continues up to the initramfs
stage, but then fails quite spectacularly with a large number of page
poisonings being reported.

While "page_poision=on slub_debug=P" doesn't seem to be necessary any longer
if CONFIG_INIT_ON_ALLOC_DEFAULT_ON and CONFIG_INIT_ON_FREE_DEFAULT_ON are
enabled[*], this still looks like a regression.

Thanks,
	Dominik

[*] https://kernsec.org/wiki/index.php/Kernel_Self_Protection_Project/Recommended_Settings
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help