summaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorBrendan Higgins <brendanhiggins@google.com>2019-12-12 16:35:22 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-01-14 15:41:04 +0100
commit0e31e3573f0cd94d7b821117db854187ffc85765 (patch)
tree92e9ee1778e4e62a056e0fef5862b9753858885c /Documentation
parentcea23efb4de2d31e72a576026b213e15d6792976 (diff)
downloadlinux-0e31e3573f0cd94d7b821117db854187ffc85765.tar.bz2
lkdtm/bugs: fix build error in lkdtm_UNSET_SMEP
When building ARCH=um with CONFIG_UML_X86=y and CONFIG_64BIT=y we get the build errors: drivers/misc/lkdtm/bugs.c: In function ‘lkdtm_UNSET_SMEP’: drivers/misc/lkdtm/bugs.c:288:8: error: implicit declaration of function ‘native_read_cr4’ [-Werror=implicit-function-declaration] cr4 = native_read_cr4(); ^~~~~~~~~~~~~~~ drivers/misc/lkdtm/bugs.c:290:13: error: ‘X86_CR4_SMEP’ undeclared (first use in this function); did you mean ‘X86_FEATURE_SMEP’? if ((cr4 & X86_CR4_SMEP) != X86_CR4_SMEP) { ^~~~~~~~~~~~ X86_FEATURE_SMEP drivers/misc/lkdtm/bugs.c:290:13: note: each undeclared identifier is reported only once for each function it appears in drivers/misc/lkdtm/bugs.c:297:2: error: implicit declaration of function ‘native_write_cr4’; did you mean ‘direct_write_cr4’? [-Werror=implicit-function-declaration] native_write_cr4(cr4); ^~~~~~~~~~~~~~~~ direct_write_cr4 So specify that this block of code should only build when CONFIG_X86_64=y *AND* CONFIG_UML is unset. Signed-off-by: Brendan Higgins <brendanhiggins@google.com> Acked-by: Kees Cook <keescook@chromium.org> Link: https://lore.kernel.org/r/20191213003522.66450-1-brendanhiggins@google.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation')
0 files changed, 0 insertions, 0 deletions