Re: [PATCH v4 7/8] STM32L4x5: Use the RCC Sysclk

2024-01-31 Thread Alistair Francis
On Wed, Jan 31, 2024 at 3:21 AM Arnaud Minier wrote: > > Now that we can generate reliable clock frequencies from the RCC, remove > the hacky definition of the sysclk in the b_l475e_iot01a initialisation > code and use the correct RCC clock. > > Signed-off-by: Arnaud Minier > Signed-off-by: Inès

Re: [PATCH v5 3/6] target/riscv: Add helper functions to calculate current number of masked bits for pointer masking

2024-01-31 Thread Alistair Francis
On Tue, Jan 30, 2024 at 5:24 AM Alexey Baturo wrote: > > From: Alexey Baturo > > Signed-off-by: Alexey Baturo Reviewed-by: Alistair Francis Alistair > --- > target/riscv/cpu.h| 4 +++ > target/riscv/cpu_helper.c | 58 +++ > 2 files changed, 62 in

Re: [PATCH v5 6/6] target/riscv: Enable updates for pointer masking variables and thus enable pointer masking extension

2024-01-31 Thread Alistair Francis
On Tue, Jan 30, 2024 at 5:24 AM Alexey Baturo wrote: > > From: Alexey Baturo > > Signed-off-by: Alexey Baturo Reviewed-by: Alistair Francis Alistair > --- > target/riscv/cpu.c | 9 + > 1 file changed, 9 insertions(+) > > diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c > index d

Re: [External] Re: [PATCH 0/5] migration/multifd: Prerequisite cleanups for ongoing work

2024-01-31 Thread Hao Xiang
On Wed, Jan 31, 2024 at 5:19 AM Fabiano Rosas wrote: > > Peter Xu writes: > > > On Mon, Jan 29, 2024 at 09:51:06AM -0300, Fabiano Rosas wrote: > >> Peter Xu writes: > >> > >> > On Mon, Jan 29, 2024 at 01:41:01AM +, Liu, Yuan1 wrote: > >> >> Because this change has an impact on the previous l

Re: [PATCH] tcg: Fixes set const_args[i] wrong value when instructions imm is 0

2024-01-31 Thread gaosong
在 2024/2/1 上午5:16, Richard Henderson 写道: On 1/31/24 17:27, Song Gao wrote: It seems that tcg_reg_alloc_op() set const_args[i] wrong value when instructions imm is 0. The LoongArch tcg_out_vec_op() cmp_vec use the wrong const_args[2]. e.g     The wrong const_args[2] is 0.     IN: vslti.w v5, v4,

答复: Disk migration from qcow2 to SPDK

2024-01-31 Thread 陈孚
can someone help me ? 发件人: 陈孚 发送时间: 2024年1月30日 10:51 收件人: 'qemu-bl...@nongnu.org' 抄送: 'qemu-devel@nongnu.org' 主题: Disk migration from qcow2 to SPDK Hello everyone, Recently, we are looking to switch the VM’s disks from the qemu driver with the qcow2 format to a vhost-user-blk driver based on

Re: [PATCH v5 0/6] Pointer Masking update for Zjpm v0.8

2024-01-31 Thread Alistair Francis
On Tue, Jan 30, 2024 at 5:23 AM Alexey Baturo wrote: > > From: Alexey Baturo > > Hi, > > This patch series targets Zjpm v0.8 extension. > The spec itself could be found here: > https://github.com/riscv/riscv-j-extension/blob/8088461d8d66a7676872b61c908cbeb7cf5c5d1d/zjpm-spec.pdf > This patch ser

Re: [PATCH v8 00/21] Introduce smp.modules for x86 in QEMU

