Message ID | 20220627072856.1529357-1-ani@anisinha.ca (mailing list archive) |
---|---|
Headers | show |
Series | Introduce new acpi/smbios qtests using biosbits | expand |
On Mon, Jun 27, 2022 at 12:58:44PM +0530, Ani Sinha wrote: > Biosbits is a software written by Josh Triplett that can be downloaded by > visiting https://biosbits.org/. The github codebase can be found here: > https://github.com/biosbits/bits/tree/master. It is a software that exercizes > the bios components such as acpi and smbios tables directly through acpica > bios interpreter (a freely available C based library written by Intel, > downloadable from https://acpica.org/ and is included with biosbits) without an > operating system getting involved in between. > There are several advantages to directly testing the bios in a real physical > machine or VM as opposed to indirectly discovering bios issues through the > operating system. For one thing, the OSes tend to hide bios problems from the > end user. The other is that we have more control of what we wanted to test > and how by directly using acpica interpreter on top of the bios on a running > system. More details on the inspiration for developing biosbits and its real > life uses can be found in (a) and (b). > This patchset contains QEMU qtests written in python that exercizes the QEMU > bios components using biosbits and reports test failures. > > Details of each of the files added by this patchset are provided in the README > file which is part of Patch 11. Every effort to contact Josh, through various > means including email, twitter, linkedIn etc has failed. Hence, the changes to > build biosbits with the newer compiler, upgrade acpica and other changes are > currently maintained in a forked project in my personal github. We may want to > maintain bits in a separate fork in a stable repository that is accessible by > QEMU developers. > > The newly introduced qtest currently only run for x86_64 platform. They pass > both when running make check on a baremetal box as well as from inside a vm. > > Thanks to Igor M for pointing me to this work. > > (a) https://blog.linuxplumbersconf.org/2011/ocw/system/presentations/867/original/bits.pdf > (b) https://www.youtube.com/watch?v=36QIepyUuhg > > Ani Sinha (12): > qtest: meson.build changes required to integrate python based qtests > acpi/tests/bits: add prebuilt bios bits zip archive > acpi/tests/bits: add prebuilt bits generated grub modules and scripts These two files didn't arrive on the mailing list, presumaby because pre-built binaries made the patches way too large. With regards, Daniel
On Tue, Jun 28, 2022 at 1:39 PM Daniel P. Berrangé <berrange@redhat.com> wrote: > > On Mon, Jun 27, 2022 at 12:58:44PM +0530, Ani Sinha wrote: > > Biosbits is a software written by Josh Triplett that can be downloaded by > > visiting https://biosbits.org/. The github codebase can be found here: > > https://github.com/biosbits/bits/tree/master. It is a software that exercizes > > the bios components such as acpi and smbios tables directly through acpica > > bios interpreter (a freely available C based library written by Intel, > > downloadable from https://acpica.org/ and is included with biosbits) without an > > operating system getting involved in between. > > There are several advantages to directly testing the bios in a real physical > > machine or VM as opposed to indirectly discovering bios issues through the > > operating system. For one thing, the OSes tend to hide bios problems from the > > end user. The other is that we have more control of what we wanted to test > > and how by directly using acpica interpreter on top of the bios on a running > > system. More details on the inspiration for developing biosbits and its real > > life uses can be found in (a) and (b). > > This patchset contains QEMU qtests written in python that exercizes the QEMU > > bios components using biosbits and reports test failures. > > > > Details of each of the files added by this patchset are provided in the README > > file which is part of Patch 11. Every effort to contact Josh, through various > > means including email, twitter, linkedIn etc has failed. Hence, the changes to > > build biosbits with the newer compiler, upgrade acpica and other changes are > > currently maintained in a forked project in my personal github. We may want to > > maintain bits in a separate fork in a stable repository that is accessible by > > QEMU developers. > > > > The newly introduced qtest currently only run for x86_64 platform. They pass > > both when running make check on a baremetal box as well as from inside a vm. > > > > Thanks to Igor M for pointing me to this work. > > > > (a) https://blog.linuxplumbersconf.org/2011/ocw/system/presentations/867/original/bits.pdf > > (b) https://www.youtube.com/watch?v=36QIepyUuhg > > > > Ani Sinha (12): > > qtest: meson.build changes required to integrate python based qtests > > acpi/tests/bits: add prebuilt bios bits zip archive > > acpi/tests/bits: add prebuilt bits generated grub modules and scripts > > These two files didn't arrive on the mailing list, presumaby because > pre-built binaries made the patches way too large. Yes they are over 25 MB and my gmail account does not support attachments more than that size. > > > With regards, > Daniel > -- > |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| > |: https://libvirt.org -o- https://fstop138.berrange.com :| > |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :| >
On Tue, Jun 28, 2022 at 02:03:15PM +0530, Ani Sinha wrote: > On Tue, Jun 28, 2022 at 1:39 PM Daniel P. Berrangé <berrange@redhat.com> wrote: > > > > On Mon, Jun 27, 2022 at 12:58:44PM +0530, Ani Sinha wrote: > > > Biosbits is a software written by Josh Triplett that can be downloaded by > > > visiting https://biosbits.org/. The github codebase can be found here: > > > https://github.com/biosbits/bits/tree/master. It is a software that exercizes > > > the bios components such as acpi and smbios tables directly through acpica > > > bios interpreter (a freely available C based library written by Intel, > > > downloadable from https://acpica.org/ and is included with biosbits) without an > > > operating system getting involved in between. > > > There are several advantages to directly testing the bios in a real physical > > > machine or VM as opposed to indirectly discovering bios issues through the > > > operating system. For one thing, the OSes tend to hide bios problems from the > > > end user. The other is that we have more control of what we wanted to test > > > and how by directly using acpica interpreter on top of the bios on a running > > > system. More details on the inspiration for developing biosbits and its real > > > life uses can be found in (a) and (b). > > > This patchset contains QEMU qtests written in python that exercizes the QEMU > > > bios components using biosbits and reports test failures. > > > > > > Details of each of the files added by this patchset are provided in the README > > > file which is part of Patch 11. Every effort to contact Josh, through various > > > means including email, twitter, linkedIn etc has failed. Hence, the changes to > > > build biosbits with the newer compiler, upgrade acpica and other changes are > > > currently maintained in a forked project in my personal github. We may want to > > > maintain bits in a separate fork in a stable repository that is accessible by > > > QEMU developers. > > > > > > The newly introduced qtest currently only run for x86_64 platform. They pass > > > both when running make check on a baremetal box as well as from inside a vm. > > > > > > Thanks to Igor M for pointing me to this work. > > > > > > (a) https://blog.linuxplumbersconf.org/2011/ocw/system/presentations/867/original/bits.pdf > > > (b) https://www.youtube.com/watch?v=36QIepyUuhg > > > > > > Ani Sinha (12): > > > qtest: meson.build changes required to integrate python based qtests > > > acpi/tests/bits: add prebuilt bios bits zip archive > > > acpi/tests/bits: add prebuilt bits generated grub modules and scripts > > > > These two files didn't arrive on the mailing list, presumaby because > > pre-built binaries made the patches way too large. > > Yes they are over 25 MB and my gmail account does not support > attachments more than that size. Ok, with that kind of size, it is definitely not something we want to be committing to git either, nor consuming via a submodule since the latter would bloat the release tarballs too. With regards, Daniel
On Tue, Jun 28, 2022 at 11:06:11AM +0100, Daniel P. Berrangé wrote: > Ok, with that kind of size, it is definitely not something we want to > be committing to git either, Not to qemu git I think. > nor consuming via a submodule since the > latter would bloat the release tarballs too. Hmm - why? We don't have to put the submodule in the tarball if we don't want to. People consuming tarballs probably do not need these tests anyway - just a basic smoketest is all that is needed.
On Tue, Jun 28, 2022 at 06:16:06AM -0400, Michael S. Tsirkin wrote: > On Tue, Jun 28, 2022 at 11:06:11AM +0100, Daniel P. Berrangé wrote: > > Ok, with that kind of size, it is definitely not something we want to > > be committing to git either, > > Not to qemu git I think. > > > nor consuming via a submodule since the > > latter would bloat the release tarballs too. > > Hmm - why? We don't have to put the submodule in the tarball if we don't > want to. People consuming tarballs probably do not need these tests > anyway - just a basic smoketest is all that is needed. That feels very dubious. Upstream doesnt test every scenario that users build & run in. Especially with Fedora rawhide we've often found problems which upstream QEMU missed, particularly where new GCC releases have bugs causing subtle mis-compilation of code. With regards, Daniel
On Tue, Jun 28, 2022 at 11:21:44AM +0100, Daniel P. Berrangé wrote: > On Tue, Jun 28, 2022 at 06:16:06AM -0400, Michael S. Tsirkin wrote: > > On Tue, Jun 28, 2022 at 11:06:11AM +0100, Daniel P. Berrangé wrote: > > > Ok, with that kind of size, it is definitely not something we want to > > > be committing to git either, > > > > Not to qemu git I think. > > > > > nor consuming via a submodule since the > > > latter would bloat the release tarballs too. > > > > Hmm - why? We don't have to put the submodule in the tarball if we don't > > want to. People consuming tarballs probably do not need these tests > > anyway - just a basic smoketest is all that is needed. > > That feels very dubious. Upstream doesnt test every scenario that users > build & run in. Especially with Fedora rawhide we've often found problems > which upstream QEMU missed, particularly where new GCC releases have bugs > causing subtle mis-compilation of code. > > With regards, > Daniel IMHO these tests are not really useful for that. What they do is verify that our ACPI tables are sane - in addition to the manual review with disassembler we do currently. We already have tests that verify that qemu generates expected ACPI tables and that is enough for what you describe. A miscompiled qemu will generate acpi tables that differ from expected ones and the simple bit for bit test will fail. No need to run acpipica within guest. > -- > |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| > |: https://libvirt.org -o- https://fstop138.berrange.com :| > |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|