[PATCH v3 13/24] tests/functional: Convert the s390x avocado tests into standalone tests

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth These tests use archive.lzma_uncompress() from the Avocado utils, so provide a small helper function for this, based on the standard lzma module from Python instead. And while we're at it, replace the MD5 hashes in the topology test with proper SHA256 hashes, since MD5 should n

[PATCH v3 17/24] tests/functional: Convert the virtio_gpu avocado test into a standalone test

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Nothing thrilling in here, it's just a straight forward conversion. Signed-off-by: Thomas Huth --- tests/functional/meson.build | 1 + .../test_virtio_gpu.py} | 64 +-- 2 files changed, 30 insertions(+), 35 deletions(-)

[PATCH v3 18/24] tests/functional: Convert most ppc avocado tests into standalone tests

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Nothing thrilling in here, just straight forward conversions. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Thomas Huth --- MAINTAINERS | 8 +-- tests/functional/meson.build | 11 .../test_ppc64_powernv.py}

[PATCH v3 00/24] Convert avocado tests to normal Python unittests

2024-07-30 Thread Daniel P . Berrangé
instead of wget for downloading - Lots of makefile / meson integration improvements - Converted more tests - Update MAINTAINERS file accordingly - Added a patch to run check-functional in the gitlab-CI - ... lots of other changes I forgot about ... in fact, I changed so many things that I also did not d

[PATCH v3 15/24] tests/functional: Convert the microblaze avocado tests into standalone tests

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth The machine_microblaze.py file contained two tests, one for each endianess. Since we only support one QEMU target binary per file in the new functional test environment, we have to split this file up into two files now. Signed-off-by: Thomas Huth --- MAINTAINERS

[PATCH v3 19/24] tests/functional: Convert the ppc_amiga avocado test into a standalone test

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Use the Python standard zipfile module instead of avocado.utils for extracting the ZIP file that we download here, and use the standard subprocess module for running the "tail" command. Signed-off-by: Thomas Huth --- tests/avocado/ppc_amiga.py | 38 ---

[PATCH v3 06/24] tests/functional: Convert simple avocado tests into standalone python tests

2024-07-30 Thread Daniel P . Berrangé
be run by executing them directly. Reviewed-by: Daniel P. Berrangé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Thomas Huth --- tests/functional/meson.build | 5 ++ .../test_cpu_queries.py} | 7 ++- .../test_empty_cpu_model.py} | 7 ++- .

[PATCH v3 01/24] python: Install pycotap in our venv if necessary

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth The upcoming functional tests will require pycotap for providing TAP output from the python-based tests. Since we want to be able to run some of the tests offline by default, too, let's install it along with meson in our venv if necessary (it's size is only 5 kB, so adding the w

[PATCH v3 21/24] tests/functional: Convert the m68k nextcube test with tesseract

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth The code that handles running of tesseract needs to be tweaked a little bit to be able to run without the functions from avocado.utils, and while we're at it, drop some legacy stuff that was still there due to Tesseract 3 support that we already dropped a while ago. Signed-off-

[PATCH v3 10/24] tests/functional: Convert some tests that download files via fetch_asset()

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Now that we've got the Asset class with pre-caching, we can convert some Avocado tests that use fetch_asset() for downloading their required files. Signed-off-by: Thomas Huth --- MAINTAINERS | 12 ++--- tests/avocado/machine_mips_loongson3v.p

[PATCH v3 04/24] tests/Makefile.include: Increase the level of indentation in the help text

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth The next patch is going to add some entries that need more space between the command and the help text, so let's increase the indentation here first. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Thomas Huth --- tests/Makefile.include | 30 +++---

[PATCH v3 12/24] tests/functional: Convert some avocado tests that needed avocado.utils.archive

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Instead of using the "archive" module from avocado.utils, switch these tests to use the new wrapper function that is based on the "tarfile" module instead. Reviewed-by: Daniel P. Berrangé Signed-off-by: Thomas Huth --- MAINTAINERS

[PATCH v3 11/24] tests/functional: Add a function for extracting files from an archive

2024-07-30 Thread Daniel P . Berrangé
provide us with this functionality, so let's just add a nice wrapper function around that. Reviewed-by: Daniel P. Berrangé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Thomas Huth --- tests/functional/qemu_test/utils.py | 21 + 1 file changed, 21 insertions(+) cre

[PATCH v3 14/24] tests/functional: Convert the x86_cpu_model_versions test

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Nothing thrilling in here, it's just a straight forward conversion. Signed-off-by: Thomas Huth --- tests/functional/meson.build | 1 + .../test_x86_cpu_model_versions.py} | 63 ++- 2 files changed, 20 insertions(+), 44 deletions(-)

[PATCH v3 22/24] tests/functional: Convert the acpi-bits test into a standalone test

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Mostly a straight-forward conversion. Looks like we can simply drop the avocado datadrainer stuff when not using the avocado framework anymore. Signed-off-by: Thomas Huth --- .../acpi-bits/bits-config/bits-cfg.txt| 0 .../acpi-bits/bits-tests/smbios.py2 |

