aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDiana Craciun <diana.craciun@nxp.com>2018-07-28 09:06:33 +1000
committerMichael Ellerman <mpe@ellerman.id.au>2018-08-08 00:32:18 +1000
commit6453b532f2c8856a80381e6b9a1f5ea2f12294df (patch)
treeb177abeae6f62da7a7c561225addd064dc97e187
parentpowerpc/64: Disable the speculation barrier from the command line (diff)
downloadlinux-dev-6453b532f2c8856a80381e6b9a1f5ea2f12294df.tar.xz
linux-dev-6453b532f2c8856a80381e6b9a1f5ea2f12294df.zip
powerpc/64: Make stf barrier PPC_BOOK3S_64 specific.
NXP Book3E platforms are not vulnerable to speculative store bypass, so make the mitigations PPC_BOOK3S_64 specific. Signed-off-by: Diana Craciun <diana.craciun@nxp.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-rw-r--r--arch/powerpc/kernel/security.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/security.c b/arch/powerpc/kernel/security.c
index 79f9397998ed..8ee1ade845c6 100644
--- a/arch/powerpc/kernel/security.c
+++ b/arch/powerpc/kernel/security.c
@@ -176,6 +176,7 @@ ssize_t cpu_show_spectre_v2(struct device *dev, struct device_attribute *attr, c
return s.len;
}
+#ifdef CONFIG_PPC_BOOK3S_64
/*
* Store-forwarding barrier support.
*/
@@ -323,3 +324,4 @@ static __init int stf_barrier_debugfs_init(void)
}
device_initcall(stf_barrier_debugfs_init);
#endif /* CONFIG_DEBUG_FS */
+#endif /* CONFIG_PPC_BOOK3S_64 */