mbox series

[0/8] tests: Make expliction defaults for tests

Message ID 20220902165126.1482-1-quintela@redhat.com
Headers show
Series tests: Make expliction defaults for tests | expand

Message

Juan Quintela Sept. 2, 2022, 4:51 p.m. UTC
Hi

For a long, long time I have had local hacks on my tree to be able to
run "make tests" when I have a minimal configure guest.  This is a
first try to upstream some of it.

- by default we always setup -display none (it already was the
  default, but some places added it anyways)

- by default we always setup -net none.  Not clear what was the
  default, but no tests use the default net, so it is safe change and
  now it is explicit.

- by default we always setup -vga none.  This is a complete difference
  can of worms.  Every tests that use vga already set vga correctly,
  so this is quite obvious, right?  Now they are acpi tables.  They
  are a mess.  And basically this means remove a device for each one
  of them.  Why going through all the trouble?  Because while I am
  develping, I normall compile out vga.

- Fix several error strings that were set with copy paste.

- replication test requires CONFIG_REPLICATION.
- test-crypto-secret requires CONFIG_SECRET_KEYRING.

Please review.  Except for the acpi changes (that I hope I have done
right following the instructions) the rest is quite obvious.

Later, Juan.

Juan Quintela (8):
  qtest: "-display none" is set in qtest_init()
  qtest: Set "-net none" in qtest_init()
  tests/acpi: The new default is -vga none
  tests/qtest: Add -vga none by default
  tests/acpi: Regenerate all needed tables
  tests: Fix error strings
  meson-build: Enable CONFIG_REPLICATION only when replication is set
  meson-build: test-crypto-secret depends on CONFIG_SECRET_KEYRING

 meson.build                           |   2 +-
 tests/qtest/bios-tables-test.c        |   2 +-
 tests/qtest/boot-serial-test.c        |   4 ++--
 tests/qtest/dbus-display-test.c       |   2 +-
 tests/qtest/display-vga-test.c        |  12 ++++++------
 tests/qtest/e1000-test.c              |   2 +-
 tests/qtest/es1370-test.c             |   2 +-
 tests/qtest/fuzz-lsi53c895a-test.c    |   2 +-
 tests/qtest/fuzz-megasas-test.c       |   2 +-
 tests/qtest/fuzz-sb16-test.c          |   6 +++---
 tests/qtest/fuzz-sdcard-test.c        |   6 +++---
 tests/qtest/fuzz-virtio-scsi-test.c   |   2 +-
 tests/qtest/fuzz-xlnx-dp-test.c       |   2 +-
 tests/qtest/fuzz/generic_fuzz.c       |   3 +--
 tests/qtest/fuzz/i440fx_fuzz.c        |   2 +-
 tests/qtest/fuzz/qos_fuzz.c           |   2 +-
 tests/qtest/libqtest.c                |   2 ++
 tests/data/acpi/pc/DSDT               | Bin 5987 -> 5992 bytes
 tests/data/acpi/pc/DSDT.acpierst      | Bin 5954 -> 5959 bytes
 tests/data/acpi/pc/DSDT.acpihmat      | Bin 7312 -> 7317 bytes
 tests/data/acpi/pc/DSDT.bridge        | Bin 8653 -> 8658 bytes
 tests/data/acpi/pc/DSDT.cphp          | Bin 6451 -> 6456 bytes
 tests/data/acpi/pc/DSDT.dimmpxm       | Bin 7641 -> 7646 bytes
 tests/data/acpi/pc/DSDT.hpbridge      | Bin 5954 -> 5959 bytes
 tests/data/acpi/pc/DSDT.hpbrroot      | Bin 3069 -> 3023 bytes
 tests/data/acpi/pc/DSDT.ipmikcs       | Bin 6059 -> 6064 bytes
 tests/data/acpi/pc/DSDT.memhp         | Bin 7346 -> 7351 bytes
 tests/data/acpi/pc/DSDT.nohpet        | Bin 5845 -> 5850 bytes
 tests/data/acpi/pc/DSDT.numamem       | Bin 5993 -> 5998 bytes
 tests/data/acpi/pc/DSDT.roothp        | Bin 6195 -> 6151 bytes
 tests/data/acpi/pc/ERST.acpierst      | Bin 912 -> 912 bytes
 tests/data/acpi/q35/DMAR.dmar         | Bin 120 -> 112 bytes
 tests/data/acpi/q35/DSDT              | Bin 8274 -> 8228 bytes
 tests/data/acpi/q35/DSDT.acpierst     | Bin 8291 -> 8245 bytes
 tests/data/acpi/q35/DSDT.acpihmat     | Bin 9599 -> 9553 bytes
 tests/data/acpi/q35/DSDT.applesmc     | Bin 8320 -> 8274 bytes
 tests/data/acpi/q35/DSDT.bridge       | Bin 10988 -> 10944 bytes
 tests/data/acpi/q35/DSDT.cphp         | Bin 8738 -> 8692 bytes
 tests/data/acpi/q35/DSDT.cxl          | Bin 9600 -> 9502 bytes
 tests/data/acpi/q35/DSDT.dimmpxm      | Bin 9928 -> 9882 bytes
 tests/data/acpi/q35/DSDT.ipmibt       | Bin 8349 -> 8303 bytes
 tests/data/acpi/q35/DSDT.ipmismbus    | Bin 8363 -> 8317 bytes
 tests/data/acpi/q35/DSDT.ivrs         | Bin 8291 -> 8245 bytes
 tests/data/acpi/q35/DSDT.memhp        | Bin 9633 -> 9587 bytes
 tests/data/acpi/q35/DSDT.mmio64       | Bin 9404 -> 9358 bytes
 tests/data/acpi/q35/DSDT.multi-bridge | Bin 8568 -> 8524 bytes
 tests/data/acpi/q35/DSDT.nohpet       | Bin 8132 -> 8086 bytes
 tests/data/acpi/q35/DSDT.numamem      | Bin 8280 -> 8234 bytes
 tests/data/acpi/q35/DSDT.pvpanic-isa  | Bin 8375 -> 8329 bytes
 tests/data/acpi/q35/DSDT.tis.tpm12    | Bin 8880 -> 8834 bytes
 tests/data/acpi/q35/DSDT.tis.tpm2     | Bin 8906 -> 8860 bytes
 tests/data/acpi/q35/DSDT.viot         | Bin 9383 -> 9339 bytes
 tests/data/acpi/q35/DSDT.xapic        | Bin 35637 -> 35591 bytes
 tests/data/acpi/q35/ERST.acpierst     | Bin 912 -> 912 bytes
 tests/data/acpi/q35/IVRS.ivrs         | Bin 104 -> 100 bytes
 tests/data/acpi/q35/VIOT.viot         | Bin 112 -> 112 bytes
 tests/unit/meson.build                |   4 +++-
 57 files changed, 31 insertions(+), 28 deletions(-)

