Revert "hardening: Disable GCC randstruct for COMPILE_TEST"

This reverts commit f5c68a4e84.

It is again possible to build "allmodconfig" with the randstruct GCC
plugin, so enable it for COMPILE_TEST to catch future bugs.

Signed-off-by: Kees Cook <kees@kernel.org>
This commit is contained in:
Kees Cook 2025-04-26 00:37:55 -07:00
parent f55aef7e0c
commit f0cd6012c4
1 changed files with 1 additions and 1 deletions

View File

@ -344,7 +344,7 @@ config CC_HAS_RANDSTRUCT
choice
prompt "Randomize layout of sensitive kernel structures"
default RANDSTRUCT_FULL if COMPILE_TEST && CC_HAS_RANDSTRUCT
default RANDSTRUCT_FULL if COMPILE_TEST && (GCC_PLUGINS || CC_HAS_RANDSTRUCT)
default RANDSTRUCT_NONE
help
If you enable this, the layouts of structures that are entirely