Make the code a little bit more robust and self-explanatory. Signed-off-by: Paolo Bonzini <pbonzini@xxxxxxxxxx> --- x86/realmode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x86/realmode.c b/x86/realmode.c index a1df515..5dbc2aa 100644 --- a/x86/realmode.c +++ b/x86/realmode.c @@ -606,7 +606,7 @@ static void test_long_jmp(void) u32 esp[16]; inregs = (struct regs){ 0 }; - inregs.esp = (u32)(esp+16); + inregs.esp = (u32)&esp[ARRAY_SIZE(esp)]; MK_INSN(long_jmp, "call 1f\n\t" "jmp 2f\n\t" "1: jmp $0, $test_function\n\t" -- 2.21.0