Re: [PATCH v2] util/qemu-config: Fix "query-command-line-options" to provide the right values

2022-11-15 Thread Thomas Huth
On 15/11/2022 08.53, Markus Armbruster wrote: Thomas Huth writes: On 11/11/2022 15.53, Markus Armbruster wrote: Thomas Huth writes: The "query-command-line-options" command uses a hand-crafted list of options that should be returned for the "machine" parameter. This is pretty much out of s

Re: [PATCH v2] capstone: use instead of

2022-11-15 Thread Daniel P . Berrangé
On Mon, Nov 14, 2022 at 02:49:39PM +0100, Paolo Bonzini wrote: > Queued, thanks. I presume you have unqueued this patch again after the discussion yesterday ? With regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-

Re: [PATCH v1 5/9] hw/virtio: introduce virtio_device_should_start

2022-11-15 Thread Christian Borntraeger
Am 14.11.22 um 18:20 schrieb Michael S. Tsirkin: On Mon, Nov 14, 2022 at 06:15:30PM +0100, Christian Borntraeger wrote: Am 14.11.22 um 18:10 schrieb Michael S. Tsirkin: On Mon, Nov 14, 2022 at 05:55:09PM +0100, Christian Borntraeger wrote: Am 14.11.22 um 17:37 schrieb Michael S. Tsirkin:

Re: [PATCH 2/2] Do not access /dev/mem in MSI-X PCI passthrough on Xen

2022-11-15 Thread Jan Beulich
On 14.11.2022 20:20, Marek Marczykowski-Górecki wrote: > The /dev/mem is used for two purposes: > - reading PCI_MSIX_ENTRY_CTRL_MASKBIT > - reading Pending Bit Array (PBA) > > The first one was originally done because when Xen did not send all > vector ctrl writes to the device model, so QEMU mi

Re: [PATCH] docs/system/s390x: Document the "loadparm" machine property

2022-11-15 Thread Janosch Frank
On 11/14/22 14:25, Thomas Huth wrote: The "loadparm" machine property is useful for selecting alternative kernels on the disk of the guest, but so far we do not tell the users yet how to use it. Add some documentation to fill this gap. Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=2128235

Re: Qemu virtual CPU limitation to 1024

2022-11-15 Thread Daniel P . Berrangé
On Tue, Nov 15, 2022 at 12:19:35AM +0100, Pawel Polawski wrote: > Hi Everyone, > > I am trying to check qemu virtual cpu boundaries when running a custom > edk2 based firmware build. For that purpose I want to run qemu with more > than 1024 vCPU: > $QEMU > -accel kvm > -m 4G > -M q35,kernel-irqchi

Re: Qemu virtual CPU limitation to 1024

2022-11-15 Thread Pawel Polawski
Hi Daniel, Thank you for the answer. Also I realized that somehow my email has split into two different threads, sorry for the confusion. Best, Pawel On Tue, Nov 15, 2022 at 9:48 AM Daniel P. Berrangé wrote: > On Tue, Nov 15, 2022 at 12:19:35AM +0100, Pawel Polawski wrote: > > Hi Everyone, > >

Re: [qemu-devel]

2022-11-15 Thread Pawel Polawski
Hi Thomas, Thank you for the suggestion about the next step. Do you know if there is an option to change this parameter in the runtime? While looking for answer I found this presentation from 2008 which makes me think that this may not be the only limit: https://www.linux-kvm.org/images/b/be/KvmFo

Re: [PATCH v1 5/9] hw/virtio: introduce virtio_device_should_start

2022-11-15 Thread Michael S. Tsirkin
On Tue, Nov 15, 2022 at 09:18:27AM +0100, Christian Borntraeger wrote: > > Am 14.11.22 um 18:20 schrieb Michael S. Tsirkin: > > On Mon, Nov 14, 2022 at 06:15:30PM +0100, Christian Borntraeger wrote: > > > > > > > > > Am 14.11.22 um 18:10 schrieb Michael S. Tsirkin: > > > > On Mon, Nov 14, 2022 a

Re: [PATCH for-8.0] hw: Add compat machines for 8.0

2022-11-15 Thread Cédric Le Goater
On 11/11/22 13:45, Cornelia Huck wrote: Add 8.0 machine types for arm/i440fx/m68k/q35/s390x/spapr. Signed-off-by: Cornelia Huck --- hw/arm/virt.c | 9 - hw/core/machine.c | 3 +++ hw/i386/pc.c | 3 +++ hw/i386/pc_piix.c | 14 +

Re: [PATCH v2 06/15] migration: Yield bitmap_mutex properly when sending/sleeping

2022-11-15 Thread Juan Quintela
Peter Xu wrote: > On Wed, Oct 12, 2022 at 01:51:07PM -0400, Peter Xu wrote: >> On Wed, Oct 12, 2022 at 05:43:53PM +0100, Dr. David Alan Gilbert wrote: >> > * Peter Xu (pet...@redhat.com) wrote: >> > > Don't take the bitmap mutex when sending pages, or when being throttled >> > > by >> > > migrati

Re: [PATCH v2] capstone: use instead of