2024-01-31 Thread Zhao Liu
Hi Daniel, On Wed, Jan 31, 2024 at 10:28:42AM +, Daniel P. Berrangé wrote: > Date: Wed, 31 Jan 2024 10:28:42 + > From: "Daniel P. Berrangé" > Subject: Re: [PATCH v8 00/21] Introduce smp.modules for x86 in QEMU > > On Wed, Jan 31, 2024 at 06:13:29PM +0800, Zhao Liu wrote: > > From: Zhao L

Re: [PULL 06/15] tests/qtest/migration: Don't use -cpu max for aarch64

2024-01-31 Thread Peter Xu
On Wed, Jan 31, 2024 at 10:09:16AM -0300, Fabiano Rosas wrote: > If we ask for KVM and it falls back to TCG, we need a cpu that supports > both. We don't have that. I've put some command-line combinations at the > end of the email[1], take a look. Thanks a lot, Fabiano. I think I have a better pi

Re: [PATCH] hw/intc: Handle the error of IOAPICCommonClass.realize()

2024-01-31 Thread Zhao Liu
Hi Philippe, On Wed, Jan 31, 2024 at 05:48:24PM +0100, Philippe Mathieu-Daudé wrote: > Date: Wed, 31 Jan 2024 17:48:24 +0100 > From: Philippe Mathieu-Daudé > Subject: Re: [PATCH] hw/intc: Handle the error of > IOAPICCommonClass.realize() > > Hi Zhao, > > On 31/1/24 15:29, Zhao Liu wrote: > > F

Re: [PATCH 1/5] migration/multifd: Separate compression ops from non-compression

2024-01-31 Thread Peter Xu
On Wed, Jan 31, 2024 at 10:14:58AM -0300, Fabiano Rosas wrote: > > I am thinking the p->normal is mostly redundant.. at least on the sender > > side that I just read. Since I'll be preparing a new spin of the multifd > > cleanup series I posted, maybe I can append one more to try dropping > > p->n

Re: [External] Re: [PATCH v3 01/20] multifd: Add capability to enable/disable zero_page

2024-01-31 Thread Peter Xu
On Tue, Jan 23, 2024 at 12:10:55PM -0300, Fabiano Rosas wrote: > Hao Xiang writes: > > > On Sun, Jan 14, 2024 at 10:02 PM Shivam Kumar > > wrote: > >> > >> > >> > >> > On 04-Jan-2024, at 6:14 AM, Hao Xiang wrote: > >> > > >> > From: Juan Quintela > >> > > >> > We have to enable it by default

Re: [PATCH v3 03/20] multifd: Zero pages transmission

2024-01-31 Thread Peter Xu
On Thu, Jan 04, 2024 at 12:44:35AM +, Hao Xiang wrote: > From: Juan Quintela > > This implements the zero page dection and handling. > > Signed-off-by: Juan Quintela > --- > migration/multifd.c | 41 +++-- > migration/multifd.h | 5 + > 2 files chan

Re: [PATCH v3 15/20] migration/multifd: Add test hook to set normal page ratio.

2024-01-31 Thread Peter Xu
On Thu, Jan 04, 2024 at 12:44:47AM +, Hao Xiang wrote: > +# @multifd-normal-page-ratio: Test hook setting the normal page ratio. > +# (Since 8.2) Please remember to touch all of them to 9.0 when repost, thanks. -- Peter Xu

Re: [PATCH v2 02/14] plugins: scoreboard API

