]> xenbits.xensource.com Git - xen.git/commitdiff
x86/emul: Fix emulator test harness build following a backport of 7c508612
authorAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 9 May 2018 17:06:46 +0000 (18:06 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 9 May 2018 17:08:36 +0000 (18:08 +0100)
The x86 emulator doesn't need to employ any Spectre v2 mitigations.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
tools/tests/x86_emulator/x86_emulate.c

index 1e67d648ad504ca60e4a87e8adfe985764a5e72c..c91d436a6391ad44ca7085110aa56b641ab7cc9d 100644 (file)
@@ -35,4 +35,9 @@ typedef bool bool_t;
 #define get_stub(stb) ((void *)((stb).addr = (uintptr_t)(stb).buf))
 #define put_stub(stb)
 
+/* No Spectre mitigations needed for the test harness. */
+asm (".macro INDIRECT_CALL arg:req\n\t"
+     "call *\\arg\n\t"
+     ".endm");
+
 #include "x86_emulate/x86_emulate.c"