summaryrefslogtreecommitdiff
path: root/main-loop.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2014-03-13 14:17:29 +0000
committerAndreas Färber <afaerber@suse.de>2014-03-13 21:36:50 +0100
commit01c22f2cdd4fcf02276ea10f48253850a5fd7259 (patch)
treecbdb89f66a43670a04f23d3c5976577498332254 /main-loop.c
parentcb201b4872f16dfbce63f8648b2584631e2e965f (diff)
downloadqemu-01c22f2cdd4fcf02276ea10f48253850a5fd7259.tar.gz
qemu-01c22f2cdd4fcf02276ea10f48253850a5fd7259.tar.bz2
qemu-01c22f2cdd4fcf02276ea10f48253850a5fd7259.zip
main-loop: Suppress "I/O thread spun" warnings for qtest
When running under qtest we don't actually have any vcpu threads to be starved, so the warning about the I/O thread spinning isn't relevant, and the way qtest manipulates the simulated clock means the warning is produced a lot as a false positive. Suppress it if qtest_enabled(), so 'make check' output is less noisy. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'main-loop.c')
-rw-r--r--main-loop.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/main-loop.c b/main-loop.c
index c3c9c28fba..8a854938e7 100644
--- a/main-loop.c
+++ b/main-loop.c
@@ -25,6 +25,7 @@
#include "qemu-common.h"
#include "qemu/timer.h"
#include "qemu/sockets.h" // struct in_addr needed for libslirp.h
+#include "sysemu/qtest.h"
#include "slirp/libslirp.h"
#include "qemu/main-loop.h"
#include "block/aio.h"
@@ -208,7 +209,7 @@ static int os_host_main_loop_wait(int64_t timeout)
if (!timeout && (spin_counter > MAX_MAIN_LOOP_SPIN)) {
static bool notified;
- if (!notified) {
+ if (!notified && !qtest_enabled()) {
fprintf(stderr,
"main-loop: WARNING: I/O thread spun for %d iterations\n",
MAX_MAIN_LOOP_SPIN);