* Various fixes for qtests

* Enable TCG tests with TCI in the gitlab CI
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEJ7iIR+7gJQEY8+q5LtnXdP5wLbUFAl4hjeURHHRodXRoQHJl
 ZGhhdC5jb20ACgkQLtnXdP5wLbVzBw//XhecLlGn+zqx5BJjF6jl8JrkPwt7MSkX
 Eqsns+oJxMgq6R2O7Jic/cM9R00QJ3v0SyV44/qg0qmxU9Mrrs01njhIekHjQ/Wz
 YCoXtmoZivOFB4uVCfceAJ5q2NufXAZi9rWRqRwz2mImrka03ZSAuV5XwD8QU8Cw
 FIJ47GgxFSeFrTs0Z1YeaYikvKexIyuoWQbMHY801wcD8pzvM9za6cQadYGhuGmF
 jYexhs8yHYvRGTI20jQ0mojYbBUMhp9B5RH1m4xrNLD3VrMW025ndzoS+RykSJDJ
 r3i12UsJ7NrZRQ6tj8ZnHNb/7QEuiQFX/DdsItLKTx50CDUtX3Ic0k38DF4/2R8F
 RsT5EErbWBzRRwjYXBrt7CsifWuoC8hjCP3GmNCPZzCeMFZxEhaMHaS4APbryGBY
 dDNwvjiojAyUs2Y55HF5k2MyE60zDZRq0Kxba7vx5x1ugfFNt3fd0oBWAVckDHb4
 2LXwPV/im30mtAAy22abUrS3NxpP6eRHHFzs8bsE/Hw9lsWtMwaMt2NlcL68pQJ9
 PYWi4gTGcssX0IMwvLyRwLZjfi0X8S9LB606Oq25LuRLNUuNE55o9R4YLLNgCHBu
 LHJt25eOgWfspQOIYbuITfOZ8Mxu45Ayva1Kon8LY47h5vfjgLKhCAalrTXVox13
 GR7lc1nrzx4=
 =cRyz
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/huth-gitlab/tags/pull-request-2020-01-17' into staging

* Various fixes for qtests
* Enable TCG tests with TCI in the gitlab CI

# gpg: Signature made Fri 17 Jan 2020 10:35:17 GMT
# gpg:                using RSA key 27B88847EEE0250118F3EAB92ED9D774FE702DB5
# gpg:                issuer "thuth@redhat.com"
# gpg: Good signature from "Thomas Huth <th.huth@gmx.de>" [full]
# gpg:                 aka "Thomas Huth <thuth@redhat.com>" [full]
# gpg:                 aka "Thomas Huth <huth@tuxfamily.org>" [full]
# gpg:                 aka "Thomas Huth <th.huth@posteo.de>" [unknown]
# Primary key fingerprint: 27B8 8847 EEE0 2501 18F3  EAB9 2ED9 D774 FE70 2DB5

* remotes/huth-gitlab/tags/pull-request-2020-01-17:
  gitlab-ci.yml: Run tcg test with tci
  tests/qtest/vhost-user-test: Fix memory leaks
  migration-test: ppc64: fix FORTH test program
  tests: acpi: update path in rebuild-expected-aml

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
Peter Maydell 2020-01-17 14:56:53 +00:00
commit bc65450ebb
4 changed files with 14 additions and 8 deletions

View File

@ -87,6 +87,7 @@ build-tci:
- ../configure --enable-tcg-interpreter - ../configure --enable-tcg-interpreter
--target-list="$(for tg in $TARGETS; do echo -n ${tg}'-softmmu '; done)" --target-list="$(for tg in $TARGETS; do echo -n ${tg}'-softmmu '; done)"
- make -j2 - make -j2
- make run-tcg-tests-x86_64-softmmu
- make tests/qtest/boot-serial-test tests/qtest/cdrom-test tests/qtest/pxe-test - make tests/qtest/boot-serial-test tests/qtest/cdrom-test tests/qtest/pxe-test
- for tg in $TARGETS ; do - for tg in $TARGETS ; do
export QTEST_QEMU_BINARY="${tg}-softmmu/qemu-system-${tg}" ; export QTEST_QEMU_BINARY="${tg}-softmmu/qemu-system-${tg}" ;

View File

