aboutsummaryrefslogtreecommitdiff
path: root/tests/ivshmem-test.c
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2017-09-11 12:20:01 -0500
committerThomas Huth <thuth@redhat.com>2018-02-14 11:43:41 +0100
commit3d95fb9770f0fbf4396879bb6152b0e78edf0546 (patch)
treee2e4022460ab6878de071853c5d8cba8c3410be1 /tests/ivshmem-test.c
parent10747e55d53d32f1f062456cac1e4fa32f58c44e (diff)
libqos: Use explicit QTestState for remaining libqos operations
Drop one more client of global_qtest by teaching all remaining libqos stragglers to pass in an explicit QTestState. Change the setting of global_qtest from being implicit in libqos' call to qtest_start() to instead be explicit in all clients that are still relying on global_qtest. Note that qmp_execute() can be greatly simplified in the process, and that we also get rid of interpolation of a JSON string into a temporary variable when qtest_qmp() can do it more reliably. Signed-off-by: Eric Blake <eblake@redhat.com> Acked-by: Greg Kurz <groug@kaod.org> Reviewed-by: John Snow <jsnow@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'tests/ivshmem-test.c')
-rw-r--r--tests/ivshmem-test.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/ivshmem-test.c b/tests/ivshmem-test.c
index 37763425ee..8af16ee79a 100644
--- a/tests/ivshmem-test.c
+++ b/tests/ivshmem-test.c
@@ -131,6 +131,7 @@ static void setup_vm_cmd(IVState *s, const char *cmd, bool msix)
g_printerr("ivshmem-test tests are only available on x86 or ppc64\n");
exit(EXIT_FAILURE);
}
+ global_qtest = s->qs->qts;
s->dev = get_device(s->qs->pcibus);
s->reg_bar = qpci_iomap(s->dev, 0, &barsize);