selftests/powerpc: spectre_v2 test must be built 64-bit
authorMichael Ellerman <mpe@ellerman.id.au>
Wed, 20 Nov 2019 02:37:23 +0000 (13:37 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 21 Nov 2019 04:41:39 +0000 (15:41 +1100)
The spectre_v2 test must be built 64-bit, it includes hand-written asm
that is 64-bit only, and segfaults if built 32-bit.

Fixes: c790c3d2b0ec ("selftests/powerpc: Add a test of spectre_v2 mitigations")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20191120023924.13130-1-mpe@ellerman.id.au
tools/testing/selftests/powerpc/security/Makefile

index d68e6031695c40480f13c049bdcf1cec827a58e7..eadbbff50be6c1db35d534f6634eeb1d7855f290 100644 (file)
@@ -8,4 +8,6 @@ CFLAGS += -I../../../../../usr/include
 include ../../lib.mk
 
 $(TEST_GEN_PROGS): ../harness.c ../utils.c
+
+$(OUTPUT)/spectre_v2: CFLAGS += -m64
 $(OUTPUT)/spectre_v2: ../pmu/event.c branch_loops.S