[PATCH 2/4] target/ppc: Add support for SMT CTRL register

2023-06-05 Thread Nicholas Piggin
A relatively simple case to begin with, CTRL is a SMT shared register where reads and writes need to synchronise against state changes by other threads in the core. Atomic serialisation operations are used to achieve this. Signed-off-by: Nicholas Piggin --- target/ppc/helper.h | 2 ++ tar

[PATCH 1/4] target/ppc: Add initial flags and helpers for SMT support

2023-06-05 Thread Nicholas Piggin
SMT TCG emulation needs to be able to iterate over siblings in a core, and needs to serialise core access to shared SPRs and state. Signed-off-by: Nicholas Piggin --- target/ppc/cpu.h | 9 + target/ppc/cpu_init.c | 5 + target/ppc/translate.c | 20 3 fil

[PATCH 0/4] target/ppc: TCG SMT support for spapr

2023-06-05 Thread Nicholas Piggin
Previous RFC here https://lists.gnu.org/archive/html/qemu-ppc/2023-05/msg00453.html This series drops patch 1 from the previous, which is more of a standalone bugfix. Also accounted for Cedric's comments, except a nicer way to set cpu_index vs PIR/TIR SPRs, which is not quite trivial. This limi

Re: [PATCH v3 1/1] hw/arm/sbsa-ref: use XHCI to replace EHCI

2023-06-05 Thread Yuquan Wang
Hi, Marcin On Mon, 5 Jun 2023 11:59:16 +0200, Marcin Juszkiewicz wrote: > > W dniu 5.06.2023 o 11:55, Yuquan Wang pisze: > > The current sbsa-ref cannot use EHCI controller which is only > > able to do 32-bit DMA, since sbsa-ref doesn't have RAM below 4GB. > > Hence, this uses XHCI to provide a

Re: [PATCH v2] target/riscv: Smepmp: Return error when access permission not allowed in PMP

2023-06-05 Thread Weiwei Li
On 2023/6/5 19:49, Himanshu Chauhan wrote: On an address match, skip checking for default permissions and return error based on access defined in PMP configuration. v2 Changes: o Removed goto to return in place when address matches o Call pmp_hart_has_privs_default at the end of the loop Fixe

Re: [PATCH 1/2] migration: switchover-hold parameter

2023-06-05 Thread Avihai Horon
Hi Peter, On 02/06/2023 17:47, Peter Xu wrote: External email: Use caution opening links or attachments Add a new migration parameter switchover-hold which can block src qemu migration from switching over to dest from running. One can set this flag to true so src qemu will keep iterating the

Re: [PATCH v3 05/23] q800: move CPU object into Q800MachineState

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: Also change the instantiation of the CPU to use object_initialize_child() followed by a separate realisation. Signed-off-by: Mark Cave-Ayland --- hw/m68k/q800.c | 18 +- include/hw/m68k/q800.h | 3 +++ 2 files changed, 16 ins

Re: [PATCH v3 07/23] q800: move GLUE device into separate q800-glue.c file

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: This will allow the q800-glue.h header to be included separately so that the GLUE device can be referenced externally. Signed-off-by: Mark Cave-Ayland Reviewed-by: Laurent Vivier --- MAINTAINERS | 2 + hw/m68k/meson.build |

Re: [PATCH v3 10/23] q800: reimplement mac-io region aliasing using IO memory region

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: The current use of aliased memory regions causes us 2 problems: firstly the output of "info qom-tree" is absolutely huge and difficult to read, and secondly we have already reached the internal limit for memory regions as adding any new memory region into

Re: [PATCH v3 13/23] hw/net/dp8393x.c: move TYPE_DP8393X and dp8393xState into dp8393x.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: This is to enable them to be used outside of dp8393x.c. Signed-off-by: Mark Cave-Ayland CC: Jason Wang Reviewed-by: Laurent Vivier --- hw/net/dp8393x.c | 32 + include/hw/net/dp8393x.h | 60 +++

Re: [PATCH v3 20/23] q800: don't access Nubus bus directly from the mac-nubus-bridge device

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: Instead use the qdev_get_child_bus() function which is intended for this exact purpose. Signed-off-by: Mark Cave-Ayland Reviewed-by: Laurent Vivier --- hw/m68k/q800.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Philippe Mathi

Re: vmovqdu/vmovqda inline asm doesn't compile on macos catalina

2023-06-05 Thread Peter Maydell
On Mon, 5 Jun 2023 at 12:29, Daniel P. Berrangé wrote: > > On Mon, Jun 05, 2023 at 11:55:43AM +0100, Peter Maydell wrote: > > I just noticed that the recent atomicity changes introduce a build > > failure on x86 macos (Catalina). Now if we wanted to, we can say "this > > is too old and outside our

Re: [PATCH v3 19/23] q800: move mac-nubus-bridge device to Q800MachineState

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: Also change the instantiation of the mac-nubus-bridge device to use object_initialize_child() and map the Nubus address space using memory_region_add_subregion() instead of sysbus_mmio_map(). Signed-off-by: Mark Cave-Ayland --- hw/m68k/q800.c |

