History | View | Annotate | Download (22.3 kB)
Prevent abortion on multiple VCPU kicks
If we call qemu_cpu_kick more than once before the target was able toprocess the signal, pthread_kill will fail, and qemu will abort. Preventthis by avoiding the redundant signal.
This logic can be found in qemu-kvm as well....
Stop current VCPU on synchronous reset requests
If some I/O operation ends up calling qemu_system_reset_request in VCPUcontext, we record this and inform the io-thread, but we do notterminate the VCPU loop. This can lead to fairly unexpected behavior if...
Trigger exit from cpu_exec_all on pending IO events
Except for timer events, we currently do not leave the loop over allVCPUs if an IO event was filed. That may cause unexpected IO latenciesunder !CONFIG_IOTHREAD in SMP scenarios. Fix it by setting the global...
kvm: Do not use qemu_fair_mutex
The imbalance in the hold time of qemu_global_mutex only exists in TCGmode. In contrast to TCG VCPUs, KVM drops the global lock during guestexecution. We already avoid touching the fairness lock from theIO-thread in KVM mode, so also stop using it from the VCPU threads....
cpus: flush all requests on each vm stop
Flush all requests once we have stopped allcpus and devices.Make sure disk is in consistent state.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Tested-by: Jason Wang <jasowang@redhat.com>Acked-by: Marcelo Tosatti <mtosatti@redhat.com>
target-xxx: Use fprintf_function (format checking)
fprintf_function uses format checking with GCC_FMT_ATTR.
Cc: Blue Swirl <blauwirbel@gmail.com>Signed-off-by: Stefan Weil <weil@mail.berlios.de>...
iothread: use signalfd
Block SIGALRM, SIGIO and consume them via signalfd.
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>Signed-off-by: Avi Kivity <avi@redhat.com>
MCE: Relay UCR MCE to guest
Port qemu-kvm's
commit 4b62fff1101a7ad77553147717a8bd3bf79df7efAuthor: Huang Ying <ying.huang@intel.com>Date: Mon Sep 21 10:43:25 2009 +0800
UCR (uncorrected recovery) MCE is supported in recent Intel CPUs,...
Init qemu_system_cond
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Acked-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Marcelo Tosatti <mtosatti@redhat.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Fix cpu_exit for tcp_cpu_exec
If a cpu_exit request is pending, ensure that we leave the CPU loopquickly. For this purpose, keep the global exit_request pending untilwe are about to leave tcg_cpu_exec. Also, immediately break out of theSMP loop if the request is set, do not run till the end of the chain....
Fix qemu_wait_io_event processing in io-thread mode
When checking for I/O events in the tcg CPU loop, make sure that wecall qemu_wait_io_event_common for all CPUs, not only the current one.Otherwise pause_all_vcpus may lock up or run_on_cpu requests may starve....
Drop redundant global cur_cpu variable
Rename tcg_cpu_exec and tcg_has_work
These functions are also used for kvm under !CONFIG_IOTHREAD, having'tcg' in their name is just misleading.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Acked-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Marcelo Tosatti <mtosatti@redhat.com>...
Rework debug exception processing for gdb use
Guest debugging is currently broken under CONFIG_IOTHREAD. The reason isinconsistent or even lacking signaling the debug events from the sourceVCPU to the main loop and the gdbstub.
This patch addresses the issue by pushing this signaling into a...
Fix io-thread build breakage of a88790a14f
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
make qemu_thread_create block all signals
All signals will thus be routed through the IO thread.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
cpus: add one 'const'
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
make SIG_IPI to tcg vcpu thread reliable
Store tcg loop exit request on a global variable, and transfer it toper-CPUState exit_request after assignment of cpu_single_env.
This makes exit request signal from robust. Drop the timedlock hack.
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>...
standardize on qemu_cpu_kick for signalling cpu thread(s)
port qemu-kvm's on_vcpu code
run_on_cpu allows to execute work on a given CPUState context.
add cpu_is_stopped helper
Fix cpu list("-cpu ?") breakage, spotted by TeLeMan
Fix breakage by 04c9a0cbc2bf496889cef6da2d61bf00ef190a4f.
kvm_init_vcpu requires global lock held
Since it accesses data protected by the lock.
Signed-off-by: Avi Kivity <avi@redhat.com>
Fix build when configured with --enable-io-thread
fix 100% cpu utilization when cpu is stopped
Hello, d6f4ade (disentangle tcg and deadline calculation, 2010-03-10)introduces following regression(s): 100% cpu utilization when QEMU is invoked like:qemu -S -s ... ditto when gdb takes control over the session via gdb-stub...
Hello,
d6f4ade (disentangle tcg and deadline calculation, 2010-03-10)introduces following regression(s):
100% cpu utilization when QEMU is invoked like:qemu -S -s ...
ditto when gdb takes control over the session via gdb-stub...
Compile qemu-timer only once
Arrange various declarations so that also non-CPU code can accessthem, adjust users.
Move CPU specific code to cpus.c.
Refactor CPUState handling out of vl.c