2022-11-15 Thread Michael Tokarev
14.11.2022 14:59, Peter Maydell wrote: .. We can do something like config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H', cc.has_header('capstone/capstone.h', depedencies: [capstone]) This doesn't work, because has_header does not have "dependencies" argument. And without that, it doesn't take pkgc

Re: [PATCH v9 2/8] KVM: Extend the memslot to support fd-based private memory

2022-11-15 Thread Chao Peng
On Mon, Nov 14, 2022 at 04:04:59PM +, Alex Bennée wrote: > > Chao Peng writes: > > > In memory encryption usage, guest memory may be encrypted with special > > key and can be accessed only by the guest itself. We call such memory > > private memory. It's valueless and sometimes can cause pro

[PATCH] disas: recognize either or

2022-11-15 Thread Michael Tokarev
Historically, capstone varies in requiring either or include depending on version and the way how it has been installed. This has already been an issue before, and will likely become an issue again with capstone 5.0 which seem to have changed this aspect once again. Recognize both ways in the m

Re: [PATCH] disas: recognize either or

2022-11-15 Thread Michael Tokarev
15.11.2022 12:38, Michael Tokarev wrote: .. Recognize both ways in the meson check, but prefer so it's easily to override which capstone to use by With the obvious typo fix, "easy" :) /mjt

Re: [PATCH v9 1/8] mm: Introduce memfd_restricted system call to create restricted user memory

2022-11-15 Thread Chao Peng
On Mon, Nov 14, 2022 at 04:16:32PM -0600, Michael Roth wrote: > On Mon, Nov 14, 2022 at 06:28:43PM +0300, Kirill A. Shutemov wrote: > > On Mon, Nov 14, 2022 at 03:02:37PM +0100, Vlastimil Babka wrote: > > > On 11/1/22 16:19, Michael Roth wrote: > > > > On Tue, Nov 01, 2022 at 07:37:29PM +0800, Chao

Re: [PATCH for-8.0] hw: Add compat machines for 8.0

2022-11-15 Thread Thomas Huth
On 11/11/2022 13.45, Cornelia Huck wrote: Add 8.0 machine types for arm/i440fx/m68k/q35/s390x/spapr. Signed-off-by: Cornelia Huck --- hw/arm/virt.c | 9 - hw/core/machine.c | 3 +++ hw/i386/pc.c | 3 +++ hw/i386/pc_piix.c | 14 +++

Re: [PATCH v2] util/qemu-config: Fix "query-command-line-options" to provide the right values

2022-11-15 Thread Markus Armbruster
Thomas Huth writes: > On 15/11/2022 08.53, Markus Armbruster wrote: >> Thomas Huth writes: >> >>> On 11/11/2022 15.53, Markus Armbruster wrote: Thomas Huth writes: > The "query-command-line-options" command uses a hand-crafted list > of options that should be returned for the

Re: [PATCH] docs/system/s390x: Document the "loadparm" machine property

2022-11-15 Thread Thomas Huth
On 15/11/2022 09.41, Janosch Frank wrote: On 11/14/22 14:25, Thomas Huth wrote: The "loadparm" machine property is useful for selecting alternative kernels on the disk of the guest, but so far we do not tell the users yet how to use it. Add some documentation to fill this gap. Buglink: https://

Re: biosbits test failing on origin/master

2022-11-15 Thread Ani Sinha
On Tue, Nov 15, 2022 at 9:07 AM Ani Sinha wrote: > > On Tue, Nov 15, 2022 at 5:13 AM John Snow wrote: > > > > On Thu, Nov 10, 2022 at 11:22 PM Ani Sinha wrote: > > > > > > On Thu, Nov 10, 2022 at 11:37 PM John Snow wrote: > > > > > > > > Hiya, on today's origin/master > > > > (2ccad61746ca7de5d

Re: [PULL 00/11] Block layer patches

2022-11-15 Thread Kevin Wolf
Am 15.11.2022 um 00:58 hat John Snow geschrieben: > On Mon, Nov 14, 2022 at 5:56 AM Kevin Wolf wrote: > > > > Am 11.11.2022 um 20:20 hat Stefan Hajnoczi geschrieben: > > > > Hanna Reitz (9): > > > > block/mirror: Do not wait for active writes > > > > block/mirror: Drop mirror_wait_for_

Re: [PULL 00/11] Block layer patches

2022-11-15 Thread Hanna Reitz
On 15.11.22 11:14, Kevin Wolf wrote: Am 15.11.2022 um 00:58 hat John Snow geschrieben: On Mon, Nov 14, 2022 at 5:56 AM Kevin Wolf wrote: Am 11.11.2022 um 20:20 hat Stefan Hajnoczi geschrieben: Hanna Reitz (9): block/mirror: Do not wait for active writes block/mirror: Drop mirror

Re: [PATCH for-8.0] hw: Add compat machines for 8.0

2022-11-15 Thread Greg Kurz
On Fri, 11 Nov 2022 13:45:34 +0100 Cornelia Huck wrote: > Add 8.0 machine types for arm/i440fx/m68k/q35/s390x/spapr. > > Signed-off-by: Cornelia Huck > --- > hw/arm/virt.c | 9 - > hw/core/machine.c | 3 +++ > hw/i386/pc.c | 3 +++ > hw/i386/pc_pi