Comments

Alexander Bulekov Sept. 2, 2022, 5:16 p.m. UTC | #1
On 220902 1851, Juan Quintela wrote:
> Hi
> 
> For a long, long time I have had local hacks on my tree to be able to
> run "make tests" when I have a minimal configure guest.  This is a
> first try to upstream some of it.
> 
> - by default we always setup -display none (it already was the
>   default, but some places added it anyways)
> 
> - by default we always setup -net none.  Not clear what was the
>   default, but no tests use the default net, so it is safe change and
>   now it is explicit.
> 
> - by default we always setup -vga none.  This is a complete difference
>   can of worms.  Every tests that use vga already set vga correctly,
>   so this is quite obvious, right?  Now they are acpi tables.  They
>   are a mess.  And basically this means remove a device for each one
>   of them.  Why going through all the trouble?  Because while I am
>   develping, I normall compile out vga.
> 
> - Fix several error strings that were set with copy paste.
> 
> - replication test requires CONFIG_REPLICATION.
> - test-crypto-secret requires CONFIG_SECRET_KEYRING.
> 
> Please review.  Except for the acpi changes (that I hope I have done
> right following the instructions) the rest is quite obvious.

I think this might break some of the fuzz regression tests, because they
have "baked-in" PCI configuration commands with hard-coded PCI
addresses, which will shift around if some device is removed (e.g. with
-net none). Probably the fix is to add addr=... to the -device parameter
in the fuzz tests to keep the PCI address stable.
-Alex

