aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2020-05-24 19:20:19 -0600
committerJason A. Donenfeld <Jason@zx2c4.com>2020-09-30 16:46:02 +0200
commit8258fd4244740abbf9c9386681dcde960b30a7c3 (patch)
treeab22401eec44ede7c448dd1673b9975b78e613b6
parentworkqueue: remove call to non-existent show_workqueue_state (diff)
downloadrhel7-kernel-misery-8258fd4244740abbf9c9386681dcde960b30a7c3.tar.xz
rhel7-kernel-misery-8258fd4244740abbf9c9386681dcde960b30a7c3.zip
x86: kaiser_enabled isn't always defined
This symbol only exists when CONFIG_PAGE_TABLE_ISOLATION is set, so don't use it otherwise. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
-rw-r--r--arch/x86/kernel/cpu/bugs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/cpu/bugs.c b/arch/x86/kernel/cpu/bugs.c
index eed1e0c03c1..c33396b4a3e 100644
--- a/arch/x86/kernel/cpu/bugs.c
+++ b/arch/x86/kernel/cpu/bugs.c
@@ -1236,8 +1236,10 @@ static ssize_t cpu_show_common(struct device *dev, struct device_attribute *attr
switch (bug) {
case X86_BUG_CPU_MELTDOWN:
+#ifdef CONFIG_PAGE_TABLE_ISOLATION
if (kaiser_enabled)
return sprintf(buf, "Mitigation: PTI\n");
+#endif
break;