qemu-trivial.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kewei Yu <keweihk@gmail.com>
To: qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, mst@redhat.com
Subject: [Qemu-trivial] [PATCH 1/1] qtest:Fix the bug about disabling vnc causes "make check" hang
Date: Mon, 30 Dec 2013 16:46:55 +0800	[thread overview]
Message-ID: <1388393215-27511-1-git-send-email-keweihk@gmail.com> (raw)

When we disabling vnc from "./configure", the qemu can't use the vnc option.
So qtest can't use the "vnc -none ", otherwise "make check" will hang.

Signed-off-by: Kewei Yu <keweihk@gmail.com>
---
 tests/fdc-test.c |    4 ++++
 tests/ide-test.c |   11 ++++++++---
 2 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/tests/fdc-test.c b/tests/fdc-test.c
index 38b5b17..80dbdfb 100644
--- a/tests/fdc-test.c
+++ b/tests/fdc-test.c
@@ -538,7 +538,11 @@ int main(int argc, char **argv)
     /* Run the tests */
     g_test_init(&argc, &argv, NULL);
 
+#ifdef CONFIG_VNC
     cmdline = g_strdup_printf("-vnc none ");
+#else
+    cmdline = NULL;
+#endif
 
     qtest_start(cmdline);
     qtest_irq_intercept_in(global_qtest, "ioapic");
diff --git a/tests/ide-test.c b/tests/ide-test.c
index d5cec5a..da9e8dd 100644
--- a/tests/ide-test.c
+++ b/tests/ide-test.c
@@ -377,10 +377,15 @@ static void test_bmdma_no_busmaster(void)
     assert_bit_clear(inb(IDE_BASE + reg_status), DF | ERR);
 }
 
+#ifdef CONFIG_VNC
+#define QTEST_VNC_PARAM    "-vnc none ";
+#else
+#define QTEST_VNC_PARAM
+#endif
 static void test_bmdma_setup(void)
 {
     ide_test_start(
-        "-vnc none "
+        QTEST_VNC_PARAM
         "-drive file=%s,if=ide,serial=%s,cache=writeback "
         "-global ide-hd.ver=%s",
         tmp_path, "testdisk", "version");
@@ -410,7 +415,7 @@ static void test_identify(void)
     int ret;
 
     ide_test_start(
-        "-vnc none "
+        QTEST_VNC_PARAM
         "-drive file=%s,if=ide,serial=%s,cache=writeback "
         "-global ide-hd.ver=%s",
         tmp_path, "testdisk", "version");
@@ -455,7 +460,7 @@ static void test_flush(void)
     uint8_t data;
 
     ide_test_start(
-        "-vnc none "
+        QTEST_VNC_PARAM
         "-drive file=blkdebug::%s,if=ide,cache=writeback",
         tmp_path);
 
-- 
1.7.1



             reply	other threads:[~2013-12-30  8:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-30  8:46 Kewei Yu [this message]
2013-12-31  0:19 ` [Qemu-trivial] [Qemu-devel] [PATCH 1/1] qtest:Fix the bug about disabling vnc causes "make check" hang Andreas Färber
2014-01-02  4:08   ` Stefan Hajnoczi
2014-01-07 10:35     ` Markus Armbruster
2014-01-07 11:36       ` Andreas Färber
2014-01-09 13:33         ` Markus Armbruster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1388393215-27511-1-git-send-email-keweihk@gmail.com \
    --to=keweihk@gmail.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).