ARM: spectre: add Kconfig symbol for CPUs vulnerable to Spectre
authorRussell King <rmk+kernel@armlinux.org.uk>
Mon, 14 May 2018 10:56:36 +0000 (11:56 +0100)
committerRussell King <rmk+kernel@armlinux.org.uk>
Thu, 31 May 2018 09:39:51 +0000 (10:39 +0100)
Add a Kconfig symbol for CPUs which are vulnerable to the Spectre
attacks.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Boot-tested-by: Tony Lindgren <tony@atomide.com>
Reviewed-by: Tony Lindgren <tony@atomide.com>
Acked-by: Marc Zyngier <marc.zyngier@arm.com>
arch/arm/mm/Kconfig

index 7f14acf67caff57b2daf8cca2b97f28d120d8532..6f3ef86b4cb71d4d3ea8803da081c11921ee76b3 100644 (file)
@@ -415,6 +415,7 @@ config CPU_V7
        select CPU_CP15_MPU if !MMU
        select CPU_HAS_ASID if MMU
        select CPU_PABRT_V7
+       select CPU_SPECTRE if MMU
        select CPU_THUMB_CAPABLE
        select CPU_TLB_V7 if MMU
 
@@ -826,6 +827,9 @@ config CPU_BPREDICT_DISABLE
        help
          Say Y here to disable branch prediction.  If unsure, say N.
 
+config CPU_SPECTRE
+       bool
+
 config TLS_REG_EMUL
        bool
        select NEED_KUSER_HELPERS