linux_dsm_epyc7002/arch/powerpc
Michael Ellerman 92edf8df0f powerpc/security: Fix spectre_v2 reporting
When I updated the spectre_v2 reporting to handle software count cache
flush I got the logic wrong when there's no software count cache
enabled at all.

The result is that on systems with the software count cache flush
disabled we print:

  Mitigation: Indirect branch cache disabled, Software count cache flush

Which correctly indicates that the count cache is disabled, but
incorrectly says the software count cache flush is enabled.

The root of the problem is that we are trying to handle all
combinations of options. But we know now that we only expect to see
the software count cache flush enabled if the other options are false.

So split the two cases, which simplifies the logic and fixes the bug.
We were also missing a space before "(hardware accelerated)".

The result is we see one of:

  Mitigation: Indirect branch serialisation (kernel only)
  Mitigation: Indirect branch cache disabled
  Mitigation: Software count cache flush
  Mitigation: Software count cache flush (hardware accelerated)

Fixes: ee13cb249f ("powerpc/64s: Add support for software count cache flush")
Cc: stable@vger.kernel.org # v4.19+
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Reviewed-by: Michael Neuling <mikey@neuling.org>
Reviewed-by: Diana Craciun <diana.craciun@nxp.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2019-03-21 21:09:03 +11:00
..
boot Kbuild updates for v5.1 2019-03-10 17:48:21 -07:00
configs powerpc fixes for 5.1 #2 2019-03-16 10:45:17 -07:00
crypto
include powerpc/mm: Only define MAX_PHYSMEM_BITS in SPARSEMEM configurations 2019-03-21 00:16:45 +11:00
kernel powerpc/security: Fix spectre_v2 reporting 2019-03-21 21:09:03 +11:00
kvm ARM: some cleanups, direct physical timer assignment, cache sanitization 2019-03-15 15:00:28 -07:00
lib treewide: add checks for the return value of memblock_alloc*() 2019-03-12 10:04:02 -07:00
math-emu
mm powerpc/6xx: fix setup and use of SPRN_SPRG_PGDIR for hash32 2019-03-19 00:30:19 +11:00
net powerpc updates for 5.1 2019-03-07 12:56:26 -08:00
oprofile
perf powerpc updates for 5.1 2019-03-07 12:56:26 -08:00
platforms device-dax for 5.1 2019-03-16 13:05:32 -07:00
purgatory
sysdev treewide: add checks for the return value of memblock_alloc*() 2019-03-12 10:04:02 -07:00
tools
xmon
Kbuild
Kconfig DMA mapping updates for 5.1 2019-03-10 11:54:48 -07:00
Kconfig.debug
Makefile
Makefile.postlink