> 
> Later, Juan.
> 
> Juan Quintela (8):
>   qtest: "-display none" is set in qtest_init()
>   qtest: Set "-net none" in qtest_init()
>   tests/acpi: The new default is -vga none
>   tests/qtest: Add -vga none by default
>   tests/acpi: Regenerate all needed tables
>   tests: Fix error strings
>   meson-build: Enable CONFIG_REPLICATION only when replication is set
>   meson-build: test-crypto-secret depends on CONFIG_SECRET_KEYRING
> 
>  meson.build                           |   2 +-
>  tests/qtest/bios-tables-test.c        |   2 +-
>  tests/qtest/boot-serial-test.c        |   4 ++--
>  tests/qtest/dbus-display-test.c       |   2 +-
>  tests/qtest/display-vga-test.c        |  12 ++++++------
>  tests/qtest/e1000-test.c              |   2 +-
>  tests/qtest/es1370-test.c             |   2 +-
>  tests/qtest/fuzz-lsi53c895a-test.c    |   2 +-
>  tests/qtest/fuzz-megasas-test.c       |   2 +-
>  tests/qtest/fuzz-sb16-test.c          |   6 +++---
>  tests/qtest/fuzz-sdcard-test.c        |   6 +++---
>  tests/qtest/fuzz-virtio-scsi-test.c   |   2 +-
>  tests/qtest/fuzz-xlnx-dp-test.c       |   2 +-
>  tests/qtest/fuzz/generic_fuzz.c       |   3 +--
>  tests/qtest/fuzz/i440fx_fuzz.c        |   2 +-
>  tests/qtest/fuzz/qos_fuzz.c           |   2 +-
>  tests/qtest/libqtest.c                |   2 ++
>  tests/data/acpi/pc/DSDT               | Bin 5987 -> 5992 bytes
>  tests/data/acpi/pc/DSDT.acpierst      | Bin 5954 -> 5959 bytes
>  tests/data/acpi/pc/DSDT.acpihmat      | Bin 7312 -> 7317 bytes
>  tests/data/acpi/pc/DSDT.bridge        | Bin 8653 -> 8658 bytes
>  tests/data/acpi/pc/DSDT.cphp          | Bin 6451 -> 6456 bytes
>  tests/data/acpi/pc/DSDT.dimmpxm       | Bin 7641 -> 7646 bytes
>  tests/data/acpi/pc/DSDT.hpbridge      | Bin 5954 -> 5959 bytes
>  tests/data/acpi/pc/DSDT.hpbrroot      | Bin 3069 -> 3023 bytes
>  tests/data/acpi/pc/DSDT.ipmikcs       | Bin 6059 -> 6064 bytes
>  tests/data/acpi/pc/DSDT.memhp         | Bin 7346 -> 7351 bytes
>  tests/data/acpi/pc/DSDT.nohpet        | Bin 5845 -> 5850 bytes
>  tests/data/acpi/pc/DSDT.numamem       | Bin 5993 -> 5998 bytes
>  tests/data/acpi/pc/DSDT.roothp        | Bin 6195 -> 6151 bytes
>  tests/data/acpi/pc/ERST.acpierst      | Bin 912 -> 912 bytes
>  tests/data/acpi/q35/DMAR.dmar         | Bin 120 -> 112 bytes
>  tests/data/acpi/q35/DSDT              | Bin 8274 -> 8228 bytes
>  tests/data/acpi/q35/DSDT.acpierst     | Bin 8291 -> 8245 bytes
>  tests/data/acpi/q35/DSDT.acpihmat     | Bin 9599 -> 9553 bytes
>  tests/data/acpi/q35/DSDT.applesmc     | Bin 8320 -> 8274 bytes
>  tests/data/acpi/q35/DSDT.bridge       | Bin 10988 -> 10944 bytes
>  tests/data/acpi/q35/DSDT.cphp         | Bin 8738 -> 8692 bytes
>  tests/data/acpi/q35/DSDT.cxl          | Bin 9600 -> 9502 bytes
>  tests/data/acpi/q35/DSDT.dimmpxm      | Bin 9928 -> 9882 bytes
>  tests/data/acpi/q35/DSDT.ipmibt       | Bin 8349 -> 8303 bytes
>  tests/data/acpi/q35/DSDT.ipmismbus    | Bin 8363 -> 8317 bytes
>  tests/data/acpi/q35/DSDT.ivrs         | Bin 8291 -> 8245 bytes
>  tests/data/acpi/q35/DSDT.memhp        | Bin 9633 -> 9587 bytes
>  tests/data/acpi/q35/DSDT.mmio64       | Bin 9404 -> 9358 bytes
>  tests/data/acpi/q35/DSDT.multi-bridge | Bin 8568 -> 8524 bytes
>  tests/data/acpi/q35/DSDT.nohpet       | Bin 8132 -> 8086 bytes
>  tests/data/acpi/q35/DSDT.numamem      | Bin 8280 -> 8234 bytes
>  tests/data/acpi/q35/DSDT.pvpanic-isa  | Bin 8375 -> 8329 bytes
>  tests/data/acpi/q35/DSDT.tis.tpm12    | Bin 8880 -> 8834 bytes
>  tests/data/acpi/q35/DSDT.tis.tpm2     | Bin 8906 -> 8860 bytes
>  tests/data/acpi/q35/DSDT.viot         | Bin 9383 -> 9339 bytes
>  tests/data/acpi/q35/DSDT.xapic        | Bin 35637 -> 35591 bytes
>  tests/data/acpi/q35/ERST.acpierst     | Bin 912 -> 912 bytes
>  tests/data/acpi/q35/IVRS.ivrs         | Bin 104 -> 100 bytes
>  tests/data/acpi/q35/VIOT.viot         | Bin 112 -> 112 bytes
>  tests/unit/meson.build                |   4 +++-
>  57 files changed, 31 insertions(+), 28 deletions(-)
> 
> -- 
> 2.37.2
>
Thomas Huth Sept. 19, 2022, 6:09 p.m. UTC | #2
On 02/09/2022 19.16, Alexander Bulekov wrote:
> On 220902 1851, Juan Quintela wrote:
>> Hi
>>
>> For a long, long time I have had local hacks on my tree to be able to
>> run "make tests" when I have a minimal configure guest.  This is a
>> first try to upstream some of it.
>>
>> - by default we always setup -display none (it already was the
>>    default, but some places added it anyways)
>>
>> - by default we always setup -net none.  Not clear what was the
>>    default, but no tests use the default net, so it is safe change and
>>    now it is explicit.
>>
>> - by default we always setup -vga none.  This is a complete difference
>>    can of worms.  Every tests that use vga already set vga correctly,
>>    so this is quite obvious, right?  Now they are acpi tables.  They
>>    are a mess.  And basically this means remove a device for each one
>>    of them.  Why going through all the trouble?  Because while I am
>>    develping, I normall compile out vga.
>>
>> - Fix several error strings that were set with copy paste.
>>
>> - replication test requires CONFIG_REPLICATION.
>> - test-crypto-secret requires CONFIG_SECRET_KEYRING.
>>
>> Please review.  Except for the acpi changes (that I hope I have done
>> right following the instructions) the rest is quite obvious.
> 
> I think this might break some of the fuzz regression tests, because they
> have "baked-in" PCI configuration commands with hard-coded PCI
> addresses, which will shift around if some device is removed (e.g. with
> -net none). Probably the fix is to add addr=... to the -device parameter
> in the fuzz tests to keep the PCI address stable.
> -Alex

The patches to default to -net none and -vga none are a good idea, but I 
agree with Alexander - this needs some careful examination of the fuzz tests 
first to see whether the BARs are changed here or not.

  Thomas