[PATCH v3 09/24] tests/functional: enable pre-emptive caching of assets

2024-07-30 Thread Daniel P . Berrangé
functional Signed-off-by: Daniel P. Berrangé --- tests/Makefile.include | 3 ++- tests/functional/meson.build | 33 +++-- tests/functional/qemu_test/asset.py| 34 ++ tests/functional/qemu_test/testcase.py | 8 ++ 4 fil

[PATCH v3 03/24] tests/functional: Set up logging

2024-07-30 Thread Daniel P . Berrangé
From: Thomas Huth Create log files for each test separately, one file that contains the basic logging and one that contains the console output. Reviewed-by: Daniel P. Berrangé Signed-off-by: Thomas Huth --- tests/functional/qemu_test/testcase.py | 27 +- 1 file

Re: [PATCH v2 1/2] crypto: add support for accumulative hashing

2024-07-30 Thread Daniel P . Berrangé
On Tue, Jul 30, 2024 at 05:58:38PM +0200, Cédric Le Goater wrote: > On 7/29/24 21:00, Alejandro Zeise wrote: > > This change adds an accumulative hashing function > > (qcrypto_hash_accumulate_bytesv) and implementation > > for each of the crypto library backends that QEMU supports. > > > > The QCr

Re: [PATCH v2 1/2] crypto: add support for accumulative hashing

2024-07-30 Thread Daniel P . Berrangé
On Mon, Jul 29, 2024 at 07:00:34PM +, Alejandro Zeise wrote: > This change adds an accumulative hashing function > (qcrypto_hash_accumulate_bytesv) and implementation > for each of the crypto library backends that QEMU supports. > > The QCrypto API did not support hashing in an accumulative mo

Re: [PATCH] sm4:Adjust the naming of SM4 encryption method

2024-07-30 Thread Daniel P . Berrangé
On Tue, Jul 30, 2024 at 07:38:50PM +0800, luzhipeng wrote: > With reference to the naming conventions of other encryption algorithms, > the name of SM4 is modified.So libvirt and qemu are compatible. > > Signed-off-by: luzhipeng > --- > crypto/block-luks.c | 2 +- > crypto/cipher-gcr

Re: [PATCH] osdep.h: Clean up no-longer-needed back-compat for macOS 10

2024-07-30 Thread Daniel P . Berrangé
macOS?". > > Signed-off-by: Peter Maydell > --- > include/qemu/osdep.h | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) Reviewed-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://li

Re: [PATCH 01/18] qapi: Smarter camel_to_upper() to reduce need for 'prefix'

2024-07-30 Thread Daniel P . Berrangé
| 1 + > qapi/migration.json | 1 + > qapi/ui.json | 2 ++ > scripts/qapi/common.py | 42 ++++++---------- > scripts/qapi/schema.py | 2 +- > tests/qapi-schema/alternate-array.out| 1 -

Re: [PATCH 09/18] qapi/machine: Rename CpuS390* to S390Cpu, and drop 'prefix'

2024-07-30 Thread Daniel P . Berrangé
nclude/hw/qdev-properties-system.h | 2 +- > include/hw/s390x/cpu-topology.h | 2 +- > target/s390x/cpu.h | 2 +- > hw/core/qdev-properties-system.c| 6 +++--- > hw/s390x/cpu-topology.c | 6 +++--- > 9 files changed, 23 insertions(+), 26

Re: [PATCH 18/18] qapi/cryptodev: Rename QCryptodevBackendAlgType to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
yptodev.c | 6 +++--- > hw/virtio/virtio-crypto.c| 14 +++--- > 6 files changed, 18 insertions(+), 19 deletions(-) Reviewed-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |:

Re: [PATCH 17/18] qapi/cryptodev: Drop unwanted 'prefix'

2024-07-30 Thread Daniel P . Berrangé
yptodev-builtin.c| 8 > backends/cryptodev-lkcf.c | 2 +- > backends/cryptodev-vhost-user.c | 6 +++--- > backends/cryptodev.c| 6 +++--- > hw/virtio/virtio-crypto.c | 10 +++++- > 6 files changed, 16 insertions(+), 17 deletions(-) Re

Re: [PATCH 16/18] qapi/crypto: Rename QCryptoAFAlg to QCryptoAFAlgo

2024-07-30 Thread Daniel P . Berrangé
> crypto/cipher-afalg.c | 12 ++-- > crypto/hash-afalg.c | 14 +++--- > 5 files changed, 25 insertions(+), 25 deletions(-) Acked-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |:

Re: [PATCH 15/18] qapi/crypto: Rename QCryptoRSAPaddingAlgorithm to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
nc| 18 +- > crypto/akcipher-nettle.c.inc| 18 +- > 7 files changed, 41 insertions(+), 42 deletions(-) Acked-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dber

