Re: [PATCH] migration: Fix parse_ramblock() on overwritten retvals

2023-10-18 Thread Juan Quintela
Peter Xu wrote: > It's possible that some errors can be overwritten with success retval later > on, and then ignored. Always capture all errors and report. > > Reported by Coverity 1522861, but actually I spot one more in the same > function. > > Fixes: CID 1522861 > Signed-off-by: Peter Xu > --

Re: [PATCH v5 5/7] migration: Deprecate old compression method

2023-10-18 Thread Markus Armbruster
Juan Quintela writes: > Markus Armbruster wrote: >> Juan Quintela writes: >> >>> Signed-off-by: Juan Quintela >>> Acked-by: Stefan Hajnoczi >>> Acked-by: Peter Xu > > >>> # @deprecated: Member @disk is deprecated because block migration is. >>> +# Member @compression is deprecated becau

Re: [PATCH 11/12] hw/xen: automatically assign device index to block devices

2023-10-18 Thread Igor Mammedov
On Mon, 16 Oct 2023 16:19:08 +0100 David Woodhouse wrote: > From: David Woodhouse > is this index a user (guest) visible? > There's no need to force the user to assign a vdev. We can automatically > assign one, starting at xvda and searching until we find the first disk > name that's unused.

Re: [PATCH v2 1/4] softmmu/physmem: Warn with ram_block_discard_range() on MAP_PRIVATE file mapping

2023-10-18 Thread David Hildenbrand
On 18.10.23 05:02, Xiaoyao Li wrote: David, On 7/6/2023 3:56 PM, David Hildenbrand wrote: ram_block_discard_range() cannot possibly do the right thing in MAP_PRIVATE file mappings in the general case. To achieve the documented semantics, we also have to punch a hole into the file, possibly mes

Re: [PATCH v7 0/7] Hyper-V Dynamic Memory Protocol driver (hv-balloon 🎈)

2023-10-18 Thread David Hildenbrand
On 28.08.23 18:48, Maciej S. Szmigiero wrote: From: "Maciej S. Szmigiero" This is a continuation of the v6 of the patch series located here: https://lore.kernel.org/qemu-devel/cover.1689786474.git.maciej.szmigi...@oracle.com/ Changes from v6: * Split the hv-balloon driver implementation into

Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-18 Thread CĂ©dric Le Goater
On 10/18/23 04:41, Duan, Zhenzhong wrote: Hi CĂ©dric, -Original Message- From: CĂ©dric Le Goater Sent: Tuesday, October 17, 2023 11:51 PM Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface On 10/16/23 10:31, Zhenzhong Duan wrote: From: E

[PATCH v2 2/2] hw/cxl: Pass NULL for a NULL MemoryRegionOps

2023-10-18 Thread Li Zhijian
a NULL parameter is enough for a NULL MemoryRegionOps Signed-off-by: Li Zhijian --- hw/cxl/cxl-component-utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/cxl/cxl-component-utils.c b/hw/cxl/cxl-component-utils.c index 6214dcdcc12..010ed82edab 100644 --- a/hw/cxl/cxl-

[PATCH v2 1/2] hw/cxl: Pass CXLComponentState to cache_mem_ops

2023-10-18 Thread Li Zhijian
cache_mem_ops.{read,write}() interprets opaque as CXLComponentState(cxl_cstate) instead of ComponentRegisters(cregs). Fortunately, cregs is the first member of cxl_cstate, so their values are the same. Fixes: 9e58f52d3f8 ("hw/cxl/component: Introduce CXL components (8.1.x, 8.2.5)") Signed-off-by:

Re: [PATCH] hw/cxl: Fix opaque type interpret wrongly