Re: [PATCH for-8.0] hw: Add compat machines for 8.0

2022-11-15 Thread Cornelia Huck
On Tue, Nov 15 2022, Greg Kurz wrote: > On Fri, 11 Nov 2022 13:45:34 +0100 > Cornelia Huck wrote: > >> Add 8.0 machine types for arm/i440fx/m68k/q35/s390x/spapr. >> >> Signed-off-by: Cornelia Huck >> --- >> hw/arm/virt.c | 9 - >> hw/core/machine.c | 3 +++ >>

Re: [PATCH 0/1] hw/arm/aspeed: Automatically zero-extend flash images

2022-11-15 Thread Peter Maydell
On Mon, 14 Nov 2022 at 19:08, Peter Delevoryas wrote: > > I've been using this patch for a long time so that I don't have to use > dd to zero-extend stuff all the time. It's just doing what people are > doing already, right? I hope it's not controversial. We just had a thread about this kind of t

Re: [PATCH for-7.2] Add G_GNUC_PRINTF to function qemu_set_info_str and fix related issues

2022-11-15 Thread Peter Maydell
On Tue, 15 Nov 2022 at 07:20, Stefan Weil via wrote: > > With the G_GNUC_PRINTF function attribute the compiler detects > two potential insecure format strings: > > ../../../net/stream.c:248:31: warning: format string is not a string literal > (potentially insecure) [-Wformat-security] > qemu

Re: [PATCH v2] capstone: use instead of

2022-11-15 Thread Peter Maydell
On Tue, 15 Nov 2022 at 09:25, Michael Tokarev wrote: > > 14.11.2022 14:59, Peter Maydell wrote: > .. > > We can do something like > > > > config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H', > > cc.has_header('capstone/capstone.h', depedencies: [capstone]) > > This doesn't work, because has_header doe

Re: [PATCH v2] capstone: use instead of

2022-11-15 Thread Peter Maydell
On Tue, 15 Nov 2022 at 11:00, Peter Maydell wrote: > > On Tue, 15 Nov 2022 at 09:25, Michael Tokarev wrote: > > > > 14.11.2022 14:59, Peter Maydell wrote: > > .. > > > We can do something like > > > > > > config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H', > > > cc.has_header('capstone/capstone.h',

Re: [PATCH v2] capstone: use instead of

2022-11-15 Thread Michael Tokarev
15.11.2022 14:00, Peter Maydell wrote: .. https://mesonbuild.com/Reference-manual_returned_compiler.html#compilerhas_header "dependencies dep | list[dep] Additionally dependencies required for compiling and / or linking." Oh sh**t.. I mistypoed it initially :) It looks like I "un-learned" t

tests/avocado/machine_s390_ccw_virtio: Fedora test failing

2022-11-15 Thread Philippe Mathieu-Daudé
Hi, As of v7.2.0-rc0 I am getting: (101/198) tests/avocado/machine_s390_ccw_virtio.py:S390CCWVirtioMachine.test_s390x_fedora: FAIL (23.51 s) $ cat test-results/101-tests_avocado_machine_s390_ccw_virtio.py_S390CCWVirtioMachine.test_s390x_fedora/debug.log 01:20:44 INFO | INIT 1-S390CCWVirti

Re: tests/avocado/machine_s390_ccw_virtio: Fedora test failing

2022-11-15 Thread Thomas Huth
On 15/11/2022 12.03, Philippe Mathieu-Daudé wrote: Hi, As of v7.2.0-rc0 I am getting:  (101/198) tests/avocado/machine_s390_ccw_virtio.py:S390CCWVirtioMachine.test_s390x_fedora: FAIL (23.51 s) Is it 100% reproducible? ... the test is known to be a little bit shaky, that's also why it is d

Re: [PATCH for-7.2] Add G_GNUC_PRINTF to function qemu_set_info_str and fix related issues

