]> git.proxmox.com Git - mirror_qemu.git/commit - tests/bios-tables-test.c
tests: acpi: reuse fetch_table() for fetching FACS and DSDT
authorIgor Mammedov <imammedo@redhat.com>
Thu, 27 Dec 2018 14:13:30 +0000 (15:13 +0100)
committerMichael S. Tsirkin <mst@redhat.com>
Tue, 15 Jan 2019 00:31:04 +0000 (19:31 -0500)
commit59f9c6cc014309cde537842af2104b2f9956b0d6
tree18caa8c90028cf36d883b0f304bf2889d1f43841
parent569afd8428a5d0d9dab5be60df46920fb277194c
tests: acpi: reuse fetch_table() for fetching FACS and DSDT

It allows to remove a bit more of code duplication and
reuse common utility to get ACPI tables from guest (modulo RSDP).

While at it, consolidate signature checking into fetch_table() instead
of open-codding it.

Considering FACS is special and doesn't have checksum, make checksum
validation optin, the same goes for signature verification.

PS:
By pure accident, patch also fixes FACS not being tested against
reference table since it wasn't added to data::tables list.
But we managed not to regress it since reference file was added
by commit
   (d25979380 acpi unit-test: add test files)
back in 2013

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Acked-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
tests/bios-tables-test.c