2024-01-31 Thread Pierrick Bouvier
On 1/31/24 11:44, Pierrick Bouvier wrote: On 1/26/24 19:14, Alex Bennée wrote: +need_realloc = TRUE; +} +plugin.scoreboard_size = cpu->cpu_index + 1; +g_assert(plugin.scoreboard_size <= plugin.scoreboard_alloc_size); + +if (g_hash_table_size(plugin.scoreboards) == 0) { +

Re: [PATCH v3 06/20] util/dsa: Add dependency idxd.

2024-01-31 Thread Peter Xu
On Thu, Jan 04, 2024 at 12:44:38AM +, Hao Xiang wrote: > Idxd is the device driver for DSA (Intel Data Streaming > Accelerator). The driver is fully functioning since Linux > kernel 5.19. This change adds the driver's header file used > for userspace development. > > Signed-off-by: Hao Xiang

Re: [PATCH 0/2] Move net backend cleanup to NIC cleanup

2024-01-31 Thread Jason Wang
On Mon, Jan 29, 2024 at 9:24 PM Eugenio Pérez wrote: > > Commit a0d7215e33 ("vhost-vdpa: do not cleanup the vdpa/vhost-net > structures if peer nic is present") effectively delayed the backend > cleanup, allowing the frontend or the guest to access it resources as > long as the frontend NIC is sti

Re: [PATCH v2 1/2] igb: fix link state on resume

2024-01-31 Thread Jason Wang
On Wed, Jan 24, 2024 at 6:30 PM Laurent Vivier wrote: > > On resume igb_vm_state_change() always calls igb_autoneg_resume() > that sets link_down to false, and thus activates the link even > if we have disabled it. > > The problem can be reproduced starting qemu in paused state (-S) and > then set

Re: [PATCH v2 2/2] e1000e: fix link state on resume

2024-01-31 Thread Jason Wang
On Wed, Jan 24, 2024 at 6:40 PM Laurent Vivier wrote: > > On resume e1000e_vm_state_change() always calls e1000e_autoneg_resume() > that sets link_down to false, and thus activates the link even > if we have disabled it. > > The problem can be reproduced starting qemu in paused state (-S) and > th

Re: [PATCH 00/14] migration/multifd: Refactor ->send_prepare() and cleanups

2024-01-31 Thread Peter Xu
On Wed, Jan 31, 2024 at 07:49:51PM -0300, Fabiano Rosas wrote: > pet...@redhat.com writes: > > > From: Peter Xu > > > > This patchset contains quite a few refactorings to current multifd: > > > > - It picked up some patches from an old series of mine [0] (the last > > patches were dropped,

Re: [PATCH 14/14] migration/multifd: Forbid spurious wakeups

2024-01-31 Thread Peter Xu
On Wed, Jan 31, 2024 at 06:31:11PM +0800, pet...@redhat.com wrote: > From: Peter Xu > > Now multifd's logic is designed to have no spurious wakeup. I still > remember a talk to Juan and he seems to agree we should drop it now, and if > my memory was right it was there because multifd used to hit

Re: [PATCH v3 2/4] tests/tcg/s390x: Test CONVERT TO DECIMAL

2024-01-31 Thread Thomas Huth
On 01/02/2024 00.07, Ilya Leoshkevich wrote: Check the CVD's and CVDG's corner cases. Signed-off-by: Ilya Leoshkevich --- tests/tcg/s390x/Makefile.target | 1 + tests/tcg/s390x/cvd.c | 45 + 2 files changed, 46 insertions(+) create mode 100644 te

Re: [PATCH v3 4/4] tests/tcg/s390x: Test CONVERT TO BINARY

2024-01-31 Thread Thomas Huth
On 01/02/2024 00.07, Ilya Leoshkevich wrote: Check the CVB's and CVBG's corner cases. Co-developed-by: Pavel Zbitskiy Signed-off-by: Ilya Leoshkevich --- tests/tcg/s390x/Makefile.target | 1 + tests/tcg/s390x/cvb.c | 47 + 2 files changed, 48 inse

Re: [PATCH 1/3] ui/gtk: skip drawing guest scanout when associated VC is invisible

2024-01-31 Thread Marc-André Lureau
Hi On Wed, Jan 31, 2024 at 10:56 PM Kim, Dongwon wrote: > > Hi Marc-André, > > > https://docs.gtk.org/gtk3/method.Widget.is_visible.html > > This is what we had tried first but it didn't seem to work for the case of > window minimization. > I see the visible flag for the GTK widget didn't seem t

Re: [PATCH v3 3/4] target/s390x: implement CVB, CVBY and CVBG

2024-01-31 Thread Thomas Huth
On 01/02/2024 00.07, Ilya Leoshkevich wrote: From: Pavel Zbitskiy Convert to Binary - counterparts of the already implemented Convert to Decimal (CVD*) instructions. Example from the Principles of Operation: 25594C becomes 63FA. [iii: Use separate functions for CVB and CVBG for simplicity]. S

Re: [PATCH v3 4/4] tests/tcg/s390x: Test CONVERT TO BINARY

2024-01-31 Thread Thomas Huth
On 01/02/2024 00.07, Ilya Leoshkevich wrote: Check the CVB's and CVBG's corner cases. Co-developed-by: Pavel Zbitskiy Signed-off-by: Ilya Leoshkevich --- tests/tcg/s390x/Makefile.target | 1 + tests/tcg/s390x/cvb.c | 47 + 2 files changed, 48 inse

Re: [PULL 13/17] hw/fsi: Aspeed APB2OPB & On-chip peripheral bus

2024-01-31 Thread Cédric Le Goater
Here is an update version with a fix. I will include it in the next PR. Thanks, C. From: Ninad Palsule This is a part of patchset where IBM's Flexible Service Interface is introduced. An APB-to-OPB bridge enabling access to the OPB from the ARM core in the AST2600. Hardware limitations pr

[PATCH rfcv2 04/18] vfio: Add host iommu device instance into VFIODevice

2024-01-31 Thread Zhenzhong Duan
Either IOMMULegacyDevice or IOMMUFDDevice into VFIODevice, neither both. Signed-off-by: Zhenzhong Duan --- include/hw/vfio/vfio-common.h | 11 +++ 1 file changed, 11 insertions(+) diff --git a/include/hw/vfio/vfio-common.h b/include/hw/vfio/vfio-common.h index 8bfb9cbe94..1bbad003ee 100

[PATCH rfcv2 02/18] backends/iommufd: Introduce IOMMUFDDevice

2024-01-31 Thread Zhenzhong Duan
IOMMUFDDevice represents a device in iommufd and can be used as a communication interface between devices (i.e., VFIO, VDPA) and vIOMMU. Currently it includes only public iommufd handle and device id which could be used by vIOMMU to get hw IOMMU information. There will also be some elements in pr

[PATCH rfcv2 06/18] vfio: Introduce host_iommu_device_init callback

2024-01-31 Thread Zhenzhong Duan
Introduce host_iommu_device_init callback and a wrapper for it. Signed-off-by: Zhenzhong Duan --- include/hw/vfio/vfio-common.h | 1 + include/hw/vfio/vfio-container-base.h | 1 + hw/vfio/common.c | 8 3 files changed, 10 insertions(+) diff --git a/include/

[PATCH rfcv2 08/18] vfio/iommufd: Implement host_iommu_device_init callback in iommufd mode

2024-01-31 Thread Zhenzhong Duan
This callback will be used to initialize base and public elements in IOMMUFDDevice, with the exception of iommufd and devid which are initialized early in attachment. Signed-off-by: Zhenzhong Duan --- hw/vfio/iommufd.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/vfio/iommufd.c b

[PATCH rfcv2 09/18] vfio/pci: Initialize host iommu device instance after attachment

2024-01-31 Thread Zhenzhong Duan
Signed-off-by: Zhenzhong Duan --- hw/vfio/pci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/vfio/pci.c b/hw/vfio/pci.c index d1e1b8cb89..dedb64fc08 100644 --- a/hw/vfio/pci.c +++ b/hw/vfio/pci.c @@ -3006,6 +3006,9 @@ static void vfio_realize(PCIDevice *pdev, Error **errp) g

[PATCH rfcv2 12/18] vfio: Initialize host IOMMU device and pass to vIOMMU

2024-01-31 Thread Zhenzhong Duan
Initialize host IOMMU device in vfio and pass to vIOMMU, so that vIOMMU could get hw IOMMU information. Support both iommufd and legacy backend. Originally-by: Yi Liu Signed-off-by: Nicolin Chen Signed-off-by: Yi Sun Signed-off-by: Zhenzhong Duan --- hw/vfio/pci.c | 20 +++-

[PATCH rfcv2 00/18] Check and sync host IOMMU cap/ecap with vIOMMU

2024-01-31 Thread Zhenzhong Duan
Hi, This enables vIOMMU to get host IOMMU cap/ecap information by introducing a new set/unset_iommu_device interface, then vIOMMU could check or sync with vIOMMU's own cap/ecap config. It works by having device side, i.e. VFIO, register either an IOMMULegacyDevice or IOMMUFDDevice to vIOMMU, whic

[PATCH rfcv2 15/18] backends/iommufd: Introduce helper function iommufd_device_get_info()

2024-01-31 Thread Zhenzhong Duan
Introduce a helper function iommufd_device_get_info() to get host IOMMU related information through iommufd uAPI. Signed-off-by: Yi Liu Signed-off-by: Yi Sun Signed-off-by: Zhenzhong Duan --- include/sysemu/iommufd.h | 4 backends/iommufd.c | 25 - 2 files c

[PATCH rfcv2 07/18] vfio/container: Implement host_iommu_device_init callback in legacy mode

2024-01-31 Thread Zhenzhong Duan
This callback will be used to initialize base and public elements in IOMMULegacyDevice. Signed-off-by: Zhenzhong Duan --- hw/vfio/container.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/vfio/container.c b/hw/vfio/container.c index bd25b9fbad..8fafd4b4e5 100644 --- a/hw/vfio/con

[PATCH rfcv2 17/18] intel_iommu: Use mgaw instead of s->aw_bits

2024-01-31 Thread Zhenzhong Duan
Because vIOMMU mgaw can be updated based on host IOMMU mgaw, s->aw_bits does't necessarily represent the final mgaw now but the mgaw field in s->cap does. Replace reference to s->aw_bits with a MACRO S_AW_BITS to fetch mgaw from s->cap. There are two exceptions on this, aw_bits value sanity check

[PATCH rfcv2 03/18] vfio: Introduce IOMMULegacyDevice

2024-01-31 Thread Zhenzhong Duan
Similar as IOMMUFDDevice, IOMMULegacyDevice represents a device in legacy mode and can be used as a communication interface between devices (i.e., VFIO, VDPA) and vIOMMU. Currently it includes nothing legacy specific, but could be extended with any wanted info of legacy mode when necessary. IOMMU

[PATCH rfcv2 14/18] intel_iommu: Add a framework to check and sync host IOMMU cap/ecap

2024-01-31 Thread Zhenzhong Duan
From: Yi Liu Add a framework to check and synchronize host IOMMU cap/ecap with vIOMMU cap/ecap. The sequence will be: vtd_cap_init() initializes iommu->cap/ecap. vtd_check_hdev() update iommu->cap/ecap based on host cap/ecap. iommu->cap_frozen set when machine create done, iommu->cap/ecap becom

[PATCH rfcv2 10/18] hw/pci: Introduce pci_device_set/unset_iommu_device()

2024-01-31 Thread Zhenzhong Duan
From: Yi Liu This adds pci_device_set/unset_iommu_device() to set/unset HostIOMMUDevice for a given PCIe device. Caller of set should fail if set operation fails. Extract out pci_device_get_iommu_bus_devfn() to facilitate implementation of pci_device_set/unset_iommu_device(). Signed-off-by: Yi

[PATCH rfcv2 05/18] vfio: Remove redundant iommufd and devid elements in VFIODevice

2024-01-31 Thread Zhenzhong Duan
iommufd and devid in VFIODevice are redundant with the ones in IOMMUFDDevice, so remove them. Suggested-by: Eric Auger Signed-off-by: Zhenzhong Duan --- include/hw/vfio/vfio-common.h | 2 -- hw/vfio/ap.c | 2 +- hw/vfio/ccw.c | 2 +- hw/vfio/common.c

[PATCH rfcv2 01/18] Introduce a common abstract struct HostIOMMUDevice

2024-01-31 Thread Zhenzhong Duan
HostIOMMUDevice will be inherited by two sub classes, legacy and iommufd currently. Introduce a helper function host_iommu_base_device_init to initialize it. Suggested-by: Eric Auger Signed-off-by: Zhenzhong Duan --- include/sysemu/host_iommu_device.h | 22 ++ 1 file change

[PATCH rfcv2 18/18] intel_iommu: Block migration if cap is updated

2024-01-31 Thread Zhenzhong Duan
When there is VFIO device and vIOMMU cap/ecap is updated based on host IOMMU cap/ecap, migration should be blocked. Signed-off-by: Zhenzhong Duan --- hw/i386/intel_iommu.c | 16 ++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_

[PATCH rfcv2 16/18] intel_iommu: Implement check and sync mechanism in iommufd mode

2024-01-31 Thread Zhenzhong Duan
We use cap_frozen to mark cap/ecap read/writable or read-only, At init stage, we allow to update cap/ecap based on host IOMMU cap/ecap, but when machine create done, cap_frozen is set and we only allow checking cap/ecap for compatibility. Currently only stage-2 translation is supported which is ba

[PATCH rfcv2 11/18] intel_iommu: Add set/unset_iommu_device callback

2024-01-31 Thread Zhenzhong Duan
From: Yi Liu This adds set/unset_iommu_device() implementation in Intel vIOMMU. In set call, a pointer to host IOMMU device info is stored in hash table indexed by PCI BDF. Signed-off-by: Yi Liu Signed-off-by: Yi Sun Signed-off-by: Zhenzhong Duan --- hw/i386/intel_iommu_internal.h | 14 +

[PATCH rfcv2 13/18] intel_iommu: Extract out vtd_cap_init to initialize cap/ecap

2024-01-31 Thread Zhenzhong Duan
This is a prerequisite for host cap/ecap sync. No functional change intended. Reviewed-by: Eric Auger Signed-off-by: Zhenzhong Duan --- hw/i386/intel_iommu.c | 93 --- 1 file changed, 51 insertions(+), 42 deletions(-) diff --git a/hw/i386/intel_iommu.c

[PULL 0/1] loongarch-to-apply queue

2024-01-31 Thread Song Gao
The following changes since commit bd2e12310b18b51aefbf834e6d54989fd175976f: Merge tag 'qga-pull-2024-01-30' of https://github.com/kostyanf14/qemu into staging (2024-01-30 15:53:46 +) are available in the Git repository at: https://gitlab.com/gaosong/qemu.git tags/pull-loongarch-2024020

[PULL 1/1] target/loongarch: Fix qtest test-hmp error when KVM-only build

2024-01-31 Thread Song Gao
The cc->sysemu_ops->get_phys_page_debug() is NULL when KVM-only build. this patch fixes it. Signed-off-by: Song Gao Tested-by: Bibo Mao Message-Id: <20240125061401.52526-1-gaos...@loongson.cn> --- target/loongarch/cpu.c| 2 - target/loongarch/cpu_helper.c | 231 +++

Re: Dynamic & heterogeneous machines, initial configuration: problems

2024-01-31 Thread Zhao Liu
Hi Markus, On Wed, Jan 31, 2024 at 09:14:21PM +0100, Markus Armbruster wrote: > Date: Wed, 31 Jan 2024 21:14:21 +0100 > From: Markus Armbruster > Subject: Dynamic & heterogeneous machines, initial configuration: problems > > This memo is the fruit of discussions with Philippe Mathieu-Daudé. > It

<    1   2   3