@ -14,7 +14,7 @@
qemu_bins="x86_64-softmmu/qemu-system-x86_64 aarch64-softmmu/qemu-system-aarch64" qemu_bins="x86_64-softmmu/qemu-system-x86_64 aarch64-softmmu/qemu-system-aarch64"
if [ ! -e "tests/bios-tables-test" ]; then if [ ! -e "tests/qtest/bios-tables-test" ]; then
echo "Test: bios-tables-test is required! Run make check before this script." echo "Test: bios-tables-test is required! Run make check before this script."
echo "Run this script from the build directory." echo "Run this script from the build directory."
exit 1; exit 1;
@ -26,11 +26,11 @@ for qemu in $qemu_bins; do
echo "Also, run this script from the build directory." echo "Also, run this script from the build directory."
exit 1; exit 1;
fi fi
TEST_ACPI_REBUILD_AML=y QTEST_QEMU_BINARY=$qemu tests/bios-tables-test TEST_ACPI_REBUILD_AML=y QTEST_QEMU_BINARY=$qemu tests/qtest/bios-tables-test
done done
eval `grep SRC_PATH= config-host.mak` eval `grep SRC_PATH= config-host.mak`
echo '/* List of comma-separated changed AML files to ignore */' > ${SRC_PATH}/tests/bios-tables-test-allowed-diff.h echo '/* List of comma-separated changed AML files to ignore */' > ${SRC_PATH}/tests/qtest/bios-tables-test-allowed-diff.h
echo "The files were rebuilt and can be added to git." echo "The files were rebuilt and can be added to git."

View File

@ -480,14 +480,14 @@ static int test_migrate_start(QTestState **from, QTestState **to,
} else if (strcmp(arch, "ppc64") == 0) { } else if (strcmp(arch, "ppc64") == 0) {
machine_opts = "vsmt=8"; machine_opts = "vsmt=8";
memory_size = "256M"; memory_size = "256M";
start_address = PPC_TEST_MEM_START;
end_address = PPC_TEST_MEM_END;
arch_source = g_strdup_printf("-nodefaults " arch_source = g_strdup_printf("-nodefaults "
"-prom-env 'use-nvramrc?=true' -prom-env " "-prom-env 'use-nvramrc?=true' -prom-env "
"'nvramrc=hex .\" _\" begin %x %x " "'nvramrc=hex .\" _\" begin %x %x "
"do i c@ 1 + i c! 1000 +loop .\" B\" 0 " "do i c@ 1 + i c! 1000 +loop .\" B\" 0 "
"until'", end_address, start_address); "until'", end_address, start_address);
arch_target = g_strdup(""); arch_target = g_strdup("");
start_address = PPC_TEST_MEM_START;
end_address = PPC_TEST_MEM_END;
} else if (strcmp(arch, "aarch64") == 0) { } else if (strcmp(arch, "aarch64") == 0) {
init_bootfile(bootpath, aarch64_kernel, sizeof(aarch64_kernel)); init_bootfile(bootpath, aarch64_kernel, sizeof(aarch64_kernel));
machine_opts = "virt,gic-version=max"; machine_opts = "virt,gic-version=max";

View File

@ -707,9 +707,9 @@ static void test_read_guest_mem(void *obj, void *arg, QGuestAllocator *alloc)
static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc) static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc)
{ {
TestServer *s = arg; TestServer *s = arg;
TestServer *dest = test_server_new("dest"); TestServer *dest;
GString *dest_cmdline = g_string_new(qos_get_current_command_line()); GString *dest_cmdline;
char *uri = g_strdup_printf("%s%s", "unix:", dest->mig_path); char *uri;
QTestState *to; QTestState *to;
GSource *source; GSource *source;
QDict *rsp; QDict *rsp;
@ -720,6 +720,10 @@ static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc)
return; return;
} }
dest = test_server_new("dest");
dest_cmdline = g_string_new(qos_get_current_command_line());
uri = g_strdup_printf("%s%s", "unix:", dest->mig_path);
size = get_log_size(s); size = get_log_size(s);
g_assert_cmpint(size, ==, (256 * 1024 * 1024) / (VHOST_LOG_PAGE * 8)); g_assert_cmpint(size, ==, (256 * 1024 * 1024) / (VHOST_LOG_PAGE * 8));
@ -778,6 +782,7 @@ static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc)
qtest_quit(to); qtest_quit(to);
test_server_free(dest); test_server_free(dest);
g_free(uri); g_free(uri);
g_string_free(dest_cmdline, true);
} }
static void wait_for_rings_started(TestServer *s, size_t count) static void wait_for_rings_started(TestServer *s, size_t count)