[PATCH] semihosting/uaccess.c: Replaced a malloc call with g_malloc.

2023-07-26 Thread dinglimin
Replaced a call to malloc() and its respective call to free() with g_malloc() and g_free(). Signed-off-by: dinglimin V3 -> V4:Delete null checks after g malloc(). g_malloc() is preferred more than g_try_* functions, which return NULL on error, when the size of the requested allocation is small

Re: [PATCH v2 1/6] python/machine: move socket setup out of _base_args property

2023-07-26 Thread Ani Sinha
> On 25-Jul-2023, at 11:33 PM, John Snow wrote: > > This property isn't meant to do much else besides return a list of > strings, so move this setup back out into _pre_launch(). > > Signed-off-by: John Snow Reviewed-by: Ani Sinha > --- > python/qemu/machine/machine.py | 5 ++--- > 1 file c

Re: how to build qemu 8.1 - keycodemapdb?

2023-07-26 Thread Michael Tokarev
26.07.2023 09:41, Michael Tokarev wrote: Looks like scripts/make-release.sh needs some updating. make-release.sh apparently does the right thing. But the published tarball does not include the 3 required sub-projects anyway. Is it about how the release is made? What is used to make the actua

回复: [PATCH v1] block/stream:add flush l2_table_cache,ensure data integrity

2023-07-26 Thread 张承
>On 25.07.23 18:13, Denis V. Lunev wrote: >>On 7/25/23 16:25, Vladimir Sementsov-Ogievskiy wrote: >>>On 24.07.23 10:30, Evanzhang wrote: On 7/26/23 01:41, Vladimir Sementsov-Ogievskiy wrote: block_stream will not actively flush l2_table_cache,when qemu process exception exit,causing

Re: [PATCH v7 4/4] tests/qtest: Introduce tests for UFS

2023-07-26 Thread Thomas Huth
Hi! On 26/07/2023 07.30, Jeuk Kim wrote: This patch includes the following tests Test mmio read Test ufs device initialization and ufs-lu recognition Test I/O (Performs a write followed by a read to verify) Signed-off-by: Jeuk Kim --- ... diff --git a/tests/qtest/ufs-test.c b/tests

Re: [PATCH v2 2/6] python/machine: close sock_pair in cleanup path

2023-07-26 Thread Ani Sinha
> On 25-Jul-2023, at 11:48 PM, Daniel P. Berrangé wrote: > > On Tue, Jul 25, 2023 at 02:03:33PM -0400, John Snow wrote: >> If everything has gone smoothly, we'll already have closed the socket we >> gave to the child during post_launch. The other half of the pair that we >> gave to the QMP con

Re: [PATCH 1/2] block/blkio: fix opening virtio-blk drivers