Re: [PATCH 14/18] qapi/crypto: Rename QCryptoAkCipherAlgorithm to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
/test-crypto-akcipher.c | 10 +- > crypto/akcipher-gcrypt.c.inc | 4 ++-- > crypto/akcipher-nettle.c.inc| 4 ++-- > 9 files changed, 19 insertions(+), 20 deletions(-) Acked-by: Daniel P. Berrangé With regards, Daniel -- |: https://berrange.com

Re: [PATCH 13/18] qapi/crypto: Rename QCryptoIVGenAlgorithm to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
.h | 2 +- > include/crypto/ivgen.h | 14 +++--- > crypto/block-luks.c| 16 > crypto/block-qcow.c| 2 +- > crypto/ivgen.c | 10 +- > tests/unit/test-crypto-block.c | 14 +++--- >

Re: [PATCH 12/18] qapi/crypto: Rename QCryptoCipherAlgorithm to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
| 18 +++--- > crypto/cipher-gcrypt.c.inc| 56 > crypto/cipher-gnutls.c.inc| 38 +-- > crypto/cipher-nettle.c.inc| 58 - > 26 files changed, 277 insertions(+), 278 deletions(-) Acked-by: Daniel P. Berrangé W

Re: [PATCH 11/18] qapi/crypto: Rename QCryptoHashAlgorithm to *Algo, and drop prefix

2024-07-30 Thread Daniel P . Berrangé
+++ > tests/unit/test-crypto-hmac.c | 16 - > tests/unit/test-crypto-ivgen.c | 8 ++--- > tests/unit/test-crypto-pbkdf.c | 44 - > ui/vnc.c | 2 +- > util/hbitmap.c

Re: [PATCH 10/18] qapi/crypto: Drop unwanted 'prefix'

2024-07-30 Thread Daniel P . Berrangé
pher-nettle.c.inc| 8 +++ > crypto/rsakey-builtin.c.inc | 4 ++-- > crypto/rsakey-nettle.c.inc | 4 ++-- > 9 files changed, 32 insertions(+), 33 deletions(-) Acked-by: Daniel P. Berrangé With regards, Daniel -- |: https://ber

Re: [PATCH 05/18] qapi/crypto: Drop temporary 'prefix'

2024-07-30 Thread Daniel P . Berrangé
nit/test-crypto-block.c | 14 +++--- > 7 files changed, 22 insertions(+), 24 deletions(-) Acked-by: Daniel P. Berrangé 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 :|

Re: [PATCH v2 4/4] virtio-net: Add support for USO features

2024-07-29 Thread Daniel P . Berrangé
On Mon, Jul 29, 2024 at 01:00:30PM -0400, Peter Xu wrote: > On Mon, Jul 29, 2024 at 04:58:03PM +0100, Daniel P. Berrangé wrote: > > > > We've got two mutually conflicting goals with the machine type > > definitions. > > > > Primarily we use them

Re: [PATCH v2 4/4] virtio-net: Add support for USO features

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 04:47:40PM -0400, Peter Xu wrote: > On Fri, Jul 26, 2024 at 04:17:12PM +0100, Daniel P. Berrangé wrote: > > > > In terms of launching QEMU I'd imagine: > > > > $QEMU -machine pc-q35-9.1 -platform linux-6.9 ...args... > > > &g

Re: [PULL 00/14] Docs / testing patches for 2024-07-29

2024-07-29 Thread Daniel P . Berrangé
On Mon, Jul 29, 2024 at 05:27:00PM +0200, Philippe Mathieu-Daudé wrote: > The following changes since commit 93b799fafd9170da3a79a533ea6f73a18de82e22: > > Merge tag 'pull-ppc-for-9.1-2-20240726-1' of > https://gitlab.com/npiggin/qemu into staging (2024-07-26 15:10:45 +1000) > > are available i

Re: [PATCH v1 00/11] Convert avocado tests to normal Python unittests

2024-07-29 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 10:21:54AM -0400, Cleber Rosa wrote: > On Tue, Jul 16, 2024 at 7:28 AM Thomas Huth wrote: > > There have been several attempts to update the test suite in QEMU > > to a newer version of Avocado, but so far no attempt has successfully > > been merged yet. > > > > So, we've

Re: [PATCH 12/13] Bump avocado to 103.0

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:37AM -0400, Cleber Rosa wrote: > This bumps Avocado to latest the LTS release. > > An LTS release is one that can receive bugfixes and guarantees > stability for a much longer period and has incremental minor releases > made. > > Even though the 103.0 LTS release is

Re: [PATCH 11/13] tests/avocado/machine_aarch64_sbsaref.py: allow for rw usage of image

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:36AM -0400, Cleber Rosa wrote: > When the OpenBSD based tests are run in parallel, the previously > single instance of the image would become corrupt. Let's give each > test its own copy. > > Signed-off-by: Cleber Rosa > --- > tests/avocado/machine_aarch64_sbsaref.

