aboutsummaryrefslogtreecommitdiff
path: root/target/i386/helper.h
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2017-02-16 12:30:05 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2017-02-16 18:37:01 +0100
commit65c9d60a3ad3249784348824eca69acac455bc02 (patch)
treeb0fb43c0c2841ae1f62b5342e376a4d46accc9e9 /target/i386/helper.h
parentf47291b7a7ffa8854300283d4773ed17d5d581c1 (diff)
downloadqemu-65c9d60a3ad3249784348824eca69acac455bc02.zip
qemu-65c9d60a3ad3249784348824eca69acac455bc02.tar.gz
qemu-65c9d60a3ad3249784348824eca69acac455bc02.tar.bz2
target-i386: correctly propagate retaddr into SVM helpers
Commit 2afbdf8 ("target-i386: exception handling for memory helpers", 2015-09-15) changed tlb_fill's cpu_restore_state+raise_exception_err to raise_exception_err_ra. After this change, the cpu_restore_state and raise_exception_err's cpu_loop_exit are merged into raise_exception_err_ra's cpu_loop_exit_restore. This actually fixed some bugs, but when SVM is enabled there is a second path from raise_exception_err_ra to cpu_loop_exit. This is the VMEXIT path, and now cpu_vmexit is called without a cpu_restore_state before. The fix is to pass the retaddr to cpu_vmexit (via cpu_svm_check_intercept_param). All helpers can now use GETPC() to pass the correct retaddr, too. Cc: qemu-stable@nongnu.org Fixes: 2afbdf84807d673eb682cb78158e11cdacbf4673 Reported-by: Alexander Boettcher <alexander.boettcher@genode-labs.com> Tested-by: Alexander Boettcher <alexander.boettcher@genode-labs.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target/i386/helper.h')
-rw-r--r--target/i386/helper.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/target/i386/helper.h b/target/i386/helper.h
index 4c1aaff..6fb8fb9 100644
--- a/target/i386/helper.h
+++ b/target/i386/helper.h
@@ -99,7 +99,6 @@ DEF_HELPER_2(inl, tl, env, i32)
DEF_HELPER_FLAGS_4(bpt_io, TCG_CALL_NO_WG, void, env, i32, i32, tl)
DEF_HELPER_3(svm_check_intercept_param, void, env, i32, i64)
-DEF_HELPER_3(vmexit, void, env, i32, i64)
DEF_HELPER_4(svm_check_io, void, env, i32, i32, i32)
DEF_HELPER_3(vmrun, void, env, int, int)
DEF_HELPER_1(vmmcall, void, env)