diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2020-10-01 15:28:55 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2020-10-01 15:28:55 +0100 |
commit | b23317eec4715aa62de9a6e5490a01122c8eef0e (patch) | |
tree | 4c46752e3d1092ab006305b3ca8f845ea348a342 /tests | |
parent | 37a712a0f969ca2df7f01182409a6c4825cebfb5 (diff) | |
parent | 7f6c3d1a574bddcda6931eb00287089998725f71 (diff) |
Merge remote-tracking branch 'remotes/kraxel/tags/microvm-20200930-pull-request' into staging
microvm: add pcie support.
# gpg: Signature made Wed 30 Sep 2020 18:48:41 BST
# gpg: using RSA key 4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full]
# gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" [full]
# gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full]
# Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138
* remotes/kraxel/tags/microvm-20200930-pull-request:
tests/acpi: update expected data files
acpi/gpex: no reason to use a method for _CRS
tests/acpi: add microvm pcie test
tests/acpi: factor out common microvm test setup
tests/acpi: add empty tests/data/acpi/microvm/DSDT.pcie file
tests/acpi: allow updates for expected data files
microvm/pcie: add 64bit mmio window
microvm: add pcie support
microvm: add irq table
arm: use acpi_dsdt_add_gpex
acpi: add acpi_dsdt_add_gpex
move MemMapEntry
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/data/acpi/microvm/DSDT.pcie | bin | 0 -> 3023 bytes | |||
-rw-r--r-- | tests/data/acpi/virt/DSDT | bin | 5200 -> 5196 bytes | |||
-rw-r--r-- | tests/data/acpi/virt/DSDT.memhp | bin | 6561 -> 6557 bytes | |||
-rw-r--r-- | tests/data/acpi/virt/DSDT.numamem | bin | 5200 -> 5196 bytes | |||
-rw-r--r-- | tests/qtest/bios-tables-test.c | 30 |
5 files changed, 25 insertions, 5 deletions
diff --git a/tests/data/acpi/microvm/DSDT.pcie b/tests/data/acpi/microvm/DSDT.pcie Binary files differnew file mode 100644 index 0000000000..4b765541e3 --- /dev/null +++ b/tests/data/acpi/microvm/DSDT.pcie diff --git a/tests/data/acpi/virt/DSDT b/tests/data/acpi/virt/DSDT Binary files differindex 9b002836f3..bc519abff9 100644 --- a/tests/data/acpi/virt/DSDT +++ b/tests/data/acpi/virt/DSDT diff --git a/tests/data/acpi/virt/DSDT.memhp b/tests/data/acpi/virt/DSDT.memhp Binary files differindex 545a18c365..54728e2b4b 100644 --- a/tests/data/acpi/virt/DSDT.memhp +++ b/tests/data/acpi/virt/DSDT.memhp diff --git a/tests/data/acpi/virt/DSDT.numamem b/tests/data/acpi/virt/DSDT.numamem Binary files differindex 9b002836f3..bc519abff9 100644 --- a/tests/data/acpi/virt/DSDT.numamem +++ b/tests/data/acpi/virt/DSDT.numamem diff --git a/tests/qtest/bios-tables-test.c b/tests/qtest/bios-tables-test.c index 67d1bed082..e15f36c8c7 100644 --- a/tests/qtest/bios-tables-test.c +++ b/tests/qtest/bios-tables-test.c @@ -1086,20 +1086,37 @@ static void test_acpi_virt_tcg_memhp(void) } +static void test_acpi_microvm_prepare(test_data *data) +{ + memset(data, 0, sizeof(*data)); + data->machine = "microvm"; + data->required_struct_types = NULL; /* no smbios */ + data->required_struct_types_len = 0; + data->blkdev = "virtio-blk-device"; +} + static void test_acpi_microvm_tcg(void) { test_data data; - memset(&data, 0, sizeof(data)); - data.machine = "microvm"; - data.required_struct_types = NULL; /* no smbios */ - data.required_struct_types_len = 0; - data.blkdev = "virtio-blk-device"; + test_acpi_microvm_prepare(&data); test_acpi_one(" -machine microvm,acpi=on,rtc=off", &data); 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 = { @@ -1224,6 +1241,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); |