aboutsummaryrefslogtreecommitdiff
path: root/softmmu
diff options
context:
space:
mode:
Diffstat (limited to 'softmmu')
-rw-r--r--softmmu/cpus.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/softmmu/cpus.c b/softmmu/cpus.c
index 668bef9..23b3048 100644
--- a/softmmu/cpus.c
+++ b/softmmu/cpus.c
@@ -672,7 +672,7 @@ int vm_stop(RunState state)
* Returns -1 if the vCPUs are not to be restarted (e.g. if they are already
* running or in case of an error condition), 0 otherwise.
*/
-int vm_prepare_start(void)
+int vm_prepare_start(bool step_pending)
{
RunState requested;
@@ -692,6 +692,14 @@ int vm_prepare_start(void)
return -1;
}
+ /*
+ * WHPX accelerator needs to know whether we are going to step
+ * any CPUs, before starting the first one.
+ */
+ if (cpus_accel->synchronize_pre_resume) {
+ cpus_accel->synchronize_pre_resume(step_pending);
+ }
+
/* We are sending this now, but the CPUs will be resumed shortly later */
qapi_event_send_resume();
@@ -703,7 +711,7 @@ int vm_prepare_start(void)
void vm_start(void)
{
- if (!vm_prepare_start()) {
+ if (!vm_prepare_start(false)) {
resume_all_vcpus();
}
}