2023-07-26 Thread Stefano Garzarella
On Tue, Jul 25, 2023 at 04:00:38PM -0400, Stefan Hajnoczi wrote: On Mon, Jul 24, 2023 at 05:46:10PM +0200, Stefano Garzarella wrote: libblkio 1.3.0 added support of "fd" property for virtio-blk-vhost-vdpa driver. In QEMU, starting from commit cad2ccc395 ("block/blkio: use qemu_open() to support

Re: [PATCH 2/2] block/blkio: use blkio_set_int("fd") to check fd support

2023-07-26 Thread Stefano Garzarella
On Tue, Jul 25, 2023 at 04:05:38PM -0400, Stefan Hajnoczi wrote: On Mon, Jul 24, 2023 at 05:46:11PM +0200, Stefano Garzarella wrote: The way the virtio-blk driver is implemented in libblkio, it's much easier to use blkio_set_int() instead of blkio_get_int() and have it fail right away to see if

Re: avocado test failing INTERRUPTED for "Missing asset"

2023-07-26 Thread Philippe Mathieu-Daudé
On 25/7/23 19:13, Peter Maydell wrote: Currently this CI job is failing: https://gitlab.com/qemu-project/qemu/-/jobs/4737819946 because: (05/59) tests/avocado/boot_linux_console.py:BootLinuxConsole.test_arm_exynos4210_initrd: INTERRUPTED: Missing asset https://snapshot.debian.org/archive/debi

[RESEND PATCH v3 1/1] target/riscv: Add Zihintntl extension ISA string to DTS

2023-07-26 Thread Jason Chien
RVA23 Profiles states: The RVA23 profiles are intended to be used for 64-bit application processors that will run rich OS stacks from standard binary OS distributions and with a substantial number of third-party binary user applications that will be supported over a considerable length of time in t

[RESEND PATCH v3 0/1] target/riscv: Add Zihintntl extension ISA string to DTS

2023-07-26 Thread Jason Chien
In v2, I rebased the patch on https://github.com/alistair23/qemu/tree/riscv-to-apply.next However, I forgot to add "Reviewed-by" in v2, so I add them in v3. Jason Chien (1): target/riscv: Add Zihintntl extension ISA string to DTS target/riscv/cpu.c | 2 ++ target/riscv/cpu_cfg.h | 1 + 2 f

[PATCH v2] block/blkio: do not use open flags in qemu_open()

2023-07-26 Thread Stefano Garzarella
qemu_open() in blkio_virtio_blk_common_open() is used to open the character device (e.g. /dev/vhost-vdpa-0 or /dev/vfio/vfio) or in the future eventually the unix socket. In all these cases we cannot open the path in read-only mode, when the `read-only` option of blockdev is on, because the exchan

Re: s390 intermittent test failure in qemu:block / io-qcow2-copy-before-write

2023-07-26 Thread Christian Borntraeger
Am 25.07.23 um 18:45 schrieb Peter Maydell: There seems to be an intermittent failure on the s390 host in the qemu:block / io-qcow2-copy-before-write test: https://gitlab.com/qemu-project/qemu/-/jobs/4737819873 The log says the test was expecting to do some reading and writing but got an unex

Re: [PATCH v21 03/20] target/s390x/cpu topology: handle STSI(15) and build the SYSIB

2023-07-26 Thread Pierre Morel
On 7/25/23 17:41, Nina Schoetterl-Glausch wrote: On Fri, 2023-06-30 at 11:17 +0200, Pierre Morel wrote: On interception of STSI(15.1.x) the System Information Block (SYSIB) is built from the list of pre-ordered topology entries. Signed-off-by: Pierre Morel --- MAINTAINERS

Re: vdpa: use io_uring passthrough command for IOCTLs [was Re: [PATCH 1/2] Reduce vdpa initialization / startup overhead]

2023-07-26 Thread Jason Wang
On Tue, Jul 18, 2023 at 6:32 PM Stefano Garzarella wrote: > > On Thu, Apr 20, 2023 at 6:20 AM Jason Wang wrote: > > > > On Wed, Apr 19, 2023 at 11:33 PM Eugenio Perez Martin > > wrote: > > > > > > On Wed, Apr 19, 2023 at 12:56 AM wrote: > > > > > > > > From: Pei Li > > > > > > > > Currently, p

Re: [PATCH] Open file as read only on private mapping in qemu_ram_alloc_from_file

2023-07-26 Thread David Hildenbrand
On 25.07.23 18:01, ThinerLogoer wrote: At 2023-07-25 19:42:30, "David Hildenbrand" wrote: Hi, patch subject should start with "softmmu/physmem: Open ..." Sorry I am newbie to the patch submission part. I will resubmit a version of patch if the final acceptable patch after discussion is mos

Re: [PATCH v7 4/4] tests/qtest: Introduce tests for UFS

2023-07-26 Thread Jeuk Kim
On 7/26/2023 4:21 PM, Thomas Huth wrote:  Hi! On 26/07/2023 07.30, Jeuk Kim wrote: This patch includes the following tests    Test mmio read    Test ufs device initialization and ufs-lu recognition    Test I/O (Performs a write followed by a read to verify) Signed-off-by: Jeuk Kim --- ...

[RFC PATCH] target/i386: Truncate ESP when exiting from long mode

2023-07-26 Thread Ard Biesheuvel
While working on some EFI boot changes for Linux/x86, I noticed that TCG deviates from bare metal when it comes to how it handles the value of the stack pointer register RSP when dropping out of long mode. On bare metal, RSP is truncated to 32 bits, even if the code that runs in 32-bit protected m

Re: [PATCH v2] block/blkio: do not use open flags in qemu_open()

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 09:48:07AM +0200, Stefano Garzarella wrote: > qemu_open() in blkio_virtio_blk_common_open() is used to open the > character device (e.g. /dev/vhost-vdpa-0 or /dev/vfio/vfio) or in > the future eventually the unix socket. > > In all these cases we cannot open the path in rea

Re: [PATCH 01/10] hw/arm/virt-acpi-build.c: Move fw_cfg and virtio to common location

2023-07-26 Thread Igor Mammedov
On Tue, 25 Jul 2023 22:20:36 +0530 Sunil V L wrote: > On Mon, Jul 24, 2023 at 05:18:59PM +0200, Igor Mammedov wrote: > > On Wed, 12 Jul 2023 22:09:34 +0530 > > Sunil V L wrote: > > > > > The functions which add fw_cfg and virtio to DSDT are same for ARM > > > and RISC-V. So, instead of duplic

Re: [PATCH v4] block-jobs: flush target at the end of .run()

2023-07-26 Thread Denis V. Lunev
On 7/25/23 19:40, Vladimir Sementsov-Ogievskiy wrote: From: Vladimir Sementsov-Ogievskiy Actually block job is not completed without this final flush. It's rather unexpected to have broken target when job was successfully completed long ago and now we fail to flush or process just crashed/kille

Re: [PATCH v9 06/10] migration: New migrate and migrate-incoming argument 'channels'

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 01:24:48AM +0530, Het Gala wrote: > Sorry, last reply on this patch was accidently replied only to Daniel. > Pasting the reply again so it is received by all the active maintianers > here. Apologies for the error 😅 > > On 26/07/23 12:07 am, Daniel P. Berrangé wrote: > > On

Re: i386/xen: prevent guest from binding loopback event channel to itself

2023-07-26 Thread Paul Durrant
On 25/07/2023 11:05, David Woodhouse wrote: From: David Woodhouse Fuzzing showed that a guest could bind an interdomain port to itself, by guessing the next port to be allocated and putting that as the 'remote' port number. By chance, that works because the newly-allocated port has type EVTCHNS

Re: how to build qemu 8.1 - keycodemapdb?

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 10:15:24AM +0300, Michael Tokarev wrote: > 26.07.2023 09:41, Michael Tokarev wrote: > > > Looks like scripts/make-release.sh needs some updating. FWIW, i see the same problem as you: $ ./configure --target-list=x86_64-softmmu --disable-download Using './build' as the dir

Re: [PATCH v2 1/3] block: add subcluster_size field to BlockDriverInfo

2023-07-26 Thread Vladimir Sementsov-Ogievskiy
On 11.07.23 20:25, Andrey Drobyshev wrote: This is going to be used in the subsequent commit as requests alignment (in particular, during copy-on-read). This value only makes sense for the formats which support subclusters (currently QCOW2 only). If this field isn't set by driver's own bdrv_get

Re: how to build qemu 8.1 - keycodemapdb?

2023-07-26 Thread Michael Tokarev
26.07.2023 11:50, Daniel P. Berrangé wrote: .. make-release.sh apparently does the right thing. But the published tarball does not include the 3 required sub-projects anyway. Is it about how the release is made? What is used to make the actual release tarball, is it not make-release.sh? make-

Re: i386/xen: prevent guest from binding loopback event channel to itself

2023-07-26 Thread David Woodhouse
On Wed, 2023-07-26 at 09:44 +0100, Paul Durrant wrote: > On 25/07/2023 11:05, David Woodhouse wrote: > > From: David Woodhouse > > > > Fuzzing showed that a guest could bind an interdomain port to itself, by > > guessing the next port to be allocated and putting that as the 'remote' > > port numb

Re: avocado test failing INTERRUPTED for "Missing asset"

2023-07-26 Thread Thomas Huth
On 26/07/2023 09.33, Philippe Mathieu-Daudé wrote: On 25/7/23 19:13, Peter Maydell wrote: Currently this CI job is failing: https://gitlab.com/qemu-project/qemu/-/jobs/4737819946 because: (05/59) tests/avocado/boot_linux_console.py:BootLinuxConsole.test_arm_exynos4210_initrd: INTERRUPTED: M

Re: [PATCH v2 2/3] block/io: align requests to subcluster_size

2023-07-26 Thread Vladimir Sementsov-Ogievskiy
On 11.07.23 20:25, Andrey Drobyshev wrote: When target image is using subclusters, and we align the request during copy-on-read, it makes sense to align to subcluster_size rather than cluster_size. Otherwise we end up with unnecessary allocations. This commit renames bdrv_round_to_clusters() to

Re: how to build qemu 8.1 - keycodemapdb?

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 12:05:41PM +0300, Michael Tokarev wrote: > 26.07.2023 11:50, Daniel P. Berrangé wrote: > .. > > > make-release.sh apparently does the right thing. But the published > > > tarball does not include the 3 required sub-projects anyway. > > > > > > Is it about how the release is

Re: [PATCH] hw/xen: Clarify (lack of) error handling in transaction_commit()

2023-07-26 Thread Paul Durrant
On 20/06/2023 18:58, David Woodhouse wrote: From: David Woodhouse Coverity was unhappy (CID 1508359) because we didn't check the return of init_walk_op() in transaction_commit(), despite doing so at every other call site. Strictly speaking, this is a false positive since it can never fail. It

Re: i386/xen: prevent guest from binding loopback event channel to itself

2023-07-26 Thread Paul Durrant
On 26/07/2023 10:07, David Woodhouse wrote: On Wed, 2023-07-26 at 09:44 +0100, Paul Durrant wrote: On 25/07/2023 11:05, David Woodhouse wrote: From: David Woodhouse Fuzzing showed that a guest could bind an interdomain port to itself, by guessing the next port to be allocated and putting that

Re: [PATCH v2 3/3] tests/qemu-iotests/197: add testcase for CoR with subclusters

2023-07-26 Thread Vladimir Sementsov-Ogievskiy
On 11.07.23 20:25, Andrey Drobyshev via wrote: Add testcase which checks that allocations during copy-on-read are performed on the subcluster basis when subclusters are enabled in target image. This testcase also triggers the following assert with previous commit not being applied, so we check t

Re: [PATCH v8 01/10] parallels: Fix comments formatting inside parallels driver

2023-07-26 Thread Denis V. Lunev
On 7/18/23 12:44, Alexander Ivanov wrote: This patch is technically necessary as git patch rendering could result in moving some code from one place to the another and that hits checkpatch.pl warning. This problem specifically happens within next series. Signed-off-by: Alexander Ivanov --- bl

Re: [PATCH] semihosting/uaccess.c: Replaced a malloc call with g_malloc.

2023-07-26 Thread Peter Maydell
(Something went wrong with the quoting in your email. I've fixed it up.) On Wed, 26 Jul 2023 at 05:38, wrote: > Peter Maydell wrote: > > The third part here, is that g_malloc() does not ever > > fail -- it will abort() on out of memory. However > > the code here is still handling g_malloc() retur

Re: [PATCH v9 06/10] migration: New migrate and migrate-incoming argument 'channels'

2023-07-26 Thread Het Gala
On 26/07/23 2:05 pm, Daniel P. Berrangé wrote: On Wed, Jul 26, 2023 at 01:24:48AM +0530, Het Gala wrote: Sorry, last reply on this patch was accidently replied only to Daniel. Pasting the reply again so it is received by all the active maintianers here. Apologies for the error 😅 On 26/07/23 1

Re: [Stable-8.0.4 00/31] Patch Round-up for stable 8.0.4, freeze on 2023-08-05

2023-07-26 Thread Olaf Hering
Tue, 25 Jul 2023 16:45:17 +0300 Michael Tokarev : > Please respond here or CC qemu-sta...@nongnu.org on any additional patches > you think should (or shouldn't) be included in the release. Consider 497fad38979c16b6412388927401e577eba43d26 ("pc-bios/keymaps: Use the official xkb name for Arabic l

Re: [Stable-8.0.4 00/31] Patch Round-up for stable 8.0.4, freeze on 2023-08-05

2023-07-26 Thread Michael Tokarev
26.07.2023 13:07, Olaf Hering пишет: Tue, 25 Jul 2023 16:45:17 +0300 Michael Tokarev : Please respond here or CC qemu-sta...@nongnu.org on any additional patches you think should (or shouldn't) be included in the release. Consider 497fad38979c16b6412388927401e577eba43d26 ("pc-bios/keymaps: Us

Re: [Stable-8.0.4 00/31] Patch Round-up for stable 8.0.4, freeze on 2023-08-05

2023-07-26 Thread Olaf Hering
Wed, 26 Jul 2023 13:12:43 +0300 Michael Tokarev : > This one is included in 8.0.3 and 7.2.4 already, picked up for the previous > stable series/releases. Indeed. I just noticed I still had 8.0.2 exported, sorry for the noise. Olaf pgpk0hLzJTvpI.pgp Description: Digitale Signatur von OpenPGP

Re: [PATCH v2 4/6] python/machine: use socketpair() for console connections

2023-07-26 Thread Ani Sinha
> On 25-Jul-2023, at 11:33 PM, John Snow wrote: > > Create a socketpair for the console output. This should help eliminate > race conditions around console text early in the boot process that might > otherwise have been dropped on the floor before being able to connect to > QEMU under "server,

[PULL 2/5] qapi/block: Tidy up block-latency-histogram-set documentation

2023-07-26 Thread Markus Armbruster
Examples come out like Example set new histograms for all io types with intervals [0, 10), [10, 50), [50, 100), [100, +inf): The sentence "set new histograms ..." starts with a lower case letter. Capitalize it. Same for the other examples. Signed-off-by: Markus Armbruster Me

[PULL 0/5] QAPI patches patches for 2023-07-26

2023-07-26 Thread Markus Armbruster
The following changes since commit 6cb2011fedf8c4e7b66b4a3abd6b42c1bae99ce6: Update version for v8.1.0-rc1 release (2023-07-25 20:09:05 +0100) are available in the Git repository at: https://repo.or.cz/qemu/armbru.git tags/pull-qapi-2023-07-26 for you to fetch changes up to 1799bdcb47d8368c

[PULL 5/5] qapi: Reformat recent doc comments to conform to current conventions

2023-07-26 Thread Markus Armbruster
Since commit a937b6aa739 (qapi: Reformat doc comments to conform to current conventions), a number of comments not conforming to the current formatting conventions were added. No problem, just sweep the entire documentation once more. To check the generated documentation does not change, I compar

[PULL 1/5] qapi/block-core: Tidy up BlockLatencyHistogramInfo documentation

2023-07-26 Thread Markus Armbruster
Documentation for member @bin comes out like list of io request counts corresponding to histogram intervals. len("bins") = len("boundaries") + 1 For the example above, "bins" may be something like [3, 1, 5, 2], and corresponding histogram looks like: Note how the equation and the

[PULL 4/5] qapi/trace: Tidy up trace-event-get-state, -set-state documentation

2023-07-26 Thread Markus Armbruster
trace-event-set-state's explanation of how events are selected is under "Features". Doesn't belong there. Simply delete it, as it feels redundant with documentation of member @name. trace-event-get-state's explanation is under "Returns". Tolerable, but similarly redundant. Delete it, too. Cc:

[PULL 3/5] qapi/qdev: Tidy up device_add documentation

2023-07-26 Thread Markus Armbruster
The notes section comes out like this: Notes Additional arguments depend on the type. 1. For detailed information about this command, please refer to the ‘docs/qdev-device-use.txt’ file. 2. It’s possible to list device properties by running QEMU with the “-device D

Re: [PULL 1/5] qapi/block-core: Tidy up BlockLatencyHistogramInfo documentation

2023-07-26 Thread Vladimir Sementsov-Ogievskiy
On 26.07.23 14:28, Markus Armbruster wrote: Documentation for member @bin comes out like list of io request counts corresponding to histogram intervals. len("bins") = len("boundaries") + 1 For the example above, "bins" may be something like [3, 1, 5, 2], and corresponding histogra

Re: [PATCH v21 12/20] qapi/s390x/cpu topology: query-cpu-polarization qmp command

2023-07-26 Thread Nina Schoetterl-Glausch
On Fri, 2023-06-30 at 11:17 +0200, Pierre Morel wrote: > The query-cpu-polarization qmp command returns the current > CPU polarization of the machine. > > Signed-off-by: Pierre Morel Reviewed-by: Nina Schoetterl-Glausch [...]

Re: [PULL 1/5] qapi/block-core: Tidy up BlockLatencyHistogramInfo documentation

2023-07-26 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > On 26.07.23 14:28, Markus Armbruster wrote: >> Documentation for member @bin comes out like >> list of io request counts corresponding to histogram intervals. >> len("bins") = len("boundaries") + 1 For the example above, "bins" >> may be somet

[PATCH] docs/devel: Add cross-compiling doc

2023-07-26 Thread Andrew Jones
Add instructions for how to cross-compile QEMU for RISC-V. The file is named generically because there's no reason not to collect other architectures steps into the same file, especially because several subsections like those for cross-compiling QEMU dependencies using meson and a cross-file could

How to tame CI?

2023-07-26 Thread Juan Quintela
Hi Now a not on CI, thas has been really bad. After too many problems with last PULLS, I decided to learn to use qemu CI. On one hand, it is not so difficult, even I can use it O:-) On the other hand, the amount of problems that I got is inmense. Some of them dissapear when I rerun the check

[PULL 00/25] Migration 20230726 patches

2023-07-26 Thread Juan Quintela
The following changes since commit 6cb2011fedf8c4e7b66b4a3abd6b42c1bae99ce6: Update version for v8.1.0-rc1 release (2023-07-25 20:09:05 +0100) are available in the Git repository at: https://gitlab.com/juan.quintela/qemu.git tags/migration-20230726-pull-request for you to fetch changes up

[PULL 12/25] migration-test: Make machine_opts regular with other options

2023-07-26 Thread Juan Quintela
Reviewed-by: Peter Xu Signed-off-by: Juan Quintela Message-ID: <20230608224943.3877-5-quint...@redhat.com> --- tests/qtest/migration-test.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c index 2296ed4bf5.

[PULL 01/25] migration/multifd: Rename threadinfo.c functions

2023-07-26 Thread Juan Quintela
From: Fabiano Rosas We're about to add more functions to this file so make it use the same coding style as the rest of the code. Signed-off-by: Fabiano Rosas Reviewed-by: Juan Quintela Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Peter Xu Message-Id: <20230607161306.31425-2-faro...@suse.

[PULL 06/25] migration: Introduce dirty-limit capability

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Introduce migration dirty-limit capability, which can be turned on before live migration and limit dirty page rate durty live migration. Introduce migrate_dirty_limit function to help check if dirty-limit capability enabled during live migration. Meanwhile, refactor vcpu_d

[PULL 14/25] migration-test: machine_opts is really arch specific

2023-07-26 Thread Juan Quintela
And it needs to be in both source and target, so put it on arch_opts. Reviewed-by: Peter Xu Message-ID: <20230608224943.3877-7-quint...@redhat.com> Signed-off-by: Juan Quintela --- tests/qtest/migration-test.c | 14 +- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/te

[PULL 10/25] migration: Extend query-migrate to provide dirty page limit info

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Extend query-migrate to provide throttle time and estimated ring full time with dirty-limit capability enabled, through which we can observe if dirty limit take effect during live migration. Signed-off-by: Hyman Huang(黄勇) Reviewed-by: Markus Armbruster Reviewed-by: Juan Q

[PULL 09/25] migration: Implement dirty-limit convergence algo

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Implement dirty-limit convergence algo for live migration, which is kind of like auto-converge algo but using dirty-limit instead of cpu throttle to make migration convergent. Enable dirty page limit if dirty_rate_high_cnt greater than 2 when dirty-limit capability enabled,

[PULL 05/25] qapi/migration: Introduce vcpu-dirty-limit parameters

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Introduce "vcpu-dirty-limit" migration parameter used to limit dirty page rate during live migration. "vcpu-dirty-limit" and "x-vcpu-dirty-limit-period" are two dirty-limit-related migration parameters, which can be set before and during live migration by qmp migrate-set-pa

[PULL 08/25] migration: Put the detection logic before auto-converge checking

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) This commit is prepared for the implementation of dirty-limit convergence algo. The detection logic of throttling condition can apply to both auto-converge and dirty-limit algo, putting it's position before the checking logic for auto-converge feature. Signed-off-by: Hyman

[PULL 17/25] migration: Update error description whenever migration fails

2023-07-26 Thread Juan Quintela
From: Tejus GK There are places in migration.c where the migration is marked failed with MIGRATION_STATUS_FAILED, but the failure reason is never updated. Hence libvirt doesn't know why the migration failed when it queries for it. Reviewed-by: Daniel P. Berrangé Signed-off-by: Tejus GK Message

[PULL 11/25] migration-test: Be consistent for ppc

2023-07-26 Thread Juan Quintela
It makes no sense that we don't have the same configuration on both sides. Reviewed-by: Laurent Vivier Message-ID: <20230608224943.3877-2-quint...@redhat.com> Signed-off-by: Juan Quintela --- tests/qtest/migration-test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/

[PULL 03/25] softmmu/dirtylimit: Add parameter check for hmp "set_vcpu_dirty_limit"

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) dirty_rate paraemter of hmp command "set_vcpu_dirty_limit" is invalid if less than 0, so add parameter check for it. Note that this patch also delete the unsolicited help message and clean up the code. Signed-off-by: Hyman Huang(黄勇) Reviewed-by: Markus Armbruster Reviewe

[PULL 02/25] migration/multifd: Protect accesses to migration_threads

2023-07-26 Thread Juan Quintela
From: Fabiano Rosas This doubly linked list is common for all the multifd and migration threads so we need to avoid concurrent access. Add a mutex to protect the data from concurrent access. This fixes a crash when removing two MigrationThread objects from the list at the same time during cleanu

[PULL 15/25] migration: skipped field is really obsolete.

2023-07-26 Thread Juan Quintela
Has return zero for more than 10 years. Specifically we introduced the field in 1.5.0 commit f1c72795af573b24a7da5eb52375c9aba8a37972 Author: Peter Lieven Date: Tue Mar 26 10:58:37 2013 +0100 migration: do not sent zero pages in bulk stage during bulk stage of ram migration if a page

[PULL 21/25] migration: Change qemu_file_transferred to noflush

2023-07-26 Thread Juan Quintela
We do a qemu_fclose() just after that, that also does a qemu_fflush(), so remove one qemu_fflush(). Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20230530183941.7223-3-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/savevm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(

[PULL 20/25] qemu-file: Rename qemu_file_transferred_ fast -> noflush

2023-07-26 Thread Juan Quintela
Fast don't say much. Noflush indicates more clearly that it is like qemu_file_transferred but without the flush. Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20230530183941.7223-2-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/qemu-file.h | 11 +-- migration/qemu-f

[PULL 16/25] docs/migration: Update postcopy bits

2023-07-26 Thread Juan Quintela
From: Peter Xu We have postcopy recovery but not reflected in the document, do an update for that. Add a very small section on postcopy preempt. Touch up the pagemap section, dropping the unsent map because it's already been dropped in the source code in commit 1e7cf8c323 ("migration/postcopy:

[PULL 18/25] migration: enforce multifd and postcopy preempt to be set before incoming

2023-07-26 Thread Juan Quintela
From: Wei Wang qemu_start_incoming_migration needs to check the number of multifd channels or postcopy ram channels to configure the backlog parameter (i.e. the maximum length to which the queue of pending connections for sockfd may grow) of listen(). So enforce the usage of postcopy-preempt and

[PULL 25/25] migration/rdma: Split qemu_fopen_rdma() into input/output functions

2023-07-26 Thread Juan Quintela
This is how everything else in QEMUFile is structured. As a bonus they are three less lines of code. Reviewed-by: Peter Xu Message-ID: <20230530183941.7223-17-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/qemu-file.h | 1 - migration/qemu-file.c | 12 migration/r

[PULL 13/25] migration-test: Create arch_opts

2023-07-26 Thread Juan Quintela
This will contain the options needed for both source and target. Reviewed-by: Peter Xu Message-ID: <20230608224943.3877-6-quint...@redhat.com> Signed-off-by: Juan Quintela --- tests/qtest/migration-test.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) di

[PULL 19/25] qtest/migration-tests.c: use "-incoming defer" for postcopy tests

2023-07-26 Thread Juan Quintela
From: Wei Wang The Postcopy preempt capability is expected to be set before incoming starts, so change the postcopy tests to start with deferred incoming and call migrate-incoming after the cap has been set. Why the existing tests (without this patch) didn't fail? There could be two reasons: 1)

[PULL 07/25] migration: Refactor auto-converge capability logic

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Check if block migration is running before throttling guest down in auto-converge way. Note that this modification is kind of like code clean, because block migration does not depend on auto-converge capability, so the order of checks can be adjusted. Signed-off-by: Hyman

Re: [PULL 1/5] qapi/block-core: Tidy up BlockLatencyHistogramInfo documentation

2023-07-26 Thread Vladimir Sementsov-Ogievskiy
On 26.07.23 15:01, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: On 26.07.23 14:28, Markus Armbruster wrote: Documentation for member @bin comes out like list of io request counts corresponding to histogram intervals. len("bins") = len("boundaries") + 1 For the exa

[PULL v2 2/5] qapi/block: Tidy up block-latency-histogram-set documentation

2023-07-26 Thread Markus Armbruster
Examples come out like Example set new histograms for all io types with intervals [0, 10), [10, 50), [50, 100), [100, +inf): The sentence "set new histograms ..." starts with a lower case letter. Capitalize it. Same for the other examples. Signed-off-by: Markus Armbruster Me

[PULL v2 1/5] qapi/block-core: Tidy up BlockLatencyHistogramInfo documentation

2023-07-26 Thread Markus Armbruster
Documentation for member @bin comes out like list of io request counts corresponding to histogram intervals. len("bins") = len("boundaries") + 1 For the example above, "bins" may be something like [3, 1, 5, 2], and corresponding histogram looks like: Note how the equation and the

Re:Re: [PATCH] Open file as read only on private mapping in qemu_ram_alloc_from_file

2023-07-26 Thread ThinerLogoer
At 2023-07-26 16:11:44, "David Hildenbrand" wrote: > >> though the file never gets written. (the actual memory file & guest state >> file require >> separated hacking) >> >> And at least the patch provided here have been the solution to this last >> problem for me >> for a while. >> >> By the

[PULL 22/25] qemu_file: Make qemu_file_is_writable() static

2023-07-26 Thread Juan Quintela
It is not used outside of qemu_file, and it shouldn't. Signed-off-by: Juan Quintela Message-ID: <20230530183941.7223-19-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/qemu-file.h | 1 - migration/qemu-file.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/

[PULL 24/25] qemu-file: Make qemu_file_get_error_obj() static

2023-07-26 Thread Juan Quintela
It was not used outside of qemu_file.c anyways. Reviewed-by: Peter Xu Message-ID: <20230530183941.7223-21-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/qemu-file.h | 1 - migration/qemu-file.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/migration/qemu

[PULL 23/25] qemu-file: Simplify qemu_file_shutdown()

2023-07-26 Thread Juan Quintela
Reviewed-by: Peter Xu Message-ID: <20230530183941.7223-20-quint...@redhat.com> Signed-off-by: Juan Quintela --- migration/qemu-file.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/migration/qemu-file.c b/migration/qemu-file.c index 9a89e17924..4c577bdff8 100644 --- a/

Re: [Qemu PATCH v2 5/9] hw/mem/cxl_type3: Add host backend and address space handling for DC regions

2023-07-26 Thread Nathan Fontenot
On 7/25/23 13:39, Fan Ni wrote: > From: Fan Ni > > Add (file/memory backed) host backend, all the dynamic capacity regions > will share a single, large enough host backend. Set up address space for > DC regions to support read/write operations to dynamic capacity for DCD. > > With the change, fo

Re: [PATCH] docs/devel: Add cross-compiling doc

2023-07-26 Thread Daniel Henrique Barboza
On 7/26/23 09:07, Andrew Jones wrote: Add instructions for how to cross-compile QEMU for RISC-V. The file is named generically because there's no reason not to collect other architectures steps into the same file, especially because several subsections like those for cross-compiling QEMU depen

[PULL 04/25] qapi/migration: Introduce x-vcpu-dirty-limit-period parameter

2023-07-26 Thread Juan Quintela
From: Hyman Huang(黄勇) Introduce "x-vcpu-dirty-limit-period" migration experimental parameter, which is in the range of 1 to 1000ms and used to make dirtyrate calculation period configurable. Currently with the "x-vcpu-dirty-limit-period" varies, the total time of live migration changes, test res

Re: How to tame CI?

2023-07-26 Thread Peter Maydell
On Wed, 26 Jul 2023 at 13:06, Juan Quintela wrote: > To make things easier, this is the part that show how it breaks (this is > the gcov test): > > 357/423 qemu:block / io-qcow2-copy-before-write > ERROR 6.38s exit status 1 > >>> PYTHON=/builds/juan.quintela

[PATCH 09/44] Add GPIO and SD to BCM2838 periph

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2838_peripherals.c | 140 +++ include/hw/arm/bcm2838_peripherals.h | 9 ++ 2 files changed, 149 insertions(+) diff --git a/hw/arm/bcm2838_peripherals.c b/hw/arm/bcm2838_peripherals.c index 864941c231..0c5e716853 10064

[PATCH 13/44] Add memory region for BCM2837 RPiVid ASB

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2838_peripherals.c | 3 +++ include/hw/arm/bcm2838_peripherals.h | 3 ++- include/hw/arm/raspi_platform.h | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/hw/arm/bcm2838_peripherals.c b/hw/arm/bcm2838_peripherals.c inde

[PATCH 04/44] Introduce BCM2838 SoC

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2838.c | 110 +++ hw/arm/bcm2838_peripherals.c | 72 ++ hw/arm/meson.build | 2 + include/hw/arm/bcm2838.h | 26 +++ include/hw/arm/bcm2838_periph

[PATCH 41/44] Add mailbox property tests. Part 2

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- tests/qtest/bcm2838-mbox-property-test.c | 196 ++- 1 file changed, 195 insertions(+), 1 deletion(-) diff --git a/tests/qtest/bcm2838-mbox-property-test.c b/tests/qtest/bcm2838-mbox-property-test.c index ac173ed3ff..bcee9971c6 100644 --- a/

[PATCH 17/44] Add RNG200 skeleton

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/misc/bcm2838_rng200.c | 118 +++ hw/misc/meson.build | 1 + hw/misc/trace-events | 10 +++ include/hw/misc/bcm2838_rng200.h | 77 4 files changed, 206 insertions(+) create

[PATCH 39/44] Add mailbox tests tags. Part 3

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- tests/qtest/bcm2838-mailbox.h | 78 +++ 1 file changed, 78 insertions(+) diff --git a/tests/qtest/bcm2838-mailbox.h b/tests/qtest/bcm2838-mailbox.h index 2231c2c596..d8975b11ea 100644 --- a/tests/qtest/bcm2838-mailbox.h +++ b/tes

[PATCH 23/44] Add GENET register structs. Part 1

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- include/hw/net/bcm2838_genet.h | 125 - 1 file changed, 124 insertions(+), 1 deletion(-) diff --git a/include/hw/net/bcm2838_genet.h b/include/hw/net/bcm2838_genet.h index f62b24fa2f..89b45eb39f 100644 --- a/include/hw/net/bcm283

[PATCH 02/44] Split out common part of peripherals

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2835_peripherals.c | 198 +++ hw/arm/bcm2836.c | 24 ++-- include/hw/arm/bcm2835_peripherals.h | 29 +++- include/hw/arm/bcm2836.h | 3 +- 4 files changed, 154 insertions(+), 100 delet

[PATCH 10/44] Add BCM2838 checkpoint support

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/gpio/bcm2838_gpio.c | 17 + 1 file changed, 17 insertions(+) diff --git a/hw/gpio/bcm2838_gpio.c b/hw/gpio/bcm2838_gpio.c index 7291e473dc..f1121f9c58 100644 --- a/hw/gpio/bcm2838_gpio.c +++ b/hw/gpio/bcm2838_gpio.c @@ -17,6 +17,7 @@ #includ

[PATCH 03/44] Split out raspi machine common part

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/raspi.c | 112 ++-- include/hw/arm/raspi_platform.h | 21 ++ 2 files changed, 85 insertions(+), 48 deletions(-) diff --git a/hw/arm/raspi.c b/hw/arm/raspi.c index af866ebce2..7d04734cd2 100644 --- a/hw/ar

[PATCH 35/44] Add mailbox test stub

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- tests/qtest/bcm2838-mailbox.c | 70 +++ tests/qtest/bcm2838-mailbox.h | 48 tests/qtest/meson.build | 1 + 3 files changed, 119 insertions(+) create mode 100644 tests/qtest/bcm2838-mailbox.c creat

[PATCH 14/44] Add BCM2838 PCIE Root Complex

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2838_pcie.c | 65 +++ hw/arm/meson.build| 5 ++- hw/arm/trace-events | 4 +++ include/hw/arm/bcm2838_pcie.h | 44 4 files changed, 117 insertions(+), 1 deletion(-)

[PULL v2 4/5] qapi/trace: Tidy up trace-event-get-state, -set-state documentation

2023-07-26 Thread Markus Armbruster
trace-event-set-state's explanation of how events are selected is under "Features". Doesn't belong there. Simply delete it, as it feels redundant with documentation of member @name. trace-event-get-state's explanation is under "Returns". Tolerable, but similarly redundant. Delete it, too. Cc:

[PULL v2 0/5] QAPI patches patches for 2023-07-26

2023-07-26 Thread Markus Armbruster
The following changes since commit 6cb2011fedf8c4e7b66b4a3abd6b42c1bae99ce6: Update version for v8.1.0-rc1 release (2023-07-25 20:09:05 +0100) are available in the Git repository at: https://repo.or.cz/qemu/armbru.git tags/pull-qapi-2023-07-26-v2 for you to fetch changes up to 9e272073e1c41

[PATCH 07/44] Implement BCM2838 GPIO functionality

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/gpio/bcm2838_gpio.c | 197 - 1 file changed, 193 insertions(+), 4 deletions(-) diff --git a/hw/gpio/bcm2838_gpio.c b/hw/gpio/bcm2838_gpio.c index 59be608250..cc9f4f74a0 100644 --- a/hw/gpio/bcm2838_gpio.c +++ b/hw/gpio

[PATCH 21/44] Add clock_isp stub

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2838_peripherals.c | 6 ++ include/hw/arm/bcm2838_peripherals.h | 1 + 2 files changed, 7 insertions(+) diff --git a/hw/arm/bcm2838_peripherals.c b/hw/arm/bcm2838_peripherals.c index e7a9db97ab..60ed535673 100644 --- a/hw/arm/bcm2838_perip

  1   2   3   >