summaryrefslogtreecommitdiffstats
path: root/tests/qtest
diff options
context:
space:
mode:
authorGerd Hoffmann2020-09-28 12:42:54 +0200
committerGerd Hoffmann2020-09-30 11:29:56 +0200
commit18bb73b3273d0c55ce1db1f8ab123d3d53506c7b (patch)
tree0331aa270a7ba74a0ae3e8956b62511247d3537b /tests/qtest
parenttests/acpi: factor out common microvm test setup (diff)
downloadqemu-18bb73b3273d0c55ce1db1f8ab123d3d53506c7b.tar.gz
qemu-18bb73b3273d0c55ce1db1f8ab123d3d53506c7b.tar.xz
qemu-18bb73b3273d0c55ce1db1f8ab123d3d53506c7b.zip
tests/acpi: add microvm pcie test
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Message-id: 20200928104256.9241-11-kraxel@redhat.com
Diffstat (limited to 'tests/qtest')
-rw-r--r--tests/qtest/bios-tables-test.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c
index 7be2b3131e..edf672d26f 100644
--- a/tests/qtest/bios-tables-test.c
+++ b/tests/qtest/bios-tables-test.c
@@ -1091,6 +1091,18 @@ static void test_acpi_microvm_tcg(void)
free_test_data(&data);
}
+static void test_acpi_microvm_pcie_tcg(void)
+{
+ test_data data;
+
+ test_acpi_microvm_prepare(&data);
+ data.variant = ".pcie";
+ data.tcg_only = true; /* need constant host-phys-bits */
+ test_acpi_one(" -machine microvm,acpi=on,rtc=off,pcie=on",
+ &data);
+ free_test_data(&data);
+}
+
static void test_acpi_virt_tcg_numamem(void)
{
test_data data = {
@@ -1213,6 +1225,9 @@ int main(int argc, char *argv[])
qtest_add_func("acpi/piix4/acpihmat", test_acpi_piix4_tcg_acpi_hmat);
qtest_add_func("acpi/q35/acpihmat", test_acpi_q35_tcg_acpi_hmat);
qtest_add_func("acpi/microvm", test_acpi_microvm_tcg);
+ if (strcmp(arch, "x86_64") == 0) {
+ qtest_add_func("acpi/microvm/pcie", test_acpi_microvm_pcie_tcg);
+ }
} else if (strcmp(arch, "aarch64") == 0) {
qtest_add_func("acpi/virt", test_acpi_virt_tcg);
qtest_add_func("acpi/virt/numamem", test_acpi_virt_tcg_numamem);