Re: [PATCH 10/13] tests/avocado/tuxrun_baselines.py: use Avocado's zstd support

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:35AM -0400, Cleber Rosa wrote: > Signed-off-by: Cleber Rosa > --- > tests/avocado/tuxrun_baselines.py | 16 ++-- > 1 file changed, 6 insertions(+), 10 deletions(-) Reviewed-by: Daniel P. Berrangé With regards, Daniel -- |: https://

Re: [PATCH 09/13] tests/avocado/boot_xen.py: fetch kernel during test setUp()

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:34AM -0400, Cleber Rosa wrote: > The kernel is a common blob used in all tests. By moving it to the > setUp() method, the "fetch asset" plugin will recognize the kernel and > attempt to fetch it and cache it before the tests are started. The other tests don't call f

Re: [PATCH 08/13] testa/avocado: test_arm_emcraft_sf2: handle RW requirements for asset

2024-07-29 Thread Daniel P . Berrangé
le changed, 4 insertions(+), 2 deletions(-) Reviewed-by: Daniel P. Berrangé 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 :|

Re: [PATCH 07/13] tests/avocado/kvm_xen_guest.py: cope with asset RW requirements

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:32AM -0400, Cleber Rosa wrote: > Some of these tests actually require the root filesystem image, > obtained through Avocado's asset feature and kept in a common cache > location, to be writable. > > This makes a distinction between the tests that actually have this >

Re: [PATCH 06/13] tests/avocado: use more distinct names for assets

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:31AM -0400, Cleber Rosa wrote: > Avocado's asset system will deposit files in a cache organized either > by their original location (the URI) or by their names. Because the > cache (and the "by_name" sub directory) is common across tests, it's a > good idea to make th

Re: [PATCH 05/13] tests/avocado: machine aarch64: standardize location and RO access

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:30AM -0400, Cleber Rosa wrote: > The tests under machine_aarch64_virt.py and machine_aarch64_sbsaref.py > should not be writing to the ISO files. By adding "media=cdrom" the > "ro" is autmatically set. > > While at it, let's use a single code style and hash for the I

Re: [PATCH 03/13] tests/avocado/intel_iommu.py: increase timeout

2024-07-29 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:44:28AM -0400, Cleber Rosa wrote: > Based on many runs, the average run time for these 4 tests is around > 250 seconds, with 320 seconds being the ceiling. In any way, the > default 120 seconds timeout is inappropriate in my experience. > Let's increase the timeout so th

Re: [PATCH] .gitlab-ci.d/cirrus.yml: Shorten the runtime of the macOS and FreeBSD jobs

2024-07-26 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 11:18:43AM +0200, Thomas Huth wrote: > > Looks like the reduction of this patch was not enough, we've run out of > Cirrus-CI compute time again ... does anybody have additional ideas how we > could avoid that in the future? QEMU keeps getting bigger, so our attempts to cut

Re: [PATCH v2 1/2] qom/object, qdev: move globals functions to object.c

2024-07-26 Thread Daniel P . Berrangé
->hotplugged is checked > to determine if object_apply_global_props() will receive a NULL or an > &error_fatal errp. The function now receives an Object and an errp, and > logic using dev->hotplugged is moved to its caller (device_post_init()). > > Suggested-by: Daniel P. Be

Re: [PATCH v2 4/4] virtio-net: Add support for USO features

2024-07-26 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 10:43:42AM -0400, Peter Xu wrote: > On Fri, Jul 26, 2024 at 09:48:02AM +0100, Daniel P. Berrangé wrote: > > On Fri, Jul 26, 2024 at 09:03:24AM +0200, Thomas Huth wrote: > > > On 26/07/2024 08.08, Michael S. Tsirkin wrote: > > > > On Thu, Ju

Re: [PATCH v2 4/4] virtio-net: Add support for USO features

2024-07-26 Thread Daniel P . Berrangé
On Fri, Jul 26, 2024 at 09:03:24AM +0200, Thomas Huth wrote: > On 26/07/2024 08.08, Michael S. Tsirkin wrote: > > On Thu, Jul 25, 2024 at 06:18:20PM -0400, Peter Xu wrote: > > > On Tue, Aug 01, 2023 at 01:31:48AM +0300, Yuri Benditovich wrote: > > > > USO features of virtio-net device depend on ker

Re: [PATCH] ptp: Add vDSO-style vmclock support

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 12:53:34PM +0100, David Woodhouse wrote: > On Thu, 2024-07-25 at 12:31 +0100, Daniel P. Berrangé wrote: > > On Thu, Jul 25, 2024 at 10:56:05AM +0100, David Woodhouse wrote: > > > Hi Michael, thanks for the review! > > > > > > On Thu,

Re: [PATCH] misc: introduce strim-memory qapi to support free memory trimming

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 01:35:21PM +0200, Markus Armbruster wrote: > Guoyi Tu writes: > > > In the test environment, we conducted IO stress tests on all storage disks > > within a virtual machine that had five storage devices mounted.During > > testing, > > we found that the qemu process allocat