2023-10-18 Thread Zhijian Li (Fujitsu)
On 13/10/2023 16:52, Philippe Mathieu-Daudé wrote: > On 13/10/23 03:55, Li Zhijian wrote: >> void cxl_component_register_block_init(Object *obj, >>     CXLComponentState *cxl_cstate, >>     const char *type) >> { >> Comp

[PULL 01/32] iotests: get rid of '..' in path environment output

2023-10-18 Thread Paolo Bonzini
From: John Snow Resolve the build_root before we append more items onto it so that the environment output is more concise with less parent directory confetti in it. Signed-off-by: John Snow Message-ID: <20230621002121.1609612-4-js...@redhat.com> Signed-off-by: Paolo Bonzini --- tests/qemu-iot

[PULL 10/32] docs/sphinx: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- docs/sphinx/hxtool.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/sphinx/hxtool.py b/docs/sphinx/hxtool.py index fb0649a3d5b..9f6b9d87dc

[PULL 02/32] iotests: use the correct python to run linters

2023-10-18 Thread Paolo Bonzini
From: John Snow Whichever python is used to run iotest 297 should be the one used to actually run the linters. Signed-off-by: John Snow Message-ID: <20230621002121.1609612-5-js...@redhat.com> Signed-off-by: Paolo Bonzini --- tests/qemu-iotests/linters.py | 2 +- 1 file changed, 1 insertion(+)

[PULL 05/32] target/i386: check intercept for XSETBV

2023-10-18 Thread Paolo Bonzini
Note that this intercept is special; it is checked before the #GP exception. Signed-off-by: Paolo Bonzini --- target/i386/svm.h | 1 + target/i386/tcg/translate.c | 1 + 2 files changed, 2 insertions(+) diff --git a/target/i386/svm.h b/target/i386/svm.h index f9a785489d8..1bd78447306

[PULL 11/32] target/hexagon: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- target/hexagon/hex_common.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/hexagon/hex_common.py b/target/hexagon/hex_common.py inde

[PULL 07/32] scripts: Mark feature_to_c.py as non-executable to fix a build issue

2023-10-18 Thread Paolo Bonzini
From: Thomas Huth Meson tries to run scripts via the shebang line if they files are marked as executable. If "python3" is not in the $PATH, or if it is a version that is too old, then the script execution fails. We should make sure to run scripts via the python3 interpreter that is used for Meson

[PULL 25/32] configure: remove some dead cruft

2023-10-18 Thread Paolo Bonzini
print_error is only invoked in one place, and $git is unused. Reviewed-by: Thomas Huth Signed-off-by: Paolo Bonzini --- configure | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/configure b/configure index 5c1d618f102..0994f54530c 100755 --- a/configure +++ b/configure

[PULL 18/32] configure: clean up handling of CFI option

2023-10-18 Thread Paolo Bonzini
Avoid that --enable-cfi --disable-cfi leaves b_lto set to true. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Paolo Bonzini --- configure | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/configure b/configure index d6103a0141f..9f782054509 100755 --- a/conf

[PULL 27/32] configure: move environment-specific defaults to config-meson.cross

2023-10-18 Thread Paolo Bonzini
Store the -Werror and SMBD defaults in the machine file, which still allows them to be overridden on the command line and enables automatic parsing of the related options. Signed-off-by: Paolo Bonzini --- configure | 37 +-- scripts/meson-build

[PULL 00/32] x86 and build system changes for 2023-10-18

2023-10-18 Thread Paolo Bonzini
The following changes since commit 800485762e6564e04e2ab315132d477069562d91: Merge tag 'python-pull-request' of https://gitlab.com/jsnow/qemu into staging (2023-10-16 12:37:48 -0400) are available in the Git repository at: https://gitlab.com/bonzini/qemu.git tags/for-upstream for you to fe

[PULL 04/32] target/i386/cpu: Fix CPUID_HT exposure

2023-10-18 Thread Paolo Bonzini
From: Xiaoyao Li When explicitly booting a multiple vcpus vm with "-cpu +ht", it gets warning of warning: host doesn't support requested feature: CPUID.01H:EDX.ht [bit 28] Make CPUID_HT as supported unconditionally can resolve the warning. However it introduces another issue that it also expo

[PULL 08/32] scripts/get_maintainer.pl: don't print parentheses

2023-10-18 Thread Paolo Bonzini
From: Emmanouil Pitsidianakis When called from git-send-email, some results contain unclosed parentheses from the subsystem title, for example: (cc-cmd) Adding cc: qemu-...@nongnu.org (open list:PowerNV (Non-Virt...) from: 'scripts/get_maintainer.pl --nogit-fallback' (cc-cmd) Adding cc:

[PULL 28/32] configure: unify handling of several Debian cross containers

2023-10-18 Thread Paolo Bonzini
The Debian and GNU architecture names match very often, even though there are common cases (32-bit Arm or 64-bit x86) where they do not and other cases in which the GNU triplet is actually a quadruplet. But it is still possible to group the common case into a single case inside probe_target_compile

[PULL 26/32] configure: move target-specific defaults to an external machine file

2023-10-18 Thread Paolo Bonzini
Enable Windows-specific defaults with a machine file, so that related options can be automatically parsed and included in the help message. Signed-off-by: Paolo Bonzini --- configs/meson/windows.txt | 9 + configure | 37 ++- scrip

[PULL 16/32] meson: do not use set10

2023-10-18 Thread Paolo Bonzini
Make all items of config-host.h consistent. To keep the --disable-coroutine-pool code visible to the compiler, mutuate the IS_ENABLED() macro from Linux. Signed-off-by: Paolo Bonzini --- include/qemu/compiler.h | 15 +++ meson.build | 2 +- tests/unit/test-coro

[PULL 21/32] tests/tcg/arm: move non-SVE tests out of conditional

2023-10-18 Thread Paolo Bonzini
test-aes, sha1-vector and sha512-vector need not be conditional on $(CROSS_CC_HAS_SVE), reorganize the "if"s to move them outside. Signed-off-by: Paolo Bonzini --- tests/tcg/aarch64/Makefile.target | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/tests/tcg/aarch64/M

[PULL 12/32] tests/avocado: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- tests/avocado/virtio_check_params.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/avocado/virtio_check_params.py b/tests/avocado/virtio

[PULL 03/32] Revert "configure: Add workaround for ccache and clang"

2023-10-18 Thread Paolo Bonzini
From: Yonggang Luo This reverts commit fd0e60530f10078f488fa3e9591cc7db5732989c. According to https://peter.eisentraut.org/blog/2014/12/01/ccache-and-clang-part-3 it's already fixed in new version of ccache According to https://ccache.dev/manual/4.8.html#config_run_second_cpp CCACHE_CPP2 are d

[PULL 30/32] meson-buildoptions: document the data at the top

2023-10-18 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- scripts/meson-buildoptions.py | 8 1 file changed, 8 insertions(+) diff --git a/scripts/meson-buildoptions.py b/scripts/meson-buildoptions.py index 2e88732a291..4814a8ff61f 100644 --- a/scripts/meson-buildoptions.py +++ b/scripts/meson-buildoptions.py @@

[PULL 13/32] tests/vm: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal or by double-escaping the backslash. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- tests/vm/basevm.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/vm/basevm.py b/tests/vm/basevm

[PULL 19/32] hw/xen: cleanup sourcesets

2023-10-18 Thread Paolo Bonzini
xen_ss is added unconditionally to arm_ss and i386_ss (the only targets that can have CONFIG_XEN enabled) and its contents are gated by CONFIG_XEN; xen_specific_ss has no condition for its constituent files but is gated on CONFIG_XEN when its added to specific_ss. So xen_ss is a duplicate of xen_s

[PULL 15/32] meson: do not build shaders by default

2023-10-18 Thread Paolo Bonzini
They are not needed when building user-mode emulators. Reviewed-by: Emmanouil Pitsidianakis Signed-off-by: Paolo Bonzini --- ui/shader/meson.build | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/shader/meson.build b/ui/shader/meson.build index 592bf596b9a..3137e65578e 100644 --- a/ui/sha

[PULL 23/32] configure: clean up plugin option handling

2023-10-18 Thread Paolo Bonzini
Keep together all the conditions that lead to disabling plugins, and remove now-dead code. Since the option was not in SKIP_OPTIONS, it was present twice in the help message, both from configure and from meson-buildoptions.sh. Remove the duplication and take the occasion to document the option as

[PULL 31/32] meson: add a note on why we use config_host for program paths

2023-10-18 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- meson.build | 5 + 1 file changed, 5 insertions(+) diff --git a/meson.build b/meson.build index 2bda62a2b1b..0182622aede 100644 --- a/meson.build +++ b/meson.build @@ -4021,6 +4021,11 @@ summary(summary_info, bool_yn: true, section: 'Directories') summary_i

[PULL 20/32] hw/remote: move stub vfu_object_set_bus_irq out of stubs/

2023-10-18 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- hw/remote/meson.build | 4 +++- stubs/vfio-user-obj.c => hw/remote/vfio-user-obj-stub.c | 0 stubs/meson.build | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) rename stubs/vfio-user-o

[PULL 09/32] tests/docker: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- tests/docker/docker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/docker/docker.py b/tests/docker/docker.py index 688ef62989c..3b8a267

Re: [PATCH v6 2/5] migration: migrate 'inc' command option is deprecated.

2023-10-18 Thread Markus Armbruster
Juan Quintela writes: > Use blockdev-mirror with NBD instead. > > Reviewed-by: Thomas Huth > Acked-by: Stefan Hajnoczi > Reviewed-by: Markus Armbruster > Signed-off-by: Juan Quintela > --- > docs/about/deprecated.rst | 9 + > qapi/migration.json| 8 +++- > migrat

[PULL 17/32] meson, cutils: allow non-relocatable installs

2023-10-18 Thread Paolo Bonzini
Say QEMU is configured with bindir = "/usr/bin" and a firmware path that starts with "/usr/share/qemu". Ever since QEMU 5.2, QEMU's install has been relocatable: if you move qemu-system-x86_64 from /usr/bin to /home/username/bin, it will start looking for firmware in /home/username/share/qemu. Pr

[PULL 32/32] configure: define "pkg-config" in addition to "pkgconfig"

2023-10-18 Thread Paolo Bonzini
Meson used to allow both "pkgconfig" and "pkg-config" entries in machine files; the former was used for dependency lookup and the latter was used as return value for "find_program('pkg-config')", which is a less common use-case and one that QEMU does not need. This inconsistency is going to be fix

[PULL 06/32] tests/vm: netbsd: install dtc

2023-10-18 Thread Paolo Bonzini
Install dtc as it is now a mandatory external dependency in order to build QEMU. Co-developed-by: Thomas Huth Signed-off-by: Thomas Huth Signed-off-by: Paolo Bonzini --- tests/vm/netbsd | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/vm/netbsd b/tests/vm/netbsd i

Re: [PATCH v8 0/5] Implement reconnect for vhost-user-scsi

2023-10-18 Thread Li Feng
Hello Guys, Ping
 These patches have been waiting for a long time. Can they be merged? Best Regards, li > On 9 Oct 2023, at 12:46 PM, Li Feng wrote: > > Changes for v8: > - [PATCH 3/5] vhost-user-scsi: support reconnect to backend > - Fix code style suggested by Manos Pitsidianakis > - [PATC

Re: [PATCH 11/12] hw/xen: automatically assign device index to block devices

2023-10-18 Thread David Woodhouse
On Wed, 2023-10-18 at 09:32 +0200, Igor Mammedov wrote: > On Mon, 16 Oct 2023 16:19:08 +0100 > David Woodhouse wrote: > > > From: David Woodhouse > > > > is this index a user (guest) visible? Yes. It defines what block device (e.g. /dev/xvda) the disk appears as in the guest. In the common ca

Re: [PATCH v8 3/5] vhost-user-scsi: support reconnect to backend

2023-10-18 Thread Manos Pitsidianakis
If the backend crashes and restarts, the device is broken. This patch adds reconnect for vhost-user-scsi. This patch also improves the error messages, and reports some silent errors. Tested with spdk backend. Signed-off-by: Li Feng --- Reviewed-by: Manos Pitsidianakis

[PULL 22/32] configure, tests/tcg: simplify GDB conditionals

2023-10-18 Thread Paolo Bonzini
Unify HAVE_GDB_BIN (currently in config-host.mak) and HOST_GDB_SUPPORTS_ARCH into a single GDB variable in config-target.mak. Reviewed-by: Emmanouil Pitsidianakis Signed-off-by: Paolo Bonzini --- configure | 30 +-- meson.build

[PULL 14/32] tracetool: avoid invalid escape in Python string

2023-10-18 Thread Paolo Bonzini
This is an error in Python 3.12; fix it by using a raw string literal. Cc: qemu-sta...@nongnu.org Signed-off-by: Paolo Bonzini --- scripts/tracetool/__init__.py| 14 +++--- scripts/tracetool/format/log_stap.py | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git

[PULL 29/32] configure, meson: use command line options to configure qemu-ga

2023-10-18 Thread Paolo Bonzini
Preserve the functionality of the environment variables, but allow using the command line instead. Signed-off-by: Paolo Bonzini --- configure | 16 +--- meson_options.txt | 7 +++ qga/meson.build | 9 ++--- scripts/meson-buildop

[PULL 24/32] configure: clean up PIE option handling

2023-10-18 Thread Paolo Bonzini
Keep together all the conditions that lead to disabling PIE. Signed-off-by: Paolo Bonzini --- configure | 35 ++- 1 file changed, 14 insertions(+), 21 deletions(-) diff --git a/configure b/configure index 688577bebd8..5c1d618f102 100755 --- a/configure +++ b/conf

Re: [PATCH v8 0/5] Implement reconnect for vhost-user-scsi

2023-10-18 Thread Michael S. Tsirkin
Queued. Thanks! On Wed, Oct 18, 2023 at 04:26:10PM +0800, Li Feng wrote: > Hello Guys, > > Ping
 > > These patches have been waiting for a long time. Can they be merged? > > > Best Regards, > > li > > > On 9 Oct 2023, at 12:46 PM, Li Feng wrote: > > Changes for v8: > - [PATCH

Re: [PATCH v7 0/7] Hyper-V Dynamic Memory Protocol driver (hv-balloon 🎈)

2023-10-18 Thread Maciej S. Szmigiero
On 18.10.2023 10:00, David Hildenbrand wrote: On 28.08.23 18:48, Maciej S. Szmigiero wrote: From: "Maciej S. Szmigiero" This is a continuation of the v6 of the patch series located here: https://lore.kernel.org/qemu-devel/cover.1689786474.git.maciej.szmigi...@oracle.com/ Changes from v6: * S

Re: [PATCH 4/4] qapi: introduce CONFIG_READ event

2023-10-18 Thread Vladimir Sementsov-Ogievskiy
On 18.10.23 09:47, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: On 17.10.23 18:00, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Send a new event when guest reads virtio-pci config after virtio_notify_config() call. That's useful to check that guest fetche

Re: [PATCH 11/12] hw/xen: automatically assign device index to block devices

2023-10-18 Thread Kevin Wolf
Am 16.10.2023 um 17:19 hat David Woodhouse geschrieben: > From: David Woodhouse > > There's no need to force the user to assign a vdev. We can automatically > assign one, starting at xvda and searching until we find the first disk > name that's unused. > > This means we can now allow '-drive if=

Re: [PATCH v5 3/3] qapi: re-establish linting baseline

2023-10-18 Thread Markus Armbruster
John Snow writes: > Some very minor housekeeping to make the linters happy once more. > > Signed-off-by: John Snow Queued. Thanks!

Re: [PATCH v11 00/11] Add VIRTIO sound card

2023-10-18 Thread Manos Pitsidianakis
On Wed, 11 Oct 2023 17:34, Manos Pitsidianakis wrote: This patch series adds an audio device implementing the recent virtio sound spec (1.2) and a corresponding PCI wrapper device. v11 can be found online at: https://gitlab.com/epilys/qemu/-/tree/virtio-snd-v11 Ref 885b01fe272541fdab5583780

[PATCH v1 2/3] target/loongarch: Allow user enable/disable LSX/LASX features

2023-10-18 Thread Song Gao
Some users may not need LSX/LASX, this patch allows the user enable/disable LSX/LASX features. e.g '-cpu max,lsx=on,lasx=on' (default); '-cpu max,lsx=on,lasx=off' (enabled LSX); '-cpu max,lsx=off,lasx=on' (error, need lsx=on); '-cpu max,lsx=off' (disable LSX and LASX). Signed-of

[PATCH v1 1/3] target/loongarch: Add cpu model 'max'

2023-10-18 Thread Song Gao
We use cpu la464 for the 'max' cpu. Signed-off-by: Song Gao --- target/loongarch/cpu.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/target/loongarch/cpu.c b/target/loongarch/cpu.c index ef1bf89dac..ef6922e812 100644 --- a/target/loongarch/cpu.c +++ b/target/loongarch/cpu.c @@ -474,

[PATCH v1 0/3] Allow user enable/disable LSX/LASX features

2023-10-18 Thread Song Gao
Hi, This series adds the cpu model 'max' support. and allow users enable/disable LSX/LASX features. Song Gao (3): target/loongarch: Add cpu model 'max' target/loongarch: Allow user enable/disable LSX/LASX features target/loongarch: Implement query-cpu-model-expansion qapi/machine-target.j

[PATCH v1 3/3] target/loongarch: Implement query-cpu-model-expansion

2023-10-18 Thread Song Gao
Add support for the query-cpu-model-expansion QMP command to LoongArch. We only support query the 'max' cpu features. e.g start with '-cpu max,lasx=off' (QEMU) query-cpu-model-expansion type=static model={"name":"max"} {"return": {"model": {"name": "max", "props": {"lasx": false, "

Re: [PATCH v2 1/4] softmmu/physmem: Warn with ram_block_discard_range() on MAP_PRIVATE file mapping

2023-10-18 Thread Xiaoyao Li
On 10/18/2023 3:42 PM, David Hildenbrand wrote: On 18.10.23 05:02, Xiaoyao Li wrote: David, On 7/6/2023 3:56 PM, David Hildenbrand wrote: ram_block_discard_range() cannot possibly do the right thing in MAP_PRIVATE file mappings in the general case. To achieve the documented semantics, we also

Re: [PATCH v11 00/11] Add VIRTIO sound card

2023-10-18 Thread Michael S. Tsirkin
On Wed, Oct 18, 2023 at 11:49:00AM +0300, Manos Pitsidianakis wrote: > On Wed, 11 Oct 2023 17:34, Manos Pitsidianakis > wrote: > > This patch series adds an audio device implementing the recent virtio > > sound spec (1.2) and a corresponding PCI wrapper device. > > > > v11 can be found online at

[PATCH] tests/qtest/migration-test: Disable the analyze-migration.py test on s390x

2023-10-18 Thread Thomas Huth
The analyze-migration.py script fails on s390x hosts: Traceback (most recent call last): File "scripts/analyze-migration.py", line 662, in dump.read(dump_memory = args.memory) File "scripts/analyze-migration.py", line 596, in read classdesc = self.section_classes[section_key] Ke

Re: [PATCH 08/11] hw/net/cadence_gem: use FIELD to describe DESCONF6 register fields

2023-10-18 Thread Philippe Mathieu-Daudé
On 17/10/23 21:44, Luc Michel wrote: Use the FIELD macro to describe the DESCONF6 register fields. Signed-off-by: Luc Michel --- hw/net/cadence_gem.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 11/11] hw/net/cadence_gem: enforce 32 bits variable size for CRC

2023-10-18 Thread Philippe Mathieu-Daudé
On 17/10/23 21:44, Luc Michel wrote: The CRC was stored in an unsigned variable in gem_receive. Change it for a uint32_t to ensure we have the correct variable size here. Fixes: e9f186e514 ("cadence_gem: initial version of device model") Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Lu

Re: [PATCH v2 1/4] softmmu/physmem: Warn with ram_block_discard_range() on MAP_PRIVATE file mapping

2023-10-18 Thread David Hildenbrand
On 18.10.23 11:02, Xiaoyao Li wrote: On 10/18/2023 3:42 PM, David Hildenbrand wrote: On 18.10.23 05:02, Xiaoyao Li wrote: David, On 7/6/2023 3:56 PM, David Hildenbrand wrote: ram_block_discard_range() cannot possibly do the right thing in MAP_PRIVATE file mappings in the general case. To ach

Re: [PATCH v7 0/7] Hyper-V Dynamic Memory Protocol driver (hv-balloon 🎈)

2023-10-18 Thread David Hildenbrand
On 18.10.23 10:45, Maciej S. Szmigiero wrote: On 18.10.2023 10:00, David Hildenbrand wrote: On 28.08.23 18:48, Maciej S. Szmigiero wrote: From: "Maciej S. Szmigiero" This is a continuation of the v6 of the patch series located here: https://lore.kernel.org/qemu-devel/cover.1689786474.git.maci

Re: [PATCH v3 6/9] qapi/block-core: use JobType for BlockJobInfo's type

2023-10-18 Thread Markus Armbruster
Fiona Ebner writes: > In preparation to turn BlockJobInfo into a union with @type as the > discriminator. That requires it to be an enum. > > No functional change is intended. > > Signed-off-by: Fiona Ebner > Reviewed-by: Vladimir Sementsov-Ogievskiy Replacing str by enum makes sense whether w

Re: [PATCH v3 5/9] mirror: implement mirror_change method

2023-10-18 Thread Markus Armbruster
Fiona Ebner writes: > which allows switching the @copy-mode from 'background' to > 'write-blocking'. > > This is useful for management applications, so they can start out in > background mode to avoid limiting guest write speed and switch to > active mode when certain criteria are fulfilled. > >

Re: deadlock when using iothread during backup_clean()

2023-10-18 Thread Fiona Ebner
Am 17.10.23 um 16:20 schrieb Kevin Wolf: > Am 17.10.2023 um 15:37 hat Fiona Ebner geschrieben: >> Am 17.10.23 um 14:12 schrieb Kevin Wolf: >>> Am 17.10.2023 um 12:18 hat Fiona Ebner geschrieben: I ran into similar issues now with mirror, (both deadlocks and stuck guest IO at other times),

Re: [PATCH v3 0/9] mirror: allow switching from background to active mode

2023-10-18 Thread Markus Armbruster
Fiona Ebner writes: > Changes in v3: > * unlock the job mutex when calling the new block job driver > 'query' handler > * squash patch adapting iotest output into patch that changes the > output > * turn accesses to copy_mode and actively_synced atomic > * slightly rew

Re: [PATCH v3 0/9] mirror: allow switching from background to active mode

2023-10-18 Thread Fiona Ebner
Am 18.10.23 um 11:41 schrieb Markus Armbruster: > Fiona Ebner writes: >> >> Initially, I tried to go for a more general 'job-change' command, but >> to avoid mutual inclusion of block-core.json and job.json, more >> preparation would be required. > > Can you elaborate a bit? A more generic comma

[PULL 02/22] linux-headers: Add iommufd.h

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan Since commit da3c22c74a3c ("linux-headers: Update to Linux v6.6-rc1"), linux-headers has been updated to v6.6-rc1. As previous patch added iommufd.h to update-linux-headers.sh, run the script again against TAG v6.6-rc1 to have iommufd.h included. Signed-off-by: Zhenzhong Du

[PULL 17/22] vfio/ap: Remove pointless apdev variable

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan No need to double-cast, call VFIO_AP_DEVICE() on DeviceState. No functional changes. Signed-off-by: Zhenzhong Duan Reviewed-by: Tony Krowiak Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Cédric Le Goater --- hw/vfio/ap.c | 9 +++-- 1 file changed, 3 insertions

[PULL 04/22] vfio/common: Propagate KVM_SET_DEVICE_ATTR error if any

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger In the VFIO_SPAPR_TCE_v2_IOMMU container case, when KVM_SET_DEVICE_ATTR fails, we currently don't propagate the error as we do on the vfio_spapr_create_window() failure case. Let's align the code. Take the opportunity to reword the error message and make it more explicit. Signed

[PULL 07/22] vfio/pci: Introduce vfio_[attach/detach]_device

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger We want the VFIO devices to be able to use two different IOMMU backends, the legacy VFIO one and the new iommufd one. Introduce vfio_[attach/detach]_device which aim at hiding the underlying IOMMU backend (IOCTLs, datatypes, ...). Once vfio_attach_device completes, the device i

[PULL 00/22] vfio queue

2023-10-18 Thread CĂ©dric Le Goater
tags/pull-vfio-20231018 for you to fetch changes up to 8741781157f09a9f79bb652f8a0210d40f814cd0: hw/vfio: add ramfb migration support (2023-10-18 10:10:49 +0200) vfio queue: * Support for VFIODisplay migration with ramfb * Prelim

[PULL 22/22] hw/vfio: add ramfb migration support

2023-10-18 Thread CĂ©dric Le Goater
From: Marc-André Lureau Add a "VFIODisplay" subsection whenever "x-ramfb-migrate" is turned on. Turn it off by default on machines <= 8.1 for compatibility reasons. Signed-off-by: Marc-André Lureau Reviewed-by: Laszlo Ersek Acked-by: Gerd Hoffmann [ clg: - checkpatch fixes - improve

[PULL 03/22] vfio/common: Move IOMMU agnostic helpers to a separate file

2023-10-18 Thread CĂ©dric Le Goater
From: Yi Liu Move low-level iommu agnostic helpers to a separate helpers.c file. They relate to regions, interrupts, device/region capabilities and etc. Signed-off-by: Eric Auger Signed-off-by: Yi Sun Signed-off-by: Yi Liu Signed-off-by: Zhenzhong Duan Reviewed-by: CĂ©dric Le Goater Signed-o

[PULL 11/22] vfio/common: Move VFIO reset handler registration to a group agnostic function

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan Move the reset handler registration/unregistration to a place that is not group specific. vfio_[get/put]_address_space are the best places for that purpose. Signed-off-by: Eric Auger Signed-off-by: Yi Liu Signed-off-by: Zhenzhong Duan Reviewed-by: CĂ©dric Le Goater Signed

[PULL 13/22] vfio/common: Store the parent container in VFIODevice

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan let's store the parent contaienr within the VFIODevice. This simplifies the logic in vfio_viommu_preset() and brings the benefice to hide the group specificity which is useful for IOMMUFD migration. Signed-off-by: Eric Auger Signed-off-by: Zhenzhong Duan Signed-off-by: CĂ©d

[PULL 14/22] vfio/common: Introduce a global VFIODevice list

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan Some functions iterate over all the VFIODevices. This is currently achieved by iterating over all groups/devices. Let's introduce a global list of VFIODevices simplifying that scan. This will also be useful while migrating to IOMMUFD by hiding the group specificity. Signed-

[PULL 15/22] vfio/common: Move legacy VFIO backend code into separate container.c

2023-10-18 Thread CĂ©dric Le Goater
From: Yi Liu Move all the code really dependent on the legacy VFIO container/group into a separate file: container.c. What does remain in common.c is the code related to VFIOAddressSpace, MemoryListeners, migration and all other general operations. Signed-off-by: Eric Auger Signed-off-by: Yi Li

[PULL 21/22] ramfb-standalone: add migration support

2023-10-18 Thread CĂ©dric Le Goater
From: Marc-André Lureau Add a "ramfb-dev" section whenever "x-migrate" is turned on. Turn it off by default on machines <= 8.1 for compatibility reasons. Signed-off-by: Marc-André Lureau Reviewed-by: Laszlo Ersek Acked-by: Gerd Hoffmann Signed-off-by: Cédric Le Goater --- hw/core/machine.c

[PULL 08/22] vfio/platform: Use vfio_[attach/detach]_device

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger Let the vfio-platform device use vfio_attach_device() and vfio_detach_device(), hence hiding the details of the used IOMMU backend. Drop the trace event for vfio-platform as we have similar one in vfio_attach_device. Signed-off-by: Eric Auger Signed-off-by: Yi Liu Signed-off-

[PULL 12/22] vfio/common: Introduce a per container device list

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan Several functions need to iterate over the VFIO devices attached to a given container. This is currently achieved by iterating over the groups attached to the container and then over the devices in the group. Let's introduce a per container device list that simplifies this s

[PULL 10/22] vfio/ccw: Use vfio_[attach/detach]_device

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger Let the vfio-ccw device use vfio_attach_device() and vfio_detach_device(), hence hiding the details of the used IOMMU backend. Note that the migration reduces the following trace "vfio: subchannel %s has already been attached" (featuring cssid.ssid.devid) into "device is already

[PULL 16/22] vfio/pci: Fix a potential memory leak in vfio_listener_region_add

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan When there is an failure in vfio_listener_region_add() and the section belongs to a ram device, there is an inaccurate error report which should never be related to vfio_dma_map failure. The memory holding err is also incrementally leaked in each failure. Fix it by reporting

[PULL 09/22] vfio/ap: Use vfio_[attach/detach]_device

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger Let the vfio-ap device use vfio_attach_device() and vfio_detach_device(), hence hiding the details of the used IOMMU backend. We take the opportunity to use g_path_get_basename() which is prefered, as suggested by 3e015d815b ("use g_path_get_basename instead of basename") Signe

[PULL 19/22] vfio/pci: Remove vfio_detach_device from vfio_realize error path

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger In vfio_realize, on the error path, we currently call vfio_detach_device() after a successful vfio_attach_device. While this looks natural, vfio_instance_finalize also induces a vfio_detach_device(), and it seems to be the right place instead as other resources are released there

[PULL 01/22] scripts/update-linux-headers: Add iommufd.h

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger Update the script to import iommufd.h Signed-off-by: Eric Auger Signed-off-by: Yi Liu Signed-off-by: Zhenzhong Duan Reviewed-by: CĂ©dric Le Goater Signed-off-by: CĂ©dric Le Goater --- scripts/update-linux-headers.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) di

[PULL 06/22] vfio/common: Extract out vfio_kvm_device_[add/del]_fd

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan Introduce two new helpers, vfio_kvm_device_[add/del]_fd which take as input a file descriptor which can be either a group fd or a cdev fd. This uses the new KVM_DEV_VFIO_FILE VFIO KVM device group, which aliases to the legacy KVM_DEV_VFIO_GROUP. vfio_kvm_device_[add/del]_gro

[PULL 05/22] vfio/common: Introduce vfio_container_add|del_section_window()

2023-10-18 Thread CĂ©dric Le Goater
From: Eric Auger Introduce helper functions that isolate the code used for VFIO_SPAPR_TCE_v2_IOMMU. Those helpers hide implementation details beneath the container object and make the vfio_listener_region_add/del() implementations more readable. No code change intended. Signed-off-by: Eric Auge

[PULL 18/22] vfio/ccw: Remove redundant definition of TYPE_VFIO_CCW

2023-10-18 Thread CĂ©dric Le Goater
From: Zhenzhong Duan No functional changes. Signed-off-by: Zhenzhong Duan Reviewed-by: Eric Farman Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Cédric Le Goater --- include/hw/s390x/vfio-ccw.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/hw/s390x/vfio-ccw.h b/include/h

[PULL 20/22] ramfb: add migration support

2023-10-18 Thread CĂ©dric Le Goater
From: Marc-André Lureau Implementing RAMFB migration is quite straightforward. One caveat is to treat the whole RAMFBCfg as a blob, since that's what is exposed to the guest directly. This avoid having to fiddle with endianness issues if we were to migrate fields individually as integers. The de

Re: [RFC PATCH v4 4/4] tests/avocado: Add test for amigaone board

2023-10-18 Thread CĂ©dric Le Goater
On 10/18/23 07:58, Thomas Huth wrote: Please add a short patch description if this moves from RFC to a real patch On 17/10/2023 21.06, BALATON Zoltan wrote: Signed-off-by: BALATON Zoltan --- I have no idea if this works so testing and corrections are welcome Why don't you test it on your own

Re: [PATCH] tests/qtest/migration-test: Disable the analyze-migration.py test on s390x

2023-10-18 Thread Juan Quintela
Thomas Huth wrote: > The analyze-migration.py script fails on s390x hosts: > > Traceback (most recent call last): >File "scripts/analyze-migration.py", line 662, in > dump.read(dump_memory = args.memory) >File "scripts/analyze-migration.py", line 596, in read > classdesc = self

[PULL 00/11] Migration 20231018 patches

2023-10-18 Thread Juan Quintela
u.git tags/migration-20231018-pull-request for you to fetch changes up to e8e4e7acd8e2113d900fe6b9a9870daa7ecf1042: migration: save_zero_page() can take block through pss (2023-10-18 10:39:03 +0200) Migration Pull request (202

[PULL 10/11] migration: control_save_page() can take block through pss

2023-10-18 Thread Juan Quintela
Reviewed-by: Lukas Straub Signed-off-by: Juan Quintela --- migration/ram.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/migration/ram.c b/migration/ram.c index 378d310fbd..7f18c1808d 100644 --- a/migration/ram.c +++ b/migration/ram.c @@ -1186,12 +1186,12 @@ static in

[PULL 05/11] migration: Move update_compress_threads_counts() to ram-compress.c

2023-10-18 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Lukas Straub Message-ID: <20230613145757.10131-9-quint...@redhat.com> --- migration/ram-compress.h | 1 + migration/ram-compress.c | 17 + migration/ram.c | 15 --- 3 files changed, 18 insertions(+), 15 deletions(-)

[PULL 07/11] migration: Use "i" as an for index in ram-compress.c

2023-10-18 Thread Juan Quintela
It is used everywhere else in C. Once there, make sure that we don't use the index outside of the for declaring the variable there. Signed-off-by: Juan Quintela Reviewed-by: Lukas Straub Message-ID: <20230613145757.10131-15-quint...@redhat.com> --- migration/ram-compress.c | 56 +++

[PULL 11/11] migration: save_zero_page() can take block through pss

2023-10-18 Thread Juan Quintela
Reviewed-by: Lukas Straub Signed-off-by: Juan Quintela --- migration/ram.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/migration/ram.c b/migration/ram.c index 7f18c1808d..16c30a9d7a 100644 --- a/migration/ram.c +++ b/migration/ram.c @@ -1144,13 +1144,12 @@ v

[PULL 09/11] migration: save_compress_page() can take block through pss

2023-10-18 Thread Juan Quintela
Reviewed-by: Lukas Straub Signed-off-by: Juan Quintela --- migration/ram.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/migration/ram.c b/migration/ram.c index 5595379fa6..378d310fbd 100644 --- a/migration/ram.c +++ b/migration/ram.c @@ -2067,7 +2067,7 @@ static b

[PULL 08/11] migration: Print block status when needed

2023-10-18 Thread Juan Quintela
The new line was only printed when command options were used. When we used migration parameters and capabilities, it wasn't. Reviewed-by: Fabiano Rosas Signed-off-by: Juan Quintela Message-ID: <20231017172307.22858-2-quint...@redhat.com> --- migration/migration-hmp-cmds.c | 5 ++--- 1 file cha

  1   2   3   4   5   6   7   >