2022-11-15 Thread Philippe Mathieu-Daudé
On 15/11/22 08:19, Stefan Weil via wrote: With the G_GNUC_PRINTF function attribute the compiler detects two potential insecure format strings: ../../../net/stream.c:248:31: warning: format string is not a string literal (potentially insecure) [-Wformat-security] qemu_set_info_str(&s->nc,

Re: [PATCH v2 1/3] nvme: Move adjustment of data_units{read,written}

2022-11-15 Thread Klaus Jensen
On Nov 14 14:50, Joel Granados wrote: > In order to return the units_{read/written} required by the SMART log we > need to shift the number of bytes value by BDRV_SECTORS_BITS and multiply > by 1000. This is a prep patch that moves this adjustment to where the SMART > log is calculated in order to

Re: [PATCH v2 2/3] nvme: Add ocp to the subsys

2022-11-15 Thread Klaus Jensen
On Nov 14 14:50, Joel Granados wrote: > The Open Compute Project defines a Datacenter NVMe SSD Spec that sits on > top of the NVMe spec. Additional commands and NVMe behaviors specific for > the Datacenter. This is a preparation patch that introduces an argument to > activate OCP in nvme. > > Sign

Re: tests/avocado/machine_s390_ccw_virtio: Fedora test failing

2022-11-15 Thread Philippe Mathieu-Daudé
On 15/11/22 12:05, Thomas Huth wrote: On 15/11/2022 12.03, Philippe Mathieu-Daudé wrote: Hi, As of v7.2.0-rc0 I am getting:   (101/198) tests/avocado/machine_s390_ccw_virtio.py:S390CCWVirtioMachine.test_s390x_fedora: FAIL (23.51 s) Is it 100% reproducible? ... the test is known to be a litt

Re: [PATCH v11 03/11] s390x/cpu topology: core_id sets s390x CPU topology

2022-11-15 Thread Cédric Le Goater
Hello Pierre, On 11/3/22 18:01, Pierre Morel wrote: In the S390x CPU topology the core_id specifies the CPU address and the position of the core withing the topology. Let's build the topology based on the core_id. Signed-off-by: Pierre Morel --- include/hw/s390x/cpu-topology.h| 41

Re: [PATCH v11 04/11] s390x/cpu topology: reporting the CPU topology to the guest

2022-11-15 Thread Cédric Le Goater
Hello Pierre, On 11/3/22 18:01, Pierre Morel wrote: The guest can use the STSI instruction to get a buffer filled with the CPU topology description. Let us implement the STSI instruction for the basis CPU topology level, level 2. Signed-off-by: Pierre Morel --- include/hw/s390x/cpu-topology

Re: [PATCH v6 09/10] vdpa: Add listener_shadow_vq to vhost_vdpa

2022-11-15 Thread Eugenio Perez Martin
On Tue, Nov 15, 2022 at 4:04 AM Jason Wang wrote: > > On Tue, Nov 15, 2022 at 12:31 AM Eugenio Perez Martin > wrote: > > > > On Mon, Nov 14, 2022 at 5:30 AM Jason Wang wrote: > > > > > > > > > 在 2022/11/11 21:12, Eugenio Perez Martin 写道: > > > > On Fri, Nov 11, 2022 at 8:49 AM Jason Wang wrote:

Re: [PATCH v1 5/9] hw/virtio: introduce virtio_device_should_start

2022-11-15 Thread Michael S. Tsirkin
On Tue, Nov 15, 2022 at 09:18:27AM +0100, Christian Borntraeger wrote: > > Am 14.11.22 um 18:20 schrieb Michael S. Tsirkin: > > On Mon, Nov 14, 2022 at 06:15:30PM +0100, Christian Borntraeger wrote: > > > > > > > > > Am 14.11.22 um 18:10 schrieb Michael S. Tsirkin: > > > > On Mon, Nov 14, 2022 a

Re: [PATCH v2 3/3] nvme: Add physical writes/reads from OCP log

2022-11-15 Thread Klaus Jensen
On Nov 14 14:50, Joel Granados wrote: > In order to evaluate write amplification factor (WAF) within the storage > stack it is important to know the number of bytes written to the > controller. The existing SMART log value of Data Units Written is too > coarse (given in units of 500 Kb) and so we a

Re: [PATCH v3 0/7] memory: prevent dma-reentracy issues

2022-11-15 Thread Philippe Mathieu-Daudé
On 10/11/22 21:50, Stefan Hajnoczi wrote: Preventing this class of bugs is important but QEMU is currently frozen for the 7.2 release. I'm a little concerned about regressions in a patch series that changes core device emulation code. I'm waiting for Alex's MemTxRequesterType field addition in

Re: [PATCH v4 4/7] target/arm: Enable TTBCR_EAE for ARMv8-R AArch32

2022-11-15 Thread Philippe Mathieu-Daudé
On 14/11/22 18:19, Peter Maydell wrote: On Sun, 23 Oct 2022 at 16:37, wrote: From: Tobias Röhmel ARMv8-R AArch32 CPUs behave as if TTBCR.EAE is always 1 even tough they don't have the TTBCR register. See ARM Architecture Reference Manual Supplement - ARMv8, for the ARMv8-R AArch32 architectu

Re: [PATCH 2/2] Do not access /dev/mem in MSI-X PCI passthrough on Xen

2022-11-15 Thread Marek Marczykowski-Górecki
On Tue, Nov 15, 2022 at 09:14:07AM +0100, Jan Beulich wrote: > On 14.11.2022 20:20, Marek Marczykowski-Górecki wrote: > > The /dev/mem is used for two purposes: > > - reading PCI_MSIX_ENTRY_CTRL_MASKBIT > > - reading Pending Bit Array (PBA) > > > > The first one was originally done because when

[PATCH] hw/loongarch: Add default stdout uart in fdt

2022-11-15 Thread Xiaojuan Yang
Add "chosen" subnode into LoongArch fdt, and set it's "stdout-path" prop to uart node. Signed-off-by: Xiaojuan Yang --- hw/loongarch/virt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/loongarch/virt.c b/hw/loongarch/virt.c index 5e4c2790bf..b59c07972a 100644 --- a/hw/loongarch/virt.

[PATCH] hw/loongarch: Replace the value of uart info with macro

2022-11-15 Thread Xiaojuan Yang
Using macro to replace the value of uart info such as addr, size in acpi_build method. Signed-off-by: Xiaojuan Yang --- hw/loongarch/acpi-build.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/loongarch/acpi-build.c b/hw/loongarch/acpi-build.c index 68dfb9f88a..7d5f5a75

[PATCH v2] disas: recognize either or

2022-11-15 Thread Michael Tokarev
Historically, capstone varies in requiring either or include depending on version and the way how it has been installed. This has already been an issue before, and will likely become an issue again with capstone 5.0 which seem to have changed this aspect once again. Recognize both ways in the m

[PATCH] hw/loongarch: Add cfi01 pflash device

2022-11-15 Thread Xiaojuan Yang
Add cfi01 pflash device for LoongArch virt machine Signed-off-by: Xiaojuan Yang --- hw/loongarch/Kconfig| 1 + hw/loongarch/acpi-build.c | 39 +++ hw/loongarch/virt.c | 130 +--- include/hw/loongarch/virt.h | 7 ++ 4 files changed, 1

Re: [PATCH v2] disas: recognize either or

2022-11-15 Thread Peter Maydell
On Tue, 15 Nov 2022 at 11:55, Michael Tokarev wrote: > > Historically, capstone varies in requiring either > or include depending on version and the > way how it has been installed. This has already been an issue > before, and will likely become an issue again with capstone > 5.0 which seem to

Re: [PATCH v1] block/rbd: Add support for layered encryption

2022-11-15 Thread Ilya Dryomov
On Sun, Nov 13, 2022 at 11:16 AM Or Ozeri wrote: > > > > > -Original Message- > > From: Ilya Dryomov > > Sent: 11 November 2022 15:01 > > To: Or Ozeri > > Cc: qemu-devel@nongnu.org; qemu-bl...@nongnu.org; Danny Harnik > > > > Subject: [EXTERNAL] Re: [PATCH v1] block/rbd: Add support for

Re: [PATCH v4 4/7] target/arm: Enable TTBCR_EAE for ARMv8-R AArch32

2022-11-15 Thread Daniel P . Berrangé
On Tue, Nov 15, 2022 at 12:37:45PM +0100, Philippe Mathieu-Daudé wrote: > On 14/11/22 18:19, Peter Maydell wrote: > > On Sun, 23 Oct 2022 at 16:37, wrote: > > > > > > From: Tobias Röhmel > > > > > > ARMv8-R AArch32 CPUs behave as if TTBCR.EAE is always 1 even > > > tough they don't have the TTB

Re: [PATCH v2] disas: recognize either or

2022-11-15 Thread Michael Tokarev
15.11.2022 14:55, Michael Tokarev wrote: + config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H') GHRRR! I especially verified this path, and fixed an error in there: config_host_data.set() expects 2 arguments, not 1. But I forgot to commit the fix before sending the patch... *sigh*. This ca

Re: [PATCH v2] block/rbd: Add support for layered encryption

2022-11-15 Thread Ilya Dryomov
On Sun, Nov 13, 2022 at 11:17 AM Or Ozeri wrote: > > Starting from ceph Reef, RBD has built-in support for layered encryption, > where each ancestor image (in a cloned image setting) can be possibly > encrypted using a unique passphrase. > > A new function, rbd_encryption_load2, was added to librb

Re: [PATCH] hw/loongarch: Add cfi01 pflash device

2022-11-15 Thread Philippe Mathieu-Daudé
On 15/11/22 12:56, Xiaojuan Yang wrote: Add cfi01 pflash device for LoongArch virt machine So the subject prefix should be "hw/loongarch/virt:". Signed-off-by: Xiaojuan Yang --- hw/loongarch/Kconfig| 1 + hw/loongarch/acpi-build.c | 39 +++ hw/loongarch/virt.c

[PATCH 07/30] migration: Export ram_release_page()

2022-11-15 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Leonardo Bras --- migration/ram.h | 1 + migration/ram.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/migration/ram.h b/migration/ram.h index e844966f69..038d52f49f 100644 --- a/migration/ram.h +++ b/migration/ram.h @@ -66,6 +66,

[PATCH 02/30] migration/multifd/zero-copy: Create helper function for flushing

2022-11-15 Thread Juan Quintela
From: Leonardo Bras Move flushing code from multifd_send_sync_main() to a new helper, and call it in multifd_send_sync_main(). Signed-off-by: Leonardo Bras Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/multifd.c | 30 +++--- 1 file changed, 19

[PATCH 03/30] migration: check magic value for deciding the mapping of channels

2022-11-15 Thread Juan Quintela
From: "manish.mishra" Current logic assumes that channel connections on the destination side are always established in the same order as the source and the first one will always be the main channel followed by the multifid or post-copy preemption channel. This may not be always true, as even if a

[PATCH 06/30] migration: Export ram_transferred_ram()

2022-11-15 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert Reviewed-by: David Edmondson Reviewed-by: Leonardo Bras --- migration/ram.h | 2 ++ migration/ram.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/migration/ram.h b/migration/ram.h index c7af65ac74..e844966

[PATCH 09/30] Unit test code and benchmark code

2022-11-15 Thread Juan Quintela
From: ling xu Unit test code is in test-xbzrle.c, and benchmark code is in xbzrle-bench.c for performance benchmarking. Signed-off-by: ling xu Co-authored-by: Zhou Zhao Co-authored-by: Jun Jin Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- tests/bench/xbzrle-bench.c | 465

[PATCH 20/30] migration: Yield bitmap_mutex properly when sending/sleeping

2022-11-15 Thread Juan Quintela
From: Peter Xu Don't take the bitmap mutex when sending pages, or when being throttled by migration_rate_limit() (which is a bit tricky to call it here in ram code, but seems still helpful). It prepares for the possibility of concurrently sending pages in >1 threads using the function ram_save_h

[PATCH 00/30] Migration PULL request

2022-11-15 Thread Juan Quintela
Hi It includes: - Leonardo fix for zero_copy flush - Fiona fix for return value of readv/writev - Peter Xu cleanups - Peter Xu preempt patches - Patches ready from zero page (me) - AVX2 support (ling) - fix for slow networking and reordering of first packets (manish) Please, apply. Fiona Ebner (

[PATCH 08/30] Update AVX512 support for xbzrle_encode_buffer

2022-11-15 Thread Juan Quintela
From: ling xu This commit updates code of avx512 support for xbzrle_encode_buffer function to accelerate xbzrle encoding speed. Runtime check of avx512 support and benchmark for this feature are added. Compared with C version of xbzrle_encode_buffer function, avx512 version can achieve 50%-70% pe

[PATCH 04/30] multifd: Create page_size fields into both MultiFD{Recv, Send}Params

2022-11-15 Thread Juan Quintela
We were calling qemu_target_page_size() left and right. Signed-off-by: Juan Quintela Reviewed-by: Leonardo Bras --- migration/multifd.h | 4 migration/multifd-zlib.c | 14 ++ migration/multifd-zstd.c | 12 +--- migration/multifd.c | 18 -- 4 f

[PATCH 29/30] migration: Drop rs->f

2022-11-15 Thread Juan Quintela
From: Peter Xu Now with rs->pss we can already cache channels in pss->pss_channels. That pss_channel contains more infromation than rs->f because it's per-channel. So rs->f could be replaced by rss->pss[RAM_CHANNEL_PRECOPY].pss_channel, while rs->f itself is a bit vague now. Note that vanilla p

[PATCH 17/30] migration: Cleanup xbzrle zero page cache update logic

2022-11-15 Thread Juan Quintela
From: Peter Xu The major change is to replace "!save_page_use_compression()" with "xbzrle_enabled" to make it clear. Reasonings: (1) When compression enabled, "!save_page_use_compression()" is exactly the same as checking "xbzrle_enabled". (2) When compression disabled, "!save_page_use_com

[PATCH 22/30] migration: Teach PSS about host page

2022-11-15 Thread Juan Quintela
From: Peter Xu Migration code has a lot to do with host pages. Teaching PSS core about the idea of host page helps a lot and makes the code clean. Meanwhile, this prepares for the future changes that can leverage the new PSS helpers that this patch introduces to send host page in another thread

[PATCH 23/30] migration: Introduce pss_channel

2022-11-15 Thread Juan Quintela
From: Peter Xu Introduce pss_channel for PageSearchStatus, define it as "the migration channel to be used to transfer this host page". We used to have rs->f, which is a mirror to MigrationState.to_dst_file. After postcopy preempt initial version, rs->f can be dynamically changed depending on wh

[PATCH 14/30] migration: Disable multifd explicitly with compression

2022-11-15 Thread Juan Quintela
From: Peter Xu Multifd thread model does not work for compression, explicitly disable it. Note that previuosly even we can enable both of them, nothing will go wrong, because the compression code has higher priority so multifd feature will just be ignored. Now we'll fail even earlier at config

[PATCH 15/30] migration: Take bitmap mutex when completing ram migration

2022-11-15 Thread Juan Quintela
From: Peter Xu Any call to ram_find_and_save_block() needs to take the bitmap mutex. We used to not take it for most of ram_save_complete() because we thought we're the only one left using the bitmap, but it's not true after the preempt full patchset applied, since the return path can be taking

[PATCH 28/30] migration: Remove old preempt code around state maintainance

2022-11-15 Thread Juan Quintela
From: Peter Xu With the new code to send pages in rp-return thread, there's little help to keep lots of the old code on maintaining the preempt state in migration thread, because the new way should always be faster.. Then if we'll always send pages in the rp-return thread anyway, we don't need t

[PATCH 18/30] migration: Trivial cleanup save_page_header() on same block check

2022-11-15 Thread Juan Quintela
From: Peter Xu The 2nd check on RAM_SAVE_FLAG_CONTINUE is a bit redundant. Use a boolean to be clearer. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 5 +++-- 1 file changed, 3 insertions(+), 2 dele

[PATCH 13/30] migration: Use non-atomic ops for clear log bitmap

2022-11-15 Thread Juan Quintela
From: Peter Xu Since we already have bitmap_mutex to protect either the dirty bitmap or the clear log bitmap, we don't need atomic operations to set/clear/test on the clear log bitmap. Switching all ops from atomic to non-atomic versions, meanwhile touch up the comments to show which lock is in

[PATCH 24/30] migration: Add pss_init()

2022-11-15 Thread Juan Quintela
From: Peter Xu Helper to init PSS structures. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/migration/ram.c b/migration/

[PATCH 26/30] migration: Move last_sent_block into PageSearchStatus

2022-11-15 Thread Juan Quintela
From: Peter Xu Since we use PageSearchStatus to represent a channel, it makes perfect sense to keep last_sent_block (aka, leverage RAM_SAVE_FLAG_CONTINUE) to be per-channel rather than global because each channel can be sending different pages on ramblocks. Hence move it from RAMState into PageS

[PATCH 19/30] migration: Remove RAMState.f references in compression code

2022-11-15 Thread Juan Quintela
From: Peter Xu Removing referencing to RAMState.f in compress_page_with_multi_thread() and flush_compressed_data(). Compression code by default isn't compatible with having >1 channels (or it won't currently know which channel to flush the compressed data), so to make it simple we always flush o

[PATCH 11/30] migration: Fix race on qemu_file_shutdown()

2022-11-15 Thread Juan Quintela
From: Peter Xu In qemu_file_shutdown(), there's a possible race if with current order of operation. There're two major things to do: (1) Do real shutdown() (e.g. shutdown() syscall on socket) (2) Update qemufile's last_error We must do (2) before (1) otherwise there can be a race condition

[PATCH 12/30] migration: Disallow postcopy preempt to be used with compress

2022-11-15 Thread Juan Quintela
From: Peter Xu The preempt mode requires the capability to assign channel for each of the page, while the compression logic will currently assign pages to different compress thread/local-channel so potentially they're incompatible. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Peter Xu Re

Re: [PATCH v2] disas: recognize either or

2022-11-15 Thread Richard Henderson
On 11/15/22 21:55, Michael Tokarev wrote: Historically, capstone varies in requiring either or include depending on version and the way how it has been installed. This has already been an issue before, and will likely become an issue again with capstone 5.0 which seem to have changed this aspe

[PATCH 27/30] migration: Send requested page directly in rp-return thread

2022-11-15 Thread Juan Quintela
From: Peter Xu With all the facilities ready, send the requested page directly in the rp-return thread rather than queuing it in the request queue, if and only if postcopy preempt is enabled. It can achieve so because it uses separate channel for sending urgent pages. The only shared data is bi

[PATCH 10/30] migration: Fix possible infinite loop of ram save process

2022-11-15 Thread Juan Quintela
From: Peter Xu When starting ram saving procedure (especially at the completion phase), always set last_seen_block to non-NULL to make sure we can always correctly detect the case where "we've migrated all the dirty pages". Then we'll guarantee both last_seen_block and pss.block will be valid al

[PATCH 25/30] migration: Make PageSearchStatus part of RAMState

2022-11-15 Thread Juan Quintela
From: Peter Xu We used to allocate PSS structure on the stack for precopy when sending pages. Make it static, so as to describe per-channel ram migration status. Here we declared RAM_CHANNEL_MAX instances, preparing for postcopy to use it, even though this patch has not yet to start using the 2

[PATCH 01/30] migration/channel-block: fix return value for qio_channel_block_{readv, writev}

2022-11-15 Thread Juan Quintela
From: Fiona Ebner in the error case. The documentation in include/io/channel.h states that -1 or QIO_CHANNEL_ERR_BLOCK should be returned upon error. Simply passing along the return value from the bdrv-functions has the potential to confuse the call sides. Non-blocking mode is not implemented cur

[PATCH 05/30] multifd: Create page_count fields into both MultiFD{Recv, Send}Params

2022-11-15 Thread Juan Quintela
We were recalculating it left and right. We plan to change that values on next patches. Signed-off-by: Juan Quintela Reviewed-by: Leonardo Bras --- migration/multifd.h | 4 migration/multifd.c | 7 --- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/migration/multifd.h

[PATCH v3] block/rbd: Add support for layered encryption

2022-11-15 Thread Or Ozeri
Starting from ceph Reef, RBD has built-in support for layered encryption, where each ancestor image (in a cloned image setting) can be possibly encrypted using a unique passphrase. A new function, rbd_encryption_load2, was added to librbd API. This new function supports an array of passphrases (vi

[PATCH 21/30] migration: Use atomic ops properly for page accountings

2022-11-15 Thread Juan Quintela
From: Peter Xu To prepare for thread-safety on page accountings, at least below counters need to be accessed only atomically, they are: ram_counters.transferred ram_counters.duplicate ram_counters.normal ram_counters.postcopy_bytes There are a lot of other counte

[PATCH 30/30] migration: Block migration comment or code is wrong

2022-11-15 Thread Juan Quintela
And it appears that what is wrong is the code. During bulk stage we need to make sure that some block is dirty, but no games with max_size at all. Signed-off-by: Juan Quintela Reviewed-by: Stefan Hajnoczi --- migration/block.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --gi

[PATCH 16/30] migration: Add postcopy_preempt_active()

2022-11-15 Thread Juan Quintela
From: Peter Xu Add the helper to show that postcopy preempt enabled, meanwhile active. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff

RE: [PATCH v1] block/rbd: Add support for layered encryption

2022-11-15 Thread Or Ozeri
I tried casting to non-const and it seems to work. Changed in v3 now. I did not know that a const modifier could simply be cast out :) > -Original Message- > From: Ilya Dryomov > Sent: 15 November 2022 14:00 > To: Or Ozeri > Cc: qemu-devel@nongnu.org; qemu-bl...@nongnu.org; Danny Harnik

Re: [PATCH v2] disas: recognize either or

2022-11-15 Thread Michael Tokarev
15.11.2022 14:55, Michael Tokarev wrote: +elif cc.has_header('capstone/capstone.h', dependencies: [capstone]) + config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H') This needs to be config_host_data.set('HAVE_CAPSTONE_CAPSTONE_H', 1) It either can be fixed at apply time or I rese

Re: [PATCH v2 3/8] target/riscv: add support for Zcd extension

2022-11-15 Thread Richard Henderson
On 11/13/22 12:32, Weiwei Li wrote: Separate c_fld/c_fsd from fld/fsd to add additional check for c.fld{sp}/c.fsd{sp} which is useful for zcmp/zcmt to reuse their encodings Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang --- target/riscv/insn16.decode | 8 target/

Re: [PATCH 0/1] hw/arm/aspeed: Automatically zero-extend flash images

2022-11-15 Thread Cédric Le Goater
Hello Peter, On 11/14/22 20:08, Peter Delevoryas wrote: I've been using this patch for a long time so that I don't have to use dd to zero-extend stuff all the time. It's just doing what people are doing already, right? I hope it's not controversial. I simply run : truncate --size on the

Re: [PATCH v1 5/9] hw/virtio: introduce virtio_device_should_start

2022-11-15 Thread Christian Borntraeger
Am 15.11.22 um 12:25 schrieb Michael S. Tsirkin: On Tue, Nov 15, 2022 at 09:18:27AM +0100, Christian Borntraeger wrote: Am 14.11.22 um 18:20 schrieb Michael S. Tsirkin: On Mon, Nov 14, 2022 at 06:15:30PM +0100, Christian Borntraeger wrote: Am 14.11.22 um 18:10 schrieb Michael S. Tsirkin:

Re: [PATCH v11 08/11] s390x/cpu topology: add topology_capable QEMU capability

2022-11-15 Thread Cédric Le Goater
On 11/3/22 18:01, Pierre Morel wrote: S390 CPU topology is only allowed for s390-virtio-ccw-7.2 and newer S390 machines. Signed-off-by: Pierre Morel Reviewed-by: Cédric Le Goater Thanks, C. --- include/hw/s390x/s390-virtio-ccw.h | 1 + hw/s390x/s390-virtio-ccw.c | 2 ++ 2 fil

[PULL 10/10] gitlab: integrate coverage report

2022-11-15 Thread Alex Bennée
This should hopefully give is nice coverage information about what our tests (or at least the subset we are running) have hit. Ideally we would want a way to trigger coverage on tests likely to be affected by the current commit. Signed-off-by: Alex Bennée Acked-by: Stefan Hajnoczi Message-Id: <2

[PULL for 7.2 00/10] testing and doc updates

2022-11-15 Thread Alex Bennée
The following changes since commit 98f10f0e2613ba1ac2ad3f57a5174014f6dcb03d: Merge tag 'pull-target-arm-20221114' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2022-11-14 13:31:17 -0500) are available in the Git repository at: https://gitlab.com/stsquad/qemu.git tags/pul

