We are going to remove global_qtest from the main libqtest library
soon, so tests that do not urgently need global_qtest anymore
should be cleaned from the unnecessary references.
Message-Id: <
20190904130047.25808-5-thuth@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
{
QOSState *qs = ahci->parent;
- assert(!global_qtest);
ahci_clean_mem(ahci);
free_ahci_device(ahci->dev);
g_free(ahci);
test_smbios_structs(data);
}
- assert(!global_qtest);
qtest_quit(data->qts);
g_free(args);
}
static void cleanup_vm(IVState *s)
{
- assert(!global_qtest);
g_free(s->dev);
qtest_shutdown(s->qs);
}
qts = qtest_init("-object memory-backend-ram,size=1M,id=mb1");
- global_qtest = qts; /* TODO: Get rid of global_qtest here */
qtest_qmp_device_add(qts, "ivshmem-plain", "iv1",
"{'addr': %s, 'memdev': 'mb1'}",
stringify(PCI_SLOT_HP));
}
qtest_quit(qts);
- global_qtest = NULL;
}
static void test_ivshmem_memdev(void)
time_t t1, t2;
qs = qtest_spapr_boot("-machine pseries");
- global_qtest = qs->qts;
t1 = time(NULL);
ret = qrtas_get_time_of_day(qs->qts, &qs->alloc, &tm, &ns);