Re: [PATCH] ptp: Add vDSO-style vmclock support

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 10:56:05AM +0100, David Woodhouse wrote: > Hi Michael, thanks for the review! > > On Thu, 2024-07-25 at 01:48 -0400, Michael S. Tsirkin wrote: > > On Wed, Jul 24, 2024 at 06:16:37PM +0100, David Woodhouse wrote: > > > From: David Woodhouse > > > > > > The vmclock "device"

Re: [PATCH v2 00/23] Convert avocado tests to normal Python unittests

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 08:42:31PM +1000, Richard Henderson wrote: > On 7/25/24 19:55, Daniel P. Berrangé wrote: > > On Thu, Jul 25, 2024 at 09:35:22AM +1000, Richard Henderson wrote: > > > On 7/25/24 03:52, Thomas Huth wrote: > > > > The Avocado v88 that we us

Re: [PATCH 0/2] gitlab: expose installed package info in build logs

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 12:42:18PM +0300, Manos Pitsidianakis wrote: > Hello Daniel, > > On Wed, 24 Jul 2024 12:55, "Daniel P. Berrangé" wrote: > > Many times we see a build job start failing, we wonder if the installed > > packages have changed since the la

Re: [PATCH v2 00/23] Convert avocado tests to normal Python unittests

2024-07-25 Thread Daniel P . Berrangé
On Thu, Jul 25, 2024 at 09:35:22AM +1000, Richard Henderson wrote: > On 7/25/24 03:52, Thomas Huth wrote: > > The Avocado v88 that we use in QEMU is already on a life support > > system: It is not supported by upstream anymore, and with the latest > > versions of Python, it won't work anymore since

Re: [PATCH v4 13/17] backends/confidential-guest-support: Add set_guest_policy() function

2024-07-24 Thread Daniel P . Berrangé
ific implementation details for each platform. > > Signed-off-by: Roy Hopkins > --- > include/exec/confidential-guest-support.h | 21 + > backends/confidential-guest-support.c | 12 > 2 files changed, 33 insertions(+) Reviewed-by: Daniel P.

Re: [PATCH v4 12/17] docs/interop/firmware.json: Add igvm to FirmwareDevice

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:50PM +0100, Roy Hopkins wrote: > Create an enum entry within FirmwareDevice for 'igvm' to describe that > an IGVM file can be used to map firmware into memory as an alternative > to pre-existing firmware devices. > > Signed-off-by: Roy Hopkins > --- > docs/interop/f

Re: [PATCH v4 11/17] docs/system: Add documentation on support for IGVM

2024-07-24 Thread Daniel P . Berrangé
00644 docs/system/igvm.rst Reviewed-by: Daniel P. Berrangé 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 :|

Re: [PATCH v4 07/17] sev: Update launch_update_data functions to use Error handling

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:45PM +0100, Roy Hopkins wrote: > The class function and implementations for updating launch data return > a code in case of error. In some cases an error message is generated and > in other cases, just the error return value is used. > > This small refactor adds an 'E

Re: [PATCH v4 06/17] sev: Fix error handling in sev_encrypt_flash()

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:44PM +0100, Roy Hopkins wrote: > The function sev_encrypt_flash() checks to see if the return value of > launch_update_data() < 0, but the function returns a non-zero (and not > necessarily negative) result on error. This means that some errors in > updating launch dat

Re: [PATCH v4 05/17] i386/pc_sysfw: Ensure sysfw flash configuration does not conflict with IGVM

2024-07-24 Thread Daniel P . Berrangé
> 1 file changed, 28 insertions(+), 3 deletions(-) Reviewed-by: Daniel P. Berrangé > > diff --git a/hw/i386/pc_sysfw.c b/hw/i386/pc_sysfw.c > index ef80281d28..f5e40b3ef6 100644 > --- a/hw/i386/pc_sysfw.c > +++ b/hw/i386/pc_sysfw.c > @@ -219,7 +219,13 @@ void pc_system_f

Re: [PATCH v4 04/17] hw/i386: Add igvm-cfg object and processing for IGVM files

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:42PM +0100, Roy Hopkins wrote: > An IGVM file contains configuration of guest state that should be > applied during configuration of the guest, before the guest is started. > > This patch allows the user to add an igvm-cfg object to an X86 machine > configuration that

Re: [PATCH v4 03/17] backends/igvm: Add IGVM loader and configuration

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:41PM +0100, Roy Hopkins wrote: > Adds an IGVM loader to QEMU which processes a given IGVM file and > applies the directives within the file to the current guest > configuration. > > The IGVM loader can be used to configure both confidential and > non-confidential gues

Re: [PATCH v4 02/17] backends/confidential-guest-support: Add functions to support IGVM

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:40PM +0100, Roy Hopkins wrote: > In preparation for supporting the processing of IGVM files to configure > guests, this adds a set of functions to ConfidentialGuestSupport > allowing configuration of secure virtual machines that can be > implemented for each supported