Re: [PATCH v3 10/23] q800: reimplement mac-io region aliasing using IO memory region

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: The current use of aliased memory regions causes us 2 problems: firstly the output of "info qom-tree" is absolutely huge and difficult to read, and secondly we have already reached the internal limit for memory regions as adding any new memory region into

Re: [PATCH v3 09/23] q800: introduce mac-io container memory region

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 15:14, Mark Cave-Ayland wrote: Move all devices from the IO region to within the container in preparation for updating the IO aliasing mechanism. Signed-off-by: Mark Cave-Ayland Reviewed-by: Laurent Vivier --- hw/m68k/q800.c | 6 ++ include/hw/m68k/q800.h | 1 + 2 fil

Re: [PATCH 04/15] linux-user: Use abi_int not int32_t in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 60 +++ 1 file changed, 30 insertions(+), 30 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 05/15] linux-user: Use abi_ullong not uint64_t in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Be careful not to change linux_dirent64, which is a host structure. Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 72 +++ 1 file changed, 36 insertions(+), 36 deletions(-) Reviewed-by: Philippe

Re: [PATCH 06/15] linux-user: Use abi_llong not int64_t in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Be careful not to change linux_dirent64, which is a host structure. Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) Reviewed-by: Philippe Mathieu-

Re: [PATCH 09/15] linux-user: Use abi_llong not long long in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 08/15] linux-user: Use abi_ullong not unsigned long long in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 32 1 file changed, 16 insertions(+), 16 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 11/15] linux-user: Use abi_ushort not unsigned short in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 90 +++ 1 file changed, 45 insertions(+), 45 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 12/15] linux-user: Use abi_short not short in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 13/15] linux-user: Use abi_uint not unsigned in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 02/15] linux-user: Remove #if 0 block in syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: These definitions are in sparc/signal.c. Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 24 1 file changed, 24 deletions(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 01/15] linux-user: Reformat syscall_defs.h

2023-06-05 Thread Philippe Mathieu-Daudé
On 4/6/23 00:23, Richard Henderson wrote: Untabify and re-indent. We had a mix of 2, 3, 4, and 8 space indentation. Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 1948 ++--- 1 file changed, 974 insertions(+), 974 deletions(-) 'git-diff --i

Re: [PATCH v5 2/5] parallels: Split image leak handling to separate check and fix helpers

2023-06-05 Thread Alexander Ivanov
On 6/2/23 16:08, Hanna Czenczek wrote: On 29.05.23 17:15, Alexander Ivanov wrote: We need to fix leak after deduplication in the next patch. Move leak fixing to a separate helper parallels_fix_leak() and add parallels_get_leak_size() helper wich used in parallels_fix_leak() and parallels_chec

Re: [PULL 07/21] cutils: Fix wraparound parsing in qemu_strtoui