[PULL 05/10] docs/devel: add a maintainers section to development process

2022-11-15 Thread Alex Bennée
We don't currently have a clear place in the documentation to describe the roles and responsibilities of a maintainer. Lets create one so we can. I've moved a few small bits out of other files to try and keep everything in one place. Signed-off-by: Alex Bennée Reviewed-by: Stefan Hajnoczi Review

[PULL 02/10] tests/avocado: improve behaviour waiting for login prompts

2022-11-15 Thread Alex Bennée
This attempts to deal with the problem of login prompts not being guaranteed to be terminated with a newline. The solution to this is to peek at the incoming data looking to see if we see an up-coming match before we fall back to the old readline() logic. The reason to mostly rely on readline is be

[PULL 07/10] docs/devel: simplify the minimal checklist

2022-11-15 Thread Alex Bennée
The bullet points are quite long and contain process tips. Move those bits of the bullet to the relevant sections and link to them. Use a table for nicer formatting of the checklist. Signed-off-by: Alex Bennée Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <2022145529.4

[PULL 06/10] docs/devel: make language a little less code centric

2022-11-15 Thread Alex Bennée
We welcome all sorts of patches. Signed-off-by: Alex Bennée Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <2022145529.4020801-7-alex.ben...@linaro.org> diff --git a/docs/devel/submitting-a-patch.rst b/docs/devel/submitting-a-patch.rst index fec33ce148..9c7c4331f3 100

[PULL 04/10] tests/docker: allow user to override check target

2022-11-15 Thread Alex Bennée
This is useful when trying to bisect a particular failing test behind a docker run. For example: make docker-test-clang@fedora \ TARGET_LIST=arm-softmmu \ TEST_COMMAND="meson test qtest-arm/qos-test" \ J=9 V=1 Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-

[PULL 08/10] docs/devel: try and improve the language around patch review

2022-11-15 Thread Alex Bennée
It is important that contributors take the review process seriously and we collaborate in a respectful way while avoiding personal attacks. Try and make this clear in the language. Signed-off-by: Alex Bennée Reviewed-by: Markus Armbruster Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini

  1   2   3   >