sparse doesn't support struct randomization
PATCH 6/6 sparse doesn't support struct randomization
From: Matthew Wilcox <[email protected]>
Subject: sparse doesn't support struct randomization
Without this patch, I drown in a sea of unknown attribute warnings
Signed-off-by Matthew Wilcox <[email protected]>
Acked-by Kees Cook <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc Josh Poimboeuf <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
include/linux/compiler-gcc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/compiler-gcc.h renamed from include/linux/compiler-gcc.h~sparse-doesnt-support-struct-randomization +1 -1
@@ -219,7 +219,7 @@/* Mark a function definition as prohibited from being cloned. */ #define __noclone __attribute__((__noclone__, __optimize__("no-tracer"))) -#ifdef RANDSTRUCT_PLUGIN +#if defined(RANDSTRUCT_PLUGIN ) && !defined(__CHECKER__)#define __randomize_layout __attribute__((randomize_layout))#define __no_randomize_layout __attribute__((no_randomize_layout))#endif
_