Re: [PATCH v4 00/17] Introduce support for IGVM files

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:38PM +0100, Roy Hopkins wrote: > Here is v4 of the set of patches to add support for IGVM files to QEMU. This > is > based on commit 1a2d52c7fc of qemu. > > This version addresses all of the review comments from v3 along with a couple > of > small bug fixes. This is

Re: [PATCH v4 01/17] meson: Add optional dependency on IGVM library

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 03, 2024 at 12:05:39PM +0100, Roy Hopkins wrote: > The IGVM library allows Independent Guest Virtual Machine files to be > parsed and processed. IGVM files are used to configure guest memory > layout, initial processor state and other configuration pertaining to > secure virtual machine

Re: [PATCH 2/8] qapi/qom: Introduce smp-cache object

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 24, 2024 at 01:35:17PM +0200, Markus Armbruster wrote: > Zhao Liu writes: > > > Hi Markus, > >> SmpCachesProperties and SmpCacheProperties would put the singular > >> vs. plural where it belongs. Sounds a bit awkward to me, though. > >> Naming is hard. > > > > For SmpCachesProperties

Re: [PATCH] gitlab-ci: Use -fno-sanitize=function in the clang-user job

2024-07-24 Thread Daniel P . Berrangé
On Wed, Jul 24, 2024 at 09:25:42AM +1000, Richard Henderson wrote: > With -fsanitize=undefined, which implies -fsanitize=function, > clang will add a "type signature" before functions. > It accesses funcptr-8 and funcptr-4 to do so. > > The generated TCG prologue is directly on a page boundary, >

[PATCH 0/2] gitlab: expose installed package info in build logs