2023-06-05 Thread Eric Blake
On Sat, Jun 03, 2023 at 11:17:27AM +0300, Michael Tokarev wrote: > 02.06.2023 01:02, Eric Blake пишет: > > While we were matching 32-bit strtol in qemu_strtoi, our use of a > > 64-bit parse was leaking through for some inaccurate answers in > > qemu_strtoui in comparison to a 32-bit strtoul (see th

Re: [PULL 31/35] hw/intc/allwinner-a10-pic: Don't use set_bit()/clear_bit()

2023-06-05 Thread Guenter Roeck
On 6/5/23 02:40, Peter Maydell wrote: On Sat, 3 Jun 2023 at 19:06, Guenter Roeck wrote: On 6/3/23 10:46, Michael Tokarev wrote: 03.06.2023 18:03, Guenter Roeck wrote: Hi, On Tue, May 02, 2023 at 01:14:55PM +0100, Peter Maydell wrote: The Allwinner PIC model uses set_bit() and clear_bit() t

Re: [PATCH 7/7] target/ppc: Eliminate goto in mmubooke_check_tlb()

2023-06-05 Thread Daniel Henrique Barboza
On 5/30/23 10:28, BALATON Zoltan wrote: Move out checking PID registers into a separate function which makes mmubooke_check_tlb() simpler and avoids using goto. Signed-off-by: BALATON Zoltan --- Reviewed-by: Daniel Henrique Barboza target/ppc/mmu_common.c | 40 +---

Re: [PATCH 0/7] Embedded PPC misc clean up and optimisation

2023-06-05 Thread Daniel Henrique Barboza
Queued in gitlab.com/danielhb/qemu/tree/ppc-next. Thanks, Daniel On 5/30/23 10:28, BALATON Zoltan wrote: Hello, This series improves embedded PPC TLB emulation a bit and contains some misc clean up I've found along the way. Before this patch ppcemb_tlb_check() shows up in a memory access inte

Re: [PATCH v5 0/4] Add gdbstub support to HVF

2023-06-05 Thread Peter Maydell
On Thu, 1 Jun 2023 at 16:31, wrote: > > From: Francesco Cagnin > > This patch series aims to add gdbstub support to HVF (the 'QEMU accelerator > on macOS that employs Hypervisor.framework') on Apple Silicon hosts. > > The proposed implementation, structured like the KVM counterpart, handles > sin

Re: [PATCH v1 1/2] target/ppc: Fix decrementer time underflow and infinite timer loop

2023-06-05 Thread Daniel Henrique Barboza
On 5/30/23 10:12, Nicholas Piggin wrote: It is possible to store a very large value to the decrementer that it does not raise the decrementer exception so the timer is scheduled, but the next time value wraps and is treated as in the past. This can occur if (u64)-1 is stored on a zero-trigger

Re: [PATCH v1 2/2] target/ppc: Decrementer fix BookE semantics

2023-06-05 Thread Daniel Henrique Barboza
On 5/30/23 10:12, Nicholas Piggin wrote: The decrementer store function has logic that short-cuts the timer if a very small value is stored (0, 1, or 2) and raises an interrupt directly. There are two problem with this on BookE. First is that BookE says a decrementer interrupt should not be r

Re: [PATCH v2 2/4] target/ppc: Ensure stcx size matches larx

2023-06-05 Thread Daniel Henrique Barboza
On 6/4/23 23:54, Nicholas Piggin wrote: Differently-sized larx/stcx. pairs can succeed if the starting address matches. Add a check to require the size of stcx. exactly match the larx that established the reservation. Use the term "reserve_length" for this state, which matches the terminology

Re: [PATCH v2 1/4] target/ppc: Fix lqarx to set cpu_reserve

2023-06-05 Thread Daniel Henrique Barboza
On 6/4/23 23:54, Nicholas Piggin wrote: lqarx does not set cpu_reserve, which causes stqcx. to never succeed. Cc: qemu-sta...@nongnu.org Fixes: 94bf2658676 ("target/ppc: Use atomic load for LQ and LQARX") Fixes: 57b38ffd0c6 ("target/ppc: Use tcg_gen_qemu_{ld,st}_i128 for LQARX, LQ, STQ") Sig

Re: [PATCH v2 4/4] target/ppc: Rework store conditional to avoid branch

2023-06-05 Thread Daniel Henrique Barboza
On 6/4/23 23:54, Nicholas Piggin wrote: Rework store conditional to avoid a branch in the success case. Change some of the variable names and layout while here so gen_conditional_store more closely matches gen_stqcx_. Reviewed-by: Richard Henderson Signed-off-by: Nicholas Piggin --- Queue

Re: [PATCH v2 3/4] target/ppc: Remove larx/stcx. memory barrier semantics

2023-06-05 Thread Daniel Henrique Barboza
On 6/4/23 23:54, Nicholas Piggin wrote: larx and stcx. are not defined to order any memory operations. Remove the barriers. Reviewed-by: Richard Henderson Signed-off-by: Nicholas Piggin --- Queued. Thanks, Daniel target/ppc/translate.c | 11 --- 1 file changed, 11 deletions

Re: [PATCH v2] hw/scsi/megasas: Silent GCC duplicated-cond warning

2023-06-05 Thread Philippe Mathieu-Daudé
ping? On 28/3/23 23:01, Philippe Mathieu-Daudé wrote: From: Philippe Mathieu-Daudé GCC9 is confused when building with CFLAG -O3: hw/scsi/megasas.c: In function ‘megasas_scsi_realize’: hw/scsi/megasas.c:2387:26: error: duplicated ‘if’ condition [-Werror=duplicated-cond] 2387 |

Re: [QEMU][PATCH v6 0/4] Introduce Xilinx Versal CANFD

2023-06-05 Thread Peter Maydell
On Tue, 30 May 2023 at 22:12, Vikram Garhwal wrote: > > Hi, > This patch implements CANFD controller for xlnx-versal-virt machine. There are > two controllers CANFD0@0xFF06_ and CANFD1@0xFF07_ are connected to the > machine. > > Also, added basic qtests for data exchange between both the c

Re: [PATCH 0/6] tests: enable meson test timeouts to improve debuggability

2023-06-05 Thread Thomas Huth
On 01/06/2023 18.31, Daniel P. Berrangé wrote: Perhaps the most painful of all the GitLab CI failures we see are the enforced job timeouts: "ERROR: Job failed: execution took longer than 1h15m0s seconds" https://gitlab.com/qemu-project/qemu/-/jobs/4387047648 when that hits the CI log s

Re: [PATCH 0/6] tests: enable meson test timeouts to improve debuggability

2023-06-05 Thread Daniel P . Berrangé
On Mon, Jun 05, 2023 at 04:07:46PM +0200, Thomas Huth wrote: > On 01/06/2023 18.31, Daniel P. Berrangé wrote: > > Perhaps the most painful of all the GitLab CI failures we see are > > the enforced job timeouts: > > > > "ERROR: Job failed: execution took longer than 1h15m0s seconds" > > > >

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

2023-06-05 Thread Richard Henderson
https://gitlab.com/gaosong/qemu.git tags/pull-loongarch-20230605 for you to fetch changes up to 8555ddc671203969b0e6eb651e538d02a9a79b3a: hw/intc/loongarch_ipi: Bring back all 4 IPI mailboxes (2023-06-05 11:08:55 +0800) Fixe

[PATCH] virtio-net: correctly report maximum tx_queue_size value

2023-06-05 Thread Laurent Vivier
Maximum value for tx_queue_size depends on the backend type. 1024 for vDPA/vhost-user, 256 for all the others. The value is returned by virtio_net_max_tx_queue_size() to set the parameter: n->net_conf.tx_queue_size = MIN(virtio_net_max_tx_queue_size(n), n->

Re: [RFC v2] linux-user/riscv: Add syscall riscv_hwprobe

2023-06-05 Thread Robbin Ehn
On Fri, 2023-06-02 at 19:57 -0700, Richard Henderson wrote: > > > +case RISCV_HWPROBE_KEY_CPUPERF_0: > > +pair->value = RISCV_HWPROBE_MISALIGNED_UNKNOWN; > > Is that really what you want to expose here? FAST is always going to be > true, in that > handling the unaligned ac

Re: [RFC v2] linux-user/riscv: Add syscall riscv_hwprobe

2023-06-05 Thread Robbin Ehn
On Fri, 2023-06-02 at 20:00 -0700, Richard Henderson wrote: > On 6/2/23 08:07, Andrew Jones wrote: > > On Fri, Jun 02, 2023 at 04:39:20PM +0200, Robbin Ehn wrote: > > > On Fri, 2023-06-02 at 16:02 +0200, Andrew Jones wrote: > > > > On Fri, Jun 02, 2023 at 11:41:11AM +0200, Robbin Ehn wrote: > > ...

Re: [PATCH v1 1/2] qmp: remove virtio_list, search QOM tree instead

2023-06-05 Thread Jonah Palmer
On 5/17/23 04:12, Daniel P. Berrangé wrote: On Tue, May 16, 2023 at 03:26:25PM -0400, Jonah Palmer wrote: The virtio_list duplicates information about virtio devices that already exist in the QOM composition tree. Instead of creating this list of realized virtio devices, search the QOM composit

Re: [PATCH] target/sh4: Emit insn_start for each insn in gUSA region

2023-06-05 Thread Philippe Mathieu-Daudé
On 3/6/23 18:55, Richard Henderson wrote: Fixes an assert in tcg_gen_code that we don't accidentally eliminate an insn_start during optimization. Signed-off-by: Richard Henderson --- Test case is tests/tcg/multiarch/testthread.c; the assert for equality is new with https://lore.kernel.org/qem

Re: [RFC 2/4] qcow2: add configurations for zoned format extension

2023-06-05 Thread Eric Blake
On Mon, Jun 05, 2023 at 06:41:06PM +0800, Sam Li wrote: > To configure the zoned format feature on the qcow2 driver, it > requires following arguments: the device size, zoned profile, > zoned model, zone size, zone capacity, number of conventional > zones, limits on zone resources (max append secto

Re: [PATCH v5 8/9] vfio/migration: Add x-allow-pre-copy VFIO device property

2023-06-05 Thread Alex Williamson
On Sun, 4 Jun 2023 12:33:43 +0300 Avihai Horon wrote: > On 01/06/2023 23:22, Alex Williamson wrote: > > External email: Use caution opening links or attachments > > > > > > On Tue, 30 May 2023 17:48:20 +0300 > > Avihai Horon wrote: > > > >> Add a new VFIO device property x-allow-pre-copy to ke

Re: [PATCH 1/4] pnv/chiptod: Add POWER9/10 chiptod model

2023-06-05 Thread Cédric Le Goater
On 6/4/23 01:36, Nicholas Piggin wrote: The chiptod is a pervasive facility which can keep TOD (time-of-day), synchronise it across multiple chips, and can move that TOD to or from the core timebase units. This driver implements basic emulation of chiptod registers sufficient to successfully run

Re: [PATCH 2/4] target/ppc: Tidy POWER book4 SPR registration

2023-06-05 Thread Cédric Le Goater
On 6/4/23 01:36, Nicholas Piggin wrote: POWER book4 (implementation-specific) SPRs are sometimes in their own functions, but in other cases are mixed with architected SPRs. Do some spring cleaning on these. Signed-off-by: Nicholas Piggin Reviewed-by: Cédric Le Goater Thanks, C. --- ta

Re: [PATCH] target/sh4: Emit insn_start for each insn in gUSA region

2023-06-05 Thread Philippe Mathieu-Daudé
On 3/6/23 18:55, Richard Henderson wrote: Fixes an assert in tcg_gen_code that we don't accidentally eliminate an insn_start during optimization. Signed-off-by: Richard Henderson --- Test case is tests/tcg/multiarch/testthread.c; the assert for equality is new with https://lore.kernel.org/qem

Re: [PATCH v2] hw/scsi/megasas: Silent GCC duplicated-cond warning

2023-06-05 Thread Hannes Reinecke
On 6/5/23 15:44, Philippe Mathieu-Daudé wrote: ping? On 28/3/23 23:01, Philippe Mathieu-Daudé wrote: From: Philippe Mathieu-Daudé GCC9 is confused when building with CFLAG -O3:    hw/scsi/megasas.c: In function ‘megasas_scsi_realize’:    hw/scsi/megasas.c:2387:26: error: duplicated ‘if’ cond

Re: [PATCH] target/riscv: Smepmp: Return error when access permission not allowed in PMP

2023-06-05 Thread Richard Henderson
On 6/5/23 00:51, Himanshu Chauhan wrote: +ret = ((privs & *allowed_privs) == privs ? true : false); Never convert bool to bool in this way. r~

Re: [PATCH 0/2] Fix venv issues with Avocado by reverting to an older version

2023-06-05 Thread Paolo Bonzini
On 6/5/23 12:58, Peter Maydell wrote: On Mon, 5 Jun 2023 at 11:51, Paolo Bonzini wrote: On 6/5/23 11:46, Peter Maydell wrote: To avoid this issue, tests/requirements.txt should use a ">=" constraint and the version of Avocado should be limited to what distros provide in the system packages.

Re: [PATCH v5 00/11] *** Add allwinner-r40 support ***

2023-06-05 Thread Peter Maydell
On Thu, 1 Jun 2023 at 19:48, Niek Linnenbank wrote: > > Hi Qianfan, > > Thanks for sending the v5. From my side, I have no further comments on the > content. > So please feel free to add the following to each of the patches 01-11 in the > series: > > Reviewed-by: Niek Linnenbank > > As a remind

Re: [PATCH 0/6] tests: enable meson test timeouts to improve debuggability

2023-06-05 Thread Thomas Huth
On 05/06/2023 16.14, Daniel P. Berrangé wrote: On Mon, Jun 05, 2023 at 04:07:46PM +0200, Thomas Huth wrote: On 01/06/2023 18.31, Daniel P. Berrangé wrote: Perhaps the most painful of all the GitLab CI failures we see are the enforced job timeouts: "ERROR: Job failed: execution took longer

[PULL 04/17] iotests/iov-padding: New test

2023-06-05 Thread Hanna Czenczek
Test that even vectored IO requests with 1024 vector elements that are not aligned to the device's request alignment will succeed. Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy Signed-off-by: Hanna Czenczek Message-Id: <20230411173418.19549-5-hre...@redhat.com> --- tests/qe

[PULL 02/17] block: Collapse padded I/O vecs exceeding IOV_MAX

2023-06-05 Thread Hanna Czenczek
When processing vectored guest requests that are not aligned to the storage request alignment, we pad them by adding head and/or tail buffers for a read-modify-write cycle. The guest can submit I/O vectors up to IOV_MAX (1024) in length, but with this padding, the vector can exceed that limit. As

[PULL 11/17] parallels: Move check of cluster outside image to a separate function

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov We will add more and more checks so we need a better code structure in parallels_co_check. Let each check performs in a separate loop in a separate helper. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Message-Id: <20230424093147.197643-8-alexander.iva...@v

[PULL 15/17] parallels: Replace qemu_co_mutex_lock by WITH_QEMU_LOCK_GUARD

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov Replace the way we use mutex in parallels_co_check() for simplier and less error prone code. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Message-Id: <20230424093147.197643-12-alexander.iva...@virtuozzo.com> Reviewed-by: Hanna Czenczek Signed-off-by: Hann

[PULL 06/17] parallels: Fix high_off calculation in parallels_co_check()

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov Don't let high_off be more than the file size even if we don't fix the image. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Reviewed-by: Vladimir Sementsov-Ogievskiy Message-Id: <20230424093147.197643-3-alexander.iva...@virtuozzo.com> Reviewed-by: Hanna Cz

[PULL 08/17] parallels: create parallels_set_bat_entry_helper() to assign BAT value

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov This helper will be reused in next patches during parallels_co_check rework to simplify its code. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Reviewed-by: Vladimir Sementsov-Ogievskiy Message-Id: <20230424093147.197643-5-alexander.iva...@virtuozzo.com> R

[PULL 12/17] parallels: Fix statistics calculation

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov Exclude out-of-image clusters from allocated and fragmented clusters calculation. Signed-off-by: Alexander Ivanov Message-Id: <20230424093147.197643-9-alexander.iva...@virtuozzo.com> Reviewed-by: Hanna Czenczek Signed-off-by: Hanna Czenczek --- block/parallels.c | 6 ++

[PULL 01/17] util/iov: Make qiov_slice() public

2023-06-05 Thread Hanna Czenczek
We want to inline qemu_iovec_init_extended() in block/io.c for padding requests, and having access to qiov_slice() is useful for this. As a public function, it is renamed to qemu_iovec_slice(). (We will need to count the number of I/O vector elements of a slice there, and then later process this

[PULL 13/17] parallels: Move check of leaks to a separate function

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov We will add more and more checks so we need a better code structure in parallels_co_check. Let each check performs in a separate loop in a separate helper. Signed-off-by: Alexander Ivanov Message-Id: <20230424093147.197643-10-alexander.iva...@virtuozzo.com> Reviewed-by: H

[PULL 09/17] parallels: Use generic infrastructure for BAT writing in parallels_co_check()

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov BAT is written in the context of conventional operations over the image inside bdrv_co_flush() when it calls parallels_co_flush_to_os() callback. Thus we should not modify BAT array directly, but call parallels_set_bat_entry() helper and bdrv_co_flush() further on. After th

[PULL 03/17] util/iov: Remove qemu_iovec_init_extended()

2023-06-05 Thread Hanna Czenczek
bdrv_pad_request() was the main user of qemu_iovec_init_extended(). HEAD^ has removed that use, so we can remove qemu_iovec_init_extended() now. The only remaining user is qemu_iovec_init_slice(), which can easily inline the small part it really needs. Note that qemu_iovec_init_extended() offered

[PULL 07/17] parallels: Fix image_end_offset and data_end after out-of-image check

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov Set data_end to the end of the last cluster inside the image. In such a way we can be sure that corrupted offsets in the BAT can't affect on the image size. If there are no allocated clusters set image_end_offset by data_end. Signed-off-by: Alexander Ivanov Reviewed-by: D

[PULL 16/17] parallels: Incorrect condition in out-of-image check

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov All the offsets in the BAT must be lower than the file size. Fix the check condition for correct check. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Message-Id: <20230424093147.197643-13-alexander.iva...@virtuozzo.com> Reviewed-by: Hanna Czenczek Signed-o

[PULL 14/17] parallels: Move statistic collection to a separate function

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov We will add more and more checks so we need a better code structure in parallels_co_check. Let each check performs in a separate loop in a separate helper. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Reviewed-by: Vladimir Sementsov-Ogievskiy Message-Id:

[PULL 17/17] qcow2: add discard-no-unref option

2023-06-05 Thread Hanna Czenczek
From: Jean-Louis Dupond When we for example have a sparse qcow2 image and discard: unmap is enabled, there can be a lot of fragmentation in the image after some time. Especially on VM's that do a lot of writes/deletes. This causes the qcow2 image to grow even over 110% of its virtual size, becau

Re: [PATCH 0/6] tests: enable meson test timeouts to improve debuggability

2023-06-05 Thread Peter Maydell
On Mon, 5 Jun 2023 at 15:08, Thomas Huth wrote: > When I run them manually without the timeout patch, I get these > values: > > qtest-aarch64/test-hmp OK 168.66s 95 subtests passed > qtest-aarch64/qom-test OK 646.37s 94 subtests passed > qtest-arm/qom-test

[PULL 05/17] parallels: Out of image offset in BAT leads to image inflation

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov data_end field in BDRVParallelsState is set to the biggest offset present in BAT. If this offset is outside of the image, any further write will create the cluster at this offset and/or the image will be truncated to this offset on close. This is definitely not correct. Ra

[PULL 10/17] parallels: Move check of unclean image to a separate function

2023-06-05 Thread Hanna Czenczek
From: Alexander Ivanov We will add more and more checks so we need a better code structure in parallels_co_check. Let each check performs in a separate loop in a separate helper. Signed-off-by: Alexander Ivanov Reviewed-by: Denis V. Lunev Reviewed-by: Vladimir Sementsov-Ogievskiy Message-Id:

[PULL 00/17] Block patches

2023-06-05 Thread Hanna Czenczek
The following changes since commit 848a6caa88b9f082c89c9b41afa975761262981d: Merge tag 'migration-20230602-pull-request' of https://gitlab.com/juan.quintela/qemu into staging (2023-06-02 17:33:29 -0700) are available in the Git repository at: https://gitlab.com/hreitz/qemu.git tags/pull-blo

Re: [PATCH v5 11/11] docs: system: arm: Introduce bananapi_m2u

2023-06-05 Thread Peter Maydell
On Tue, 23 May 2023 at 11:06, wrote: > > From: qianfan Zhao > > Add documents for Banana Pi M2U > > Signed-off-by: qianfan Zhao > Reviewed-by: Niek Linnenbank The docs here turned out to have a couple of minor formatting issues which meant they didn't build. I've fixed them up with this extra

Re: [PATCH v3 00/20] target/arm: Implement FEAT_LSE2

2023-06-05 Thread Peter Maydell
On Tue, 30 May 2023 at 20:20, Richard Henderson wrote: > > All prerequisites are upstream. There are still outstanding patches > to improve the atomic16 support, but those are all optimizations. > > Patches needing r-b: > 16-target-arm-Relax-ordered-atomic-alignment-checks-.patch Applied to ta

[PATCH v2 0/2] Revert recent Avocado changes

2023-06-05 Thread Paolo Bonzini
Bumping avocado to version 101 has two issues. First, there are problems where Avocado is not logging of command lines or terminal output, and not collecting Python logs outside the avocado namespace. Second, the recent changes to Python handling mean that there is a single virtual environment fo

Re: [PATCH v4 0/2] target/arm: allow DC CVA[D]P in user mode emulation

2023-06-05 Thread Peter Maydell
On Thu, 1 Jun 2023 at 23:09, Zhuojia Shen wrote: > > This patch series enables executing DC CVAP and DC CVADP instructions in > AArch64 Linux user mode emulation and adds proper TCG tests. Applied to target-arm.next, thanks. -- PMM

Re: [PATCH] target/arm: trap DCC access in user mode emulation

2023-06-05 Thread Peter Maydell
On Sat, 3 Jun 2023 at 05:52, Richard Henderson wrote: > > On 6/2/23 14:43, Zhuojia Shen wrote: > > Accessing EL0-accessible Debug Communication Channel (DCC) registers in > > user mode emulation is currently enabled. However, it does not match > > Linux behavior as Linux sets MDSCR_EL1.TDCC on st

[PATCH v2 1/2] Revert "tests/requirements.txt: bump up avocado-framework version to 101.0"

2023-06-05 Thread Paolo Bonzini
This reverts commit ec5ffa0056389c3c10ea2de1e78366f66f4e5abc. Bumping avocado to version 101 has two issues. First, there are problems where Avocado is not logging of command lines or terminal output, and not collecting Python logs outside the avocado namespace. Second, the recent changes to Pyt

[PATCH v2 2/2] tests: Use separate virtual environment for avocado

2023-06-05 Thread Paolo Bonzini
This reverts commits eea2d141179 ("Makefile: remove $(TESTS_PYTHON)", 2023-05-26) and 9c6692db550 ("tests: Use configure-provided pyvenv for tests", 2023-05-18). Right now, there is a conflict between wanting a ">=" constraint when using a distro-provided package and wanting a "==" constraint when

Re: [PATCH 1/2] migration: switchover-hold parameter

2023-06-05 Thread Peter Xu
On Mon, Jun 05, 2023 at 03:27:53PM +0300, Avihai Horon wrote: > Hi Peter, > > On 02/06/2023 17:47, Peter Xu wrote: > > External email: Use caution opening links or attachments > > > > > > Add a new migration parameter switchover-hold which can block src qemu > > migration from switching over to

Re: [PATCH 05/12] hw/ssi: Introduce a ssi_get_cs() helper

2023-06-05 Thread Cédric Le Goater
On 6/5/23 07:57, Bernhard Beschow wrote: Am 31. Mai 2023 07:39:32 UTC schrieb "Philippe Mathieu-Daudé" : On 31/5/23 08:36, Cédric Le Goater wrote: On 5/31/23 08:17, Philippe Mathieu-Daudé wrote: +QOM tinkerers On 31/5/23 07:59, Cédric Le Goater wrote: On 5/30/23 23:15, Philippe Mathieu-Da

[PATCH v3] target/riscv: Smepmp: Return error when access permission not allowed in PMP

2023-06-05 Thread Himanshu Chauhan
On an address match, skip checking for default permissions and return error based on access defined in PMP configuration. v3 Changes: o Removed explicit return of boolean value from comparision of priv/allowed_priv v2 Changes: o Removed goto to return in place when address matches o Call pmp_ha

Re: [PATCH v5 3/5] parallels: Add checking and repairing duplicate offsets in BAT

2023-06-05 Thread Alexander Ivanov
On 6/2/23 16:43, Hanna Czenczek wrote: On 29.05.23 17:15, Alexander Ivanov wrote: Cluster offsets must be unique among all the BAT entries. Find duplicate offsets in the BAT and fix it by copying the content of the relevant cluster to a newly allocated cluster and set the new cluster offset

Re: [PATCH v3 03/15] hw/pci: Add a pci_device_iommu_memory_region() helper

2023-06-05 Thread Peter Xu
On Tue, May 30, 2023 at 06:59:25PM +0100, Joao Martins wrote: > Much like pci_device_iommu_address_space() fetches the IOMMU AS, add a > pci_device_iommu_memory_region() which lets it return an the IOMMU MR > associated with it. The IOMMU MR is returned correctly for vIOMMUs using > pci_setup_iommu

Re: [PULL 0/3] qemu-sparc queue 20230605

2023-06-05 Thread Richard Henderson
ository at: https://github.com/mcayland/qemu.git tags/qemu-sparc-20230605 for you to fetch changes up to 36c9189890bfb936b1b086da639e37fd92b50215: hw/isa/i82378: Remove unused "io" attribute (2023-06-05 07:43:23 +0100)

Re: [Qemu RFC 0/7] Early enabling of DCD emulation in Qemu

2023-06-05 Thread Ira Weiny
Fan Ni wrote: > Since the early draft of DCD support in kernel is out > (https://lore.kernel.org/linux-cxl/20230417164126.GA1904906@bgt-140510-bm03/T/#t), > this patch series provide dcd emulation in qemu so people who are interested > can have an early try. It is noted that the patch series may ne

[PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config() impl

2023-06-05 Thread Philippe Mathieu-Daudé
Commit b3f1c8c413 ("qemu-pr-helper: use new libmultipath API") declared the two [get/set]_multipath_config() functions to satisfy the 'new' API. The library already provides an internal implementation for these helpers, exposed as weak symbols. Since our implementation doesn't provide much, we can

[PATCH 1/2] scsi/qemu-pr-helper: Drop support for 'old' libmultipath API

2023-06-05 Thread Philippe Mathieu-Daudé
Commit 1b0578f5c4 ("qemu-pr-helper: Fix build on CentOS 7") added code to probe for 'old' libmultipath API on CentOS 7. However since merge commit 8c345b3e6a (June 2021) we don't build/test CentOS 7 as it felt out of our list of supported distrib versions. Therefore we can safely remove the 'old' A

[PATCH 0/2] scsi/qemu-pr-helper: Drop 'old' lib and use default config helpers

2023-06-05 Thread Philippe Mathieu-Daudé
The 'old' lib check was added for CentOS 7 which we don't support anymore. We don't need to implement particular [get/set]_multipath_config() helpers: use the defaults. Philippe Mathieu-Daudé (2): scsi/qemu-pr-helper: Drop support for 'old' libmultipath API scsi/qemu-pr-helper: Use defaults [

Re: [PATCH 0/2] scsi/qemu-pr-helper: Drop 'old' lib and use default config helpers

2023-06-05 Thread Philippe Mathieu-Daudé
On 5/6/23 19:41, Philippe Mathieu-Daudé wrote: The 'old' lib check was added for CentOS 7 which we don't support anymore. We don't need to implement particular [get/set]_multipath_config() helpers: use the defaults. Philippe Mathieu-Daudé (2): scsi/qemu-pr-helper: Drop support for 'old' libm

Re: [Qemu RFC 0/7] Early enabling of DCD emulation in Qemu

2023-06-05 Thread Fan Ni
On Mon, Jun 05, 2023 at 10:35:48AM -0700, Ira Weiny wrote: > Fan Ni wrote: > > Since the early draft of DCD support in kernel is out > > (https://urldefense.com/v3/__https://lore.kernel.org/linux-cxl/20230417164126.GA1904906@bgt-140510-bm03/T/*t__;Iw!!EwVzqGoTKBqv-0DWAJBm!RHzXPIcSiGsqUciUIH6HnlG_W-

Re: [PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config() impl

2023-06-05 Thread Paolo Bonzini
On 6/5/23 19:41, Philippe Mathieu-Daudé wrote: Commit b3f1c8c413 ("qemu-pr-helper: use new libmultipath API") declared the two [get/set]_multipath_config() functions to satisfy the 'new' API. The library already provides an internal implementation for these helpers, exposed as weak symbols. Since

[PATCH v2 0/5] bulk: Do not declare function prototypes using 'extern' keyword

2023-06-05 Thread Philippe Mathieu-Daudé
Since v2: - Do not change variable declarations in "block/dmg.h" (danpb) - Rebased - Added R-b from v1 v1: - Remove the 'extern' keyword on function prototypes declared in header. - Replace __attribute__((noreturn)) -> G_NORETURN - Trivial cleanups to keep the previous commits generic. Based-on

[PATCH v2 5/5] bulk: Replace __attribute__((noreturn)) -> G_NORETURN

2023-06-05 Thread Philippe Mathieu-Daudé
Under MSYS2, G_NORETURN is expanded to '[[noreturn]]'. Simpler to use the same definition everywhere, unifying the code style. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Juan Quintela --- include/sysemu/os-win32.h | 2 +- tests/migration/stress.c | 2 +- 2 files changed, 2 insertions(+

[PATCH v2 4/5] bulk: Do not declare function prototypes using 'extern' keyword

2023-06-05 Thread Philippe Mathieu-Daudé
By default, C function prototypes declared in headers are visible, so there is no need to declare them as 'extern' functions. Remove this redundancy in a single bulk commit; do not modify: - meson.build (used to check function availability at runtime) - pc-bios/ - libdecnumber/ - tests/

[PATCH v2 1/5] util/cacheflush: Use declarations from on Darwin

2023-06-05 Thread Philippe Mathieu-Daudé
Per the cache(3) man page, sys_icache_invalidate() and sys_dcache_flush() are declared in . Signed-off-by: Philippe Mathieu-Daudé --- util/cacheflush.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/cacheflush.c b/util/cacheflush.c index 06c2333a60..de35616718 10064

<    1   2   3   4   >