2024-07-24 Thread Daniel P . Berrangé
is intended to be output in the build phase, so record the packages associated with the build. This adds packages.txt to the manually written containers, and modifies the build jobs to display this content. This will improve our future debuggability of CI problems. Daniel P. Berrangé (2

[PULL 10/11] crypto: push error reporting into TLS session I/O APIs

2024-07-24 Thread Daniel P . Berrangé
ession I/O APIs gives more detailed error information. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Daniel P. Berrangé --- crypto/tlssession.c | 60 ++--- include/crypto/tlssession.h | 23 +++--- io/channel-tls.c

[PATCH 1/2] gitlab: record installed packages in /packages.txt in containers

2024-07-24 Thread Daniel P . Berrangé
ntainer is often lost. This extends the manually written dockerfiles to also create the /packages.txt file. Signed-off-by: Daniel P. Berrangé --- tests/docker/dockerfiles/debian-all-test-cross.docker| 3 ++- tests/docker/dockerfiles/debian-hexagon-cross.docker | 3 ++- tests/docker/d

[PATCH 2/2] gitlab: display /packages.txt in build jobs

2024-07-24 Thread Daniel P . Berrangé
ntainer is often lost. Signed-off-by: Daniel P. Berrangé --- .gitlab-ci.d/buildtest-template.yml | 1 + .gitlab-ci.d/crossbuild-template.yml | 2 ++ 2 files changed, 3 insertions(+) diff --git a/.gitlab-ci.d/buildtest-template.yml b/.gitlab-ci.d/buildtest-template.yml index 8f7ebfaed8..844c266

[PULL 08/11] chardev: add tracing of socket error conditions

2024-07-24 Thread Daniel P . Berrangé
This adds trace points to every error scenario in the chardev socket backend that can lead to termination of the connection. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Daniel P. Berrangé --- chardev/char-socket.c | 37 ++--- chardev/trace-events | 10

[PULL 05/11] meson.build: fix libgcrypt detection on system without libgcrypt-config

2024-07-24 Thread Daniel P . Berrangé
-config. Auto method for libgcrypt is supported by meson since 0.49.0, which is higher than the version qemu requires. Signed-off-by: Yao Zi Signed-off-by: Daniel P. Berrangé --- meson.build | 1 - 1 file changed, 1 deletion(-) diff --git a/meson.build b/meson.build index 4eca361319..ec6fb7d69c

[PULL 11/11] crypto: propagate errors from TLS session I/O callbacks

2024-07-24 Thread Daniel P . Berrangé
This changes the I/O callbacks in QEMU to stash the "Error" object in the QCryptoTLSSession class, and fetch it when seeing an I/O error returned from GNUTLS, thus preserving useful error messages. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Daniel P. Berrangé --- crypto/tls

[PULL 09/11] crypto: drop gnutls debug logging support

2024-07-24 Thread Daniel P . Berrangé
GNUTLS already supports dynamically enabling its logging at runtime by setting the env var 'GNUTLS_DEBUG_LEVEL=10', so there is no need to re-invent this logic in QEMU in a way that requires a re-compile. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Daniel P. Berrangé --- cry

[PULL 06/11] qapi: drop unused QCryptoBlockCreateOptionsLUKS.detached-header

2024-07-24 Thread Daniel P . Berrangé
The 'detached-header' field in QCryptoBlockCreateOptionsLUKS was left over from earlier patch iterations. Acked-by: Markus Armbruster Signed-off-by: Daniel P. Berrangé --- qapi/crypto.json | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/qapi/crypto.j

[PULL 07/11] meson: build chardev trace files when have_block

2024-07-24 Thread Daniel P . Berrangé
wasn't built in a !have_system scenario. Reviewed-by: Marc-André Lureau Signed-off-by: Daniel P. Berrangé --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index ec6fb7d69c..5613b62a4f 100644 --- a/meson.build +++ b/meson.build @@ -3

[PULL 01/11] crypto: Remove 'crypto-tls-x509-helpers.h' from crypto-tls-psk-helpers.c

2024-07-24 Thread Daniel P . Berrangé
crypto-tls-x509-helpers.h:26:10: fatal error: libtasn1.h: No such file or directory 26 | #include | ^~~~ compilation terminated. Fixes: e1a6dc91dd ("crypto: Implement TLS Pre-Shared Keys (PSK).") Suggested-by: Daniel P. Berrangé Reviewed-by: Daniel P

[PULL 03/11] crypto: Allow building with GnuTLS but without Libtasn1

2024-07-24 Thread Daniel P . Berrangé
.1 (cached) Run-time dependency libtasn1 found: NO (tried pkgconfig) ../meson.build:1914:10: ERROR: Dependency "libtasn1" not found, tried pkgconfig Fixes: ba7ed407e6 ("configure, meson: convert libtasn1 detection to meson") Reviewed-by: Daniel P. Berrangé Signed-off-by:

[PULL 04/11] docs/devel: Add introduction to LUKS volume with detached header

2024-07-24 Thread Daniel P . Berrangé
From: Hyman Huang Signed-off-by: Hyman Huang Signed-off-by: Daniel P. Berrangé --- MAINTAINERS | 1 + docs/devel/crypto.rst | 10 ++ docs/devel/index-internals.rst | 1 + docs/devel/luks-detached-header.rst | 182 4

[PULL 02/11] crypto: Restrict pkix_asn1_tab[] to crypto-tls-x509-helpers.c

2024-07-24 Thread Daniel P . Berrangé
From: Philippe Mathieu-Daudé pkix_asn1_tab[] is only accessed by crypto-tls-x509-helpers.c, rename pkix_asn1_tab.c as pkix_asn1_tab.c.inc and include it once. Reviewed-by: Daniel P. Berrangé Signed-off-by: Philippe Mathieu-Daudé [berrange: updated MAINTAINERS for changed filename] Signed-off

[PULL 00/11] Crypto patches

2024-07-24 Thread Daniel P . Berrangé
ypt-config is absent -------- Daniel P. Berrangé (6): qapi: drop unused QCryptoBlockCreateOptionsLUKS.detached-header meson: build chardev trace files when have_block chardev: add tracing of socket error conditions crypto: drop gnutls debug logging support crypto: push erro

Re: [PATCH 1/5] qapi: allow for g_autoptr(Error) usage

2024-07-23 Thread Daniel P . Berrangé
On Tue, Jul 23, 2024 at 01:36:32PM +0200, Markus Armbruster wrote: > Daniel P. Berrangé writes: > > > While common error propagation practice does not require manually > > free'ing of local 'Error' objects, there are some cases where this > > is needed. One

[PATCH] meson: build chardev trace files when have_block

2024-07-23 Thread Daniel P . Berrangé
wasn't built in a !have_system scenario. Signed-off-by: Daniel P. Berrangé --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) This is an add-on needed for: https://lists.nongnu.org/archive/html/qemu-devel/2024-07/msg05068.html since I discovered a tools-only build fails

Re: [RFC PATCH v5 3/8] CI: Add build-system-rust-debian job

2024-07-23 Thread Daniel P . Berrangé
On Tue, Jul 23, 2024 at 01:06:20PM +0300, Manos Pitsidianakis wrote: > On Tue, 23 Jul 2024 11:39, "Daniel P. Berrangé" wrote: > > On Mon, Jul 22, 2024 at 02:43:33PM +0300, Manos Pitsidianakis wrote: > > > Add job that builds with rust support enabled on debian. >

Re: [RFC PATCH v5 3/8] CI: Add build-system-rust-debian job

2024-07-23 Thread Daniel P . Berrangé
On Mon, Jul 22, 2024 at 02:43:33PM +0300, Manos Pitsidianakis wrote: > Add job that builds with rust support enabled on debian. > > Signed-off-by: Manos Pitsidianakis > --- > .gitlab-ci.d/buildtest.yml | 11 +++ > 1 file changed, 11 insertions(+) > > diff --git a/.gitlab-ci.d/buildtest.

Re: [PATCH v4] osdep: add a qemu_close_all_open_fd() helper

2024-07-23 Thread Daniel P . Berrangé
On Tue, Jul 23, 2024 at 09:16:15AM +0200, Clément Léger wrote: > > > On 23/07/2024 08:24, Philippe Mathieu-Daudé wrote: > > Hi Clément, > > > > On 17/7/24 14:45, Clément Léger wrote: > >> Since commit 03e471c41d8b ("qemu_init: increase NOFILE soft limit on > >> POSIX"), the maximum number of fil

Re: [PATCH 3/5] crypto: drop gnutls debug logging support

2024-07-22 Thread Daniel P . Berrangé
On Mon, Jul 22, 2024 at 04:32:23PM +0200, Philippe Mathieu-Daudé wrote: > On 22/7/24 15:16, Daniel P. Berrangé wrote: > > GNUTLS already supports dynamically enabling its logging at runtime by > > setting the env var 'GNUTLS_DEBUG_LEVEL=10', so there is no need to > &g

Re: [PATCH for-9.0] qapi: drop unused QCryptoBlockCreateOptionsLUKS.detached-header

2024-07-22 Thread Daniel P . Berrangé
On Mon, Jul 22, 2024 at 04:07:28PM +0200, Markus Armbruster wrote: > Daniel P. Berrangé writes: > > > On Tue, Mar 19, 2024 at 05:06:07PM +0100, Markus Armbruster wrote: > >> Daniel P. Berrangé writes: > >> > >> > The 'detached-header' field i

[PATCH 0/5] crypto: improve error reporting detail

2024-07-22 Thread Daniel P . Berrangé
This small series came about after struggling to diagnose some problems with TLS, due to unhelpfully generic error messages. Daniel P. Berrangé (5): qapi: allow for g_autoptr(Error) usage chardev: add tracing of socket error conditions crypto: drop gnutls debug logging support crypto

[PATCH 5/5] crypto: propagate errors from TLS session I/O callbacks

2024-07-22 Thread Daniel P . Berrangé
This changes the I/O callbacks in QEMU to stash the "Error" object in the QCryptoTLSSession class, and fetch it when seeing an I/O error returned from GNUTLS, thus preserving useful error messages. Signed-off-by: Daniel P. Berrangé --- crypto/tlssession.c | 71

[PATCH 1/5] qapi: allow for g_autoptr(Error) usage

2024-07-22 Thread Daniel P . Berrangé
the need to manually call 'error_free'. Signed-off-by: Daniel P. Berrangé --- include/qapi/error.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/qapi/error.h b/include/qapi/error.h index 71f8fb2c50..6e429809d8 100644 --- a/include/qapi/error.h +++ b/include/qapi/error.h @@

[PATCH 3/5] crypto: drop gnutls debug logging support

2024-07-22 Thread Daniel P . Berrangé
GNUTLS already supports dynamically enabling its logging at runtime by setting the env var 'GNUTLS_DEBUG_LEVEL=10', so there is no need to re-invent this logic in QEMU in a way that requires a re-compile. Signed-off-by: Daniel P. Berrangé --- crypto/init.c | 11 --- 1 file c

[PATCH 2/5] chardev: add tracing of socket error conditions

2024-07-22 Thread Daniel P . Berrangé
This adds trace points to every error scenario in the chardev socket backend that can lead to termination of the connection. Signed-off-by: Daniel P. Berrangé --- chardev/char-socket.c | 34 +- chardev/trace-events | 10 ++ 2 files changed, 31 insertions

[PATCH 4/5] crypto: push error reporting into TLS session I/O APIs

2024-07-22 Thread Daniel P . Berrangé
ession I/O APIs gives more detailed error information. Signed-off-by: Daniel P. Berrangé --- crypto/tlssession.c | 47 - include/crypto/tlssession.h | 23 ++ io/channel-tls.c| 44 ++ 3 files c

Re: [PATCH for-9.0] qapi: drop unused QCryptoBlockCreateOptionsLUKS.detached-header

2024-07-22 Thread Daniel P . Berrangé
On Tue, Mar 19, 2024 at 05:06:07PM +0100, Markus Armbruster wrote: > Daniel P. Berrangé writes: > > > The 'detached-header' field in QCryptoBlockCreateOptionsLUKS > > was left over from earlier patch iterations. > > > > Signed-off-by: Daniel P. Ber

Re: [PATCH 11/13] crypto/block-luks: make range overlap check more readable

2024-07-22 Thread Daniel P . Berrangé
deletion(-) Reviewed-by: Daniel P. Berrangé 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 :|

Re: [PATCH] tests/avocado: Move LinuxTest related code into a separate file

2024-07-19 Thread Daniel P . Berrangé
- > tests/avocado/intel_iommu.py| 2 +- > tests/avocado/replay_linux.py | 2 +- > tests/avocado/smmu.py | 3 +- > 8 files changed, 262 insertions(+), 244 deletions(-) > create mode 100644 tests/avocado/avocado_qemu/linuxtest.py Reviewed-by: Daniel

<    1   2   3   4   5   6   7   8   9   10   >