Re: [PATCH v2 3/6] python/console_socket: accept existing FD in initializer

2023-07-26 Thread Ani Sinha
> On 25-Jul-2023, at 11:33 PM, John Snow wrote: > > Useful if we want to use ConsoleSocket() for a socket created by > socketpair(). > > Signed-off-by: John Snow Reviewed-by: Ani Sinha > --- > python/qemu/machine/console_socket.py | 29 +++ > 1 file changed, 21 inse

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

2023-07-26 Thread Ani Sinha
> On 26-Jul-2023, at 10:51 PM, John Snow wrote: > > > > On Wed, Jul 26, 2023, 6:50 AM Ani Sinha wrote: > > > > 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 th

Re: [PATCH v2 3/8] machine: Print supported CPU models instead of typenames

2023-07-26 Thread Gavin Shan
On 7/27/23 09:08, Richard Henderson wrote: On 7/25/23 17:32, Gavin Shan wrote: -static const char *q800_machine_valid_cpu_types[] = { +static const char * const q800_machine_valid_cpu_types[] = {   M68K_CPU_TYPE_NAME("m68040"),   NULL   }; +static const char * const q800_machine_valid_

Re: [External] Re: [PATCH] memory: avoid updating ioeventfds for some address_space

2023-07-26 Thread hongmainquan
在 2023/7/27 1:45 上午, Peter Xu 写道: On Tue, Jul 25, 2023 at 07:20:37PM +0800, hongmianquan wrote: When updating ioeventfds, we need to iterate all address spaces, but some address spaces do not register eventfd_add|del call when memory_listener_register() and they do nothing when updating ioeve

Re: [PATCH 0/8] Adds CPU hot-plug support to Loongarch

2023-07-26 Thread lixianglai
Hi Gavin and Salil, On 7/27/23 8:57 AM, Gavin Shan wrote: Hi Xianglai, On 7/20/23 17:15, xianglai li wrote: Hello everyone, We refer to the implementation of ARM CPU Hot-Plug to add GED-based CPU Hot-Plug support to Loongarch. The first 4 patches are changes to the QEMU common code, including

Re: [PATCH] migrate/multifd: fix coredump when the multifd thread cleanup

2023-07-26 Thread chenyuhui (A)
On 2023/7/26 0:53, Peter Xu wrote: > On Tue, Jul 25, 2023 at 04:43:28PM +0800, chenyuhui (A) wrote: >> @Peter Xu @Fabiano Rosas >> Kindly ping on this. > > Ah I see what's missing - please copy maintainer (Juan) for any migration > patches, especially multifd ones.. I'm doing that for this one

Re: [PATCH v7 0/4] hw/ufs: Add Universal Flash Storage (UFS) support

2023-07-26 Thread Jeuk Kim
On 7/27/2023 4:36 AM, Stefan Hajnoczi wrote: On Wed, Jul 26, 2023 at 02:30:49PM +0900, Jeuk Kim wrote: Since v6: - Add tests/qtest/ufs-test.c to test ufs initialisation and I/O - Add struct UtpTaskReqDesc to include/block/ufs.h - Fix ufs_log2() logic - Fix ufs-lu to use 4K as default block size

Re: [PATCH] target/i386: Fix reporting of CPU dies when nr_cores=nr_threads=1

2023-07-26 Thread Xiaoyao Li
On 7/24/2023 2:59 AM, 小太 wrote: When QEMU is started with `-smp D,sockets=1,dies=D,cores=1,threads=1` (that is, 1 socket with D dies but each die contains just a single thread), both Linux and Windows guests incorrectly interprets the system as having D sockets with 1 die each Ultimately this is

Re: [PATCH 0/8] Adds CPU hot-plug support to Loongarch

2023-07-26 Thread Gavin Shan
Hi Xianglai, On 7/20/23 17:15, xianglai li wrote: Hello everyone, We refer to the implementation of ARM CPU Hot-Plug to add GED-based CPU Hot-Plug support to Loongarch. The first 4 patches are changes to the QEMU common code, including adding GED support for CPU Hot-Plug, updating the ACPI tabl

[PATCH] tests/migration-test: Remove arch_target

2023-07-26 Thread Peter Xu
It is always NULL, so drop it. Cc: Juan Quintela Fixes: Coverity CID 1518101 Signed-off-by: Peter Xu --- tests/qtest/migration-test.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c index 62d3f37021..7ce1379ba8 1

Re: how to build qemu 8.1 - keycodemapdb?

2023-07-26 Thread Michael Roth
Quoting Daniel P. Berrangé (2023-07-26 04:18:37) > 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-p

Re: [PATCH v2 3/8] machine: Print supported CPU models instead of typenames

2023-07-26 Thread Richard Henderson
On 7/25/23 17:32, Gavin Shan wrote: -static const char *q800_machine_valid_cpu_types[] = { +static const char * const q800_machine_valid_cpu_types[] = { M68K_CPU_TYPE_NAME("m68040"), NULL }; +static const char * const q800_machine_valid_cpu_models[] = { +"m68040", +NULL

Re: [PATCH v2 2/8] machine: Introduce helper is_cpu_type_supported()

2023-07-26 Thread Richard Henderson
On 7/25/23 17:31, Gavin Shan wrote: The logic of checking if the specified CPU type is supported in machine_run_board_init() is independent enough. Factor it out into helper is_cpu_type_supported(). With this, machine_run_board_init() looks a bit clean. Since we're here, @machine_class is renamed

[PATCH v2 0/2] Fix MCE handling on AMD hosts

2023-07-26 Thread John Allen
In the event that a guest process attempts to access memory that has been poisoned in response to a deferred uncorrected MCE, an AMD system will currently generate a SIGBUS error which will result in the entire guest being shutdown. Ideally, we only want to kill the guest process that accessed pois

[PATCH for-8.1] accel/tcg: Clear tcg_ctx->gen_tb on buffer overflow

2023-07-26 Thread Richard Henderson
On overflow of code_gen_buffer, we unlock the guest pages we had been translating, but failed to clear gen_tb. On restart, if we cannot allocate a TB, we exit to the main loop to perform the flush of all TBs as soon as possible. With garbage in gen_tb, we hit an assert: ../src/accel/tcg/tb-maint

[PATCH v2 1/2] i386: Add support for SUCCOR feature

2023-07-26 Thread John Allen
Add cpuid bit definition for the SUCCOR feature. This cpuid bit is required to be exposed to guests to allow them to handle machine check exceptions on AMD hosts. Reported-by: William Roche Signed-off-by: John Allen --- v2: - Add "succor" feature word. - Add case to kvm_arch_get_supported_cp

[PATCH v2 2/2] i386: Fix MCE support for AMD hosts

2023-07-26 Thread John Allen
For the most part, AMD hosts can use the same MCE injection code as Intel but, there are instances where the qemu implementation is Intel specific. First, MCE deliviery works differently on AMD and does not support broadcast. Second, kvm_mce_inject generates MCEs that include a number of Intel spec

Implementing "tee" in python asyncio

2023-07-26 Thread John Snow
Hi folks, I'm currently wondering how to take a StreamReader as found on https://docs.python.org/3/library/asyncio-subprocess.html#asyncio.subprocess.Process and to consume the data while optionally re-streaming it to a secondary consumer. What I'd like to do is create a StreamWatcher class that

Re: [PATCH V1 2/3] migration: fix suspended runstate

2023-07-26 Thread Peter Xu
On Fri, Jun 30, 2023 at 09:50:41AM -0400, Steven Sistare wrote: > On 6/26/2023 2:27 PM, Peter Xu wrote: > > On Fri, Jun 23, 2023 at 02:25:05PM -0400, Steven Sistare wrote: > >> On 6/21/2023 4:28 PM, Peter Xu wrote: > >>> On Wed, Jun 21, 2023 at 03:15:42PM -0400, Steven Sistare wrote: > On 6/20

[PATCH QEMU 2/2] MAINTAINERS: Add Hyman Huang to dirty-limit feature

2023-07-26 Thread ~hyman
From: Hyman Huang(黄勇) Signed-off-by: Hyman Huang(黄勇) --- MAINTAINERS | 6 ++ 1 file changed, 6 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 12e59b6b27..d72fd63a8e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -3437,6 +3437,12 @@ F: hw/core/clock-vmstate.c F: hw/core/qdev-clo

[PATCH QEMU 1/2] qapi: Reformat and craft the migration doc comments

2023-07-26 Thread ~hyman
From: Hyman Huang(黄勇) Reformat migration doc comments to conform to current conventions as commit a937b6aa739 (qapi: Reformat doc comments to conform to current conventions). Also, craft the dirty-limit capability comment. Signed-off-by: Hyman Huang(黄勇) --- qapi/migration.json | 66 ++

[PATCH QEMU 0/2] migration: craft the doc comments

2023-07-26 Thread ~hyman
Hi, Markus, This patchset aims to reformat migration doc comments as commit a937b6aa739. Meanwhile, add myself to the dirty-limit feature maintainer list. Please review, Thanks. Yong Hyman Huang(黄勇) (2): qapi: Reformat and craft the migration doc comments MAINTAINERS: Add Hyman Huang to di

Re: [PATCH v7 0/4] hw/ufs: Add Universal Flash Storage (UFS) support

2023-07-26 Thread Stefan Hajnoczi
On Wed, Jul 26, 2023 at 02:30:49PM +0900, Jeuk Kim wrote: > Since v6: > - Add tests/qtest/ufs-test.c to test ufs initialisation and I/O > - Add struct UtpTaskReqDesc to include/block/ufs.h > - Fix ufs_log2() logic > - Fix ufs-lu to use 4K as default block size to match the ufs spec > > Since I cre

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

2023-07-26 Thread Stefan Hajnoczi
On Wed, Jul 26, 2023 at 02:30:53PM +0900, Jeuk Kim wrote: > +static void *ufs_blk_test_setup(GString *cmd_line, void *arg) > +{ > +char *tmp_path = drive_create(); > + > +g_string_append_printf(cmd_line, > + " -drive if=none,id=drv1,file=%s," > +

Re: [PATCH] memory: avoid updating ioeventfds for some address_space

2023-07-26 Thread Peter Xu
On Tue, Jul 25, 2023 at 07:20:37PM +0800, hongmianquan wrote: > When updating ioeventfds, we need to iterate all address spaces, > but some address spaces do not register eventfd_add|del call when > memory_listener_register() and they do nothing when updating ioeventfds. > So we can skip these AS i

[PATCH 6/6] target/ppc: Migrate DECR SPR

2023-07-26 Thread Nicholas Piggin
TCG does not maintain the DEC reigster in the SPR array, so it does get migrated. TCG also needs to re-start the decrementer timer on the destination machine. Load and store the decrementer into the SPR when migrating. This works for the level-triggered (book3s) decrementer, and should be compatib

[PATCH 5/7] tests/avocado: boot ppc64 pseries replay-record test to Linux VFS mount

2023-07-26 Thread Nicholas Piggin
This the ppc64 record-replay test is able to replay the full kernel boot so try enabling it. Cc: Pavel Dovgalyuk Signed-off-by: Nicholas Piggin --- tests/avocado/replay_kernel.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/avocado/replay_kernel.py b/tests/avocado

[PATCH 3/6] target/ppc: Fix pending HDEC when entering PM state

2023-07-26 Thread Nicholas Piggin
HDEC is defined to not wake from PM state. There is a check in the HDEC timer to avoid setting the interrupt if we are in a PM state, but no check on PM entry to lower HDEC if it already fired. This can cause a HDECR wake up and QEMU abort with unsupported exception in Power Save mode. Fixes: 4b2

Re: [PATCH] gitlab: remove duplication between msys jobs

2023-07-26 Thread Thomas Huth
On 26/07/2023 18.19, Daniel P. Berrangé wrote: Although they share a common parent, the two msys jobs still have massive duplication in their script definitions that can easily be collapsed. Signed-off-by: Daniel P. Berrangé --- .gitlab-ci.d/windows.yml | 132 +++--

[PATCH 4/7] spapr: Fix record-replay machine reset consuming too many events

2023-07-26 Thread Nicholas Piggin
spapr_machine_reset gets a random number to populate the device-tree rng seed with. When loading a snapshot for record-replay, the machine is reset again, and that tries to consume the random event record again, crashing due to inconsistent record Fix this by saving the seed to populate the device

[PATCH 2/7] target/ppc: Fix timebase reset with record-replay

2023-07-26 Thread Nicholas Piggin
Timebase save uses a random number for a legacy vmstate field, which makes rr snapshot loading unbalanced. The easiest way to deal with this is just to skip the rng if record-replay is active. Reviewed-by: Pavel Dovgalyuk Signed-off-by: Nicholas Piggin --- hw/ppc/ppc.c | 11 +-- 1 file

Re: [PATCH v6 4/5] intel_iommu: allow Extended Interrupt Mode when using userspace APIC

2023-07-26 Thread Peter Xu
On Fri, Jul 21, 2023 at 10:35:01PM +0700, Bui Quang Minh wrote: > On 7/21/23 03:47, Peter Xu wrote: > > On Mon, Jul 17, 2023 at 11:29:56PM +0700, Bui Quang Minh wrote: > > > On 7/17/23 17:47, Joao Martins wrote: > > > > +Peter, +Jason (intel-iommu maintainer/reviewer) > > > > Thanks for copying me

[PATCH 4/6] hw/ppc: Avoid decrementer rounding errors

2023-07-26 Thread Nicholas Piggin
The decrementer register contains a relative time in timebase units. When writing to DECR this is converted and stored as an absolute value in nanosecond units, reading DECR converts back to relative timebase. The tb<->ns conversion of the relative part can cause rounding such that a value writen

Re: [PATCH v1] migration: refactor migration_completion

2023-07-26 Thread Peter Xu
On Fri, Jul 21, 2023 at 11:14:55AM +, Wang, Wei W wrote: > On Friday, July 21, 2023 4:38 AM, Peter Xu wrote: > > Looks good to me, after addressing Isaku's comments. > > > > The current_active_state is very unfortunate, along with most of the calls > > to > > migrate_set_state() - I bet most

[PATCH 1/6] target/ppc: Implement ASDR register for ISA v3.0 for HPT

2023-07-26 Thread Nicholas Piggin
The ASDR register was introduced in ISA v3.0. It has not been implemented for HPT. With HPT, ASDR is the format of the slbmte RS operand (containing VSID), which matches the ppc_slb_t field. Fixes: 3367c62f522b ("target/ppc: Support for POWER9 native hash") Signed-off-by: Nicholas Piggin --- tar

[PATCH 2/6] target/ppc: Fix VRMA page size for ISA v3.0

2023-07-26 Thread Nicholas Piggin
Until v2.07s, the VRMA page size (L||LP) was encoded in LPCR[VRMASD]. In v3.0 that moved to the partition table PS field. The powernv machine can now run KVM HPT guests on POWER9/10 CPUs with this fix and the patch to add ASDR. Fixes: 3367c62f522b ("target/ppc: Support for POWER9 native hash") Si

[PATCH 2/2] virtio-gpu: reset gfx resources in main thread

2023-07-26 Thread marcandre . lureau
From: Marc-André Lureau Calling OpenGL from different threads can have bad consequences if not carefully reviewed. It's not generally supported. In my case, I was debugging a crash in glDeleteTextures from OPENGL32.DLL, where I asked qemu for gl=es, and thus ANGLE implementation was expected. lib

[PATCH 5/6] hw/ppc: Always store the decrementer value

2023-07-26 Thread Nicholas Piggin
When writing a value to the decrementer that raises an exception, the irq is raised, but the value is not stored so the store doesn't appear to have changed the register when it is read again. Always store the write value to the register. Fixes: e81a982aa53 ("PPC: Clean up DECR implementation") S

[PATCH 1/7] target/ppc: Fix CPU reservation migration for record-replay

2023-07-26 Thread Nicholas Piggin
ppc only migrates reserve_addr, so the destination machine can get a valid reservation with an incorrect reservation value of 0. Prior to commit 392d328abe753 ("target/ppc: Ensure stcx size matches larx"), this could permit a stcx. to incorrectly succeed. That commit inadvertently fixed that bug be

[PATCH 0/2] virtio-gpu: reset gfx resources in main thread

2023-07-26 Thread marcandre . lureau
From: Marc-André Lureau Hi, See the second patch for details. thanks Marc-André Lureau (2): virtio-gpu: free BHs, by implementing unrealize virtio-gpu: reset gfx resources in main thread include/hw/virtio/virtio-gpu.h | 4 +++ hw/display/virtio-gpu-base.c | 2 +- hw/display/virtio-gpu

[PATCH 3/7] spapr: Fix machine reset deadlock from replay-record

2023-07-26 Thread Nicholas Piggin
When the machine is reset to load a new snapshot while being debugged with replay-record, it is done from another thread, so the CPU does not run the register setting operations. Set CPU registers directly in machine reset. Cc: Pavel Dovgalyuk Signed-off-by: Nicholas Piggin --- hw/ppc/spapr.c

Re: [PATCH v10 09/10] migration: Implement MigrateChannelList to hmp migration flow.

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 10:08:05PM +0530, Het Gala wrote: > > On 26/07/23 8:25 pm, Daniel P. Berrangé wrote: > > On Wed, Jul 26, 2023 at 02:18:32PM +, Het Gala wrote: > > > Integrate MigrateChannelList with all transport backends > > > (socket, exec and rdma) for both src and dest migration >

[PATCH 0/7] ppc: record-replay fixes and enablement

2023-07-26 Thread Nicholas Piggin
Here is a series that gets ppc pseries and powernv machines into better shape for record-replay, maybe for 8.2. It's likely got a few deficiencies but it does run test cases and helped find bugs in migration already. It requires previous decrementer fixes to work well. I think we can get away with

Re: [PATCH] gitlab: remove duplication between msys jobs

2023-07-26 Thread Marc-André Lureau
Hi On Wed, Jul 26, 2023 at 10:21 PM Thomas Huth wrote: > > On 26/07/2023 18.19, Daniel P. Berrangé wrote: > > Although they share a common parent, the two msys jobs still have > > massive duplication in their script definitions that can easily be > > collapsed. > > > > Signed-off-by: Daniel P. Be

[PATCH 0/6] ppc fixes possibly for 8.1

2023-07-26 Thread Nicholas Piggin
Sorry for the delay following up on the fixes, I got sucked down the decrementer rabbit hole that took longer than expected. Question about what is suitable for merge at this time and what should be stable. The first 3 have caused crashes or hangs running Linux and other software. Second 3 fix som

[PATCH for-8.1] target/arm: Fix MemOp for STGP

2023-07-26 Thread Richard Henderson
When converting to decodetree, the code to rebuild mop for the pair only made it into trans_STP and not into trans_STGP. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1790 Fixes: 8c212eb6594 ("target/arm: Convert load/store-pair to decodetree") Signed-off-by: Richard Henderson --- targ

Re: [PATCH 1/1] qemu-nbd: regression with arguments passing into nbd_client_thread()

2023-07-26 Thread Eric Blake
On Wed, Jul 26, 2023 at 04:52:47PM +0200, Denis V. Lunev wrote: > Unfortunately > commit 03b67621445d601c9cdc7dfe25812e9f19b81488 > Author: Denis V. Lunev > Date: Mon Jul 17 16:55:40 2023 +0200 > qemu-nbd: pass structure into nbd_client_thread instead of plain char* > has introdu

[PATCH 7/7] tests/avocado: ppc64 reverse debugging tests for pseries and powernv

2023-07-26 Thread Nicholas Piggin
These machines run reverse-debugging well enough to pass basic tests. Wire them up. Cc: Pavel Dovgalyuk Signed-off-by: Nicholas Piggin --- tests/avocado/reverse_debugging.py | 29 + 1 file changed, 29 insertions(+) diff --git a/tests/avocado/reverse_debugging.py b/

[PATCH 6/7] tests/avocado: reverse-debugging cope with re-executing breakpoints

2023-07-26 Thread Nicholas Piggin
The reverse-debugging test creates a trace, then replays it and: 1. Steps the first 10 instructions and records their addresses. 2. Steps backward and verifies their addresses match. 3. Runs to (near) the end of the trace. 4. Sets breakpoints on the first 10 instructions. 5. Continues backward and

[PATCH 1/2] virtio-gpu: free BHs, by implementing unrealize

2023-07-26 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- include/hw/virtio/virtio-gpu.h | 1 + hw/display/virtio-gpu-base.c | 2 +- hw/display/virtio-gpu.c| 10 ++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/include/hw/virtio/virtio-gpu.h b/include/hw/

Re: [PATCH v10 09/10] migration: Implement MigrateChannelList to hmp migration flow.

2023-07-26 Thread Het Gala
On 26/07/23 10:11 pm, Daniel P. Berrangé wrote: On Wed, Jul 26, 2023 at 10:08:05PM +0530, Het Gala wrote: On 26/07/23 8:25 pm, Daniel P. Berrangé wrote: On Wed, Jul 26, 2023 at 02:18:32PM +, Het Gala wrote: Integrate MigrateChannelList with all transport backends (socket, exec and rdma)

Re: [PATCH v2 0/7] migration: Better error handling in return path thread

2023-07-26 Thread Peter Xu
Hi, Fabiano, Sorry to be late on responding. On Tue, Jul 25, 2023 at 03:24:26PM -0300, Fabiano Rosas wrote: > Fabiano Rosas writes: > > > Peter Xu writes: > > > >> v2: > >> - Patch "migration: Provide explicit error message for file shutdowns" > >> - Touched up qapi doc [Fabiano] > >> - Ad

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

2023-07-26 Thread John Snow
On Wed, Jul 26, 2023, 6:50 AM Ani Sinha wrote: > > > > 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

Re: [PATCH] migration/ram: Refactor precopy ram loading code

2023-07-26 Thread Peter Xu
On Tue, Jul 25, 2023 at 10:26:51AM -0300, Fabiano Rosas wrote: > From: Nikolay Borisov > > Extract the ramblock parsing code into a routine that operates on the > sequence of headers from the stream and another the parses the > individual ramblock. This makes ram_load_precopy() easier to > compre

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

2023-07-26 Thread Bernhard Beschow
Am 26. Juli 2023 09:24:28 UTC schrieb 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

Re: [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user

2023-07-26 Thread Stefan Hajnoczi
On Wed, Jul 26, 2023 at 12:02:33PM -0400, Michael S. Tsirkin wrote: > On Mon, Jul 24, 2023 at 02:08:39PM -0400, Stefan Hajnoczi wrote: > > On Thu, Jul 20, 2023 at 06:22:08PM -0400, Michael S. Tsirkin wrote: > > > On Thu, Jul 20, 2023 at 05:31:03PM -0400, Stefan Hajnoczi wrote: > > > > On Thu, 20 Ju

Re: intel-iommu: Report interrupt remapping faults, fix return value

2023-07-26 Thread Peter Xu
On Tue, Jul 25, 2023 at 11:01:16AM +0100, David Woodhouse wrote: > From: David Woodhouse > > A generic X86IOMMUClass->int_remap function should not return VT-d > specific values; fix it to return 0 if the interrupt was successfully > translated or -EINVAL if not. > > The VTD_FR_IR_xxx values are

Re: [PATCH v10 09/10] migration: Implement MigrateChannelList to hmp migration flow.

2023-07-26 Thread Het Gala
On 26/07/23 8:25 pm, Daniel P. Berrangé wrote: On Wed, Jul 26, 2023 at 02:18:32PM +, Het Gala wrote: Integrate MigrateChannelList with all transport backends (socket, exec and rdma) for both src and dest migration endpoints for hmp migration. Suggested-by: Aravind Retnakaran Signed-off-b

Re: [PULL 00/25] Migration 20230726 patches

2023-07-26 Thread Richard Henderson
-20230726-pull-request for you to fetch changes up to 697c4c86ab515a728ffb2adc2c3c04b22fa9210f: migration/rdma: Split qemu_fopen_rdma() into input/output functions (2023-07-26 10:55:56 +0200) Migration Pull request Hi This is the

[PATCH] gitlab: remove duplication between msys jobs

2023-07-26 Thread Daniel P . Berrangé
Although they share a common parent, the two msys jobs still have massive duplication in their script definitions that can easily be collapsed. Signed-off-by: Daniel P. Berrangé --- .gitlab-ci.d/windows.yml | 132 +++ 1 file changed, 49 insertions(+), 83 delet

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

2023-07-26 Thread ni...@outlook.com
The 07/26/2023 07:53, Nathan Fontenot wrote: > 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 operati

Re: [PULL 0/2] Misc next patches

2023-07-26 Thread Richard Henderson
On 7/25/23 09:23, Daniel P. Berrangé wrote: The following changes since commit a279ca4ea07383314b2d2b2f1d550be9482f148e: Merge tag 'pull-target-arm-20230725' ofhttps://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-07-25 12:44:39 +0100) are available in the Git repository at:

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

2023-07-26 Thread Richard Henderson
On 7/26/23 05:57, Markus Armbruster wrote: 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-

Re: [virtio-dev] [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user

2023-07-26 Thread Michael S. Tsirkin
On Thu, Jul 20, 2023 at 03:36:01PM -0400, Stefan Hajnoczi wrote: > On Fri, Jul 07, 2023 at 12:27:39PM +0200, Stefano Garzarella wrote: > > On Tue, Jul 04, 2023 at 04:02:42PM +0100, Alex Bennée wrote: > > > > > > Stefano Garzarella writes: > > > > > > > On Tue, Jul 04, 2023 at 01:36:00PM +0100, A

Re: [virtio-dev] [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user

2023-07-26 Thread Stefan Hajnoczi
On Wed, 26 Jul 2023 at 11:42, Erik Schilling wrote: > > On Tue Jul 4, 2023 at 4:54 PM CEST, Stefano Garzarella wrote: > > On Tue, Jul 04, 2023 at 01:36:00PM +0100, Alex Bennée wrote: > > >Currently QEMU has to know some details about the back-end to be able > > >to setup the guest. While various p

Re: [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user

2023-07-26 Thread Michael S. Tsirkin
On Mon, Jul 24, 2023 at 02:08:39PM -0400, Stefan Hajnoczi wrote: > On Thu, Jul 20, 2023 at 06:22:08PM -0400, Michael S. Tsirkin wrote: > > On Thu, Jul 20, 2023 at 05:31:03PM -0400, Stefan Hajnoczi wrote: > > > On Thu, 20 Jul 2023 at 17:15, Michael S. Tsirkin wrote: > > > > > > > > On Thu, Jul 20,

[PATCH 2/3] Rework i.MX7 device implementation/instantiation

2023-07-26 Thread Jean-Christophe Dubois
From: jcdubois * Add Addr and size definition for all i.MX7 devices in i.MX7 header file. * Use those newly defined named constants whenever possible. * Standardize the way we init a familly of unimplemented devices - SAI - PWM - CAN * Add TZASC as unimplemented device. - Allow bare metal

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

2023-07-26 Thread Stefano Garzarella
On Wed, Jul 26, 2023 at 11:32:10AM -0400, Stefan Hajnoczi wrote: On Wed, Jul 26, 2023 at 09:26:45AM +0200, Stefano Garzarella wrote: 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 sup

[PATCH 3/3] Add i.MX7 SRC device implementation

2023-07-26 Thread Jean-Christophe Dubois
From: jcdubois The SRC device is normaly used to start the secondary CPU. When running Linux directly, Qemu is emulating a PSCI interface that UBOOT is installing at boot time and therefore the fact that the SRC device is unimplemented is hidden as Qemu respond directly to PSCI requets without u

[PATCH 1/3] Rework i.MX6UL device implementation/instantiation

2023-07-26 Thread Jean-Christophe Dubois
From: jcdubois * Add Addr and size definition for all i.MX6UL devices in i.MX6UL header file. * Use those newly defined named constants whenever possible. * Standardize the way we init a familly of unimplemented devices - SAI - PWM (add missing PWM instances) - CAN * Add TZASC as unimplemen

[PATCH 0/3] Complete i.MX6UL and i.MX7 processor for bare metal application.

2023-07-26 Thread Jean-Christophe Dubois
This patch adds a few unimplemented TZ devices (TZASC and CSU) to i.MX6UL and i.MX7 processors to avoid bare metal application to experiment "bus error" when acccessing these devices. It also adds some internal memory segments (OCRAM) to the i.MX7 to allow bare metal application to use them. Last

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

2023-07-26 Thread Stefan Hajnoczi
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] ui/dbus: fix clang compilation issue

2023-07-26 Thread Thomas Huth
On 26/07/2023 17.12, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau ../ui/dbus-listener.c:236:9: error: expected expression Error *err = NULL; See: https://gitlab.com/qemu-project/qemu/-/issues/1782#note_1488517427 Signed-off-by: Marc-André Lureau --- ui/dbus-listener.

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

2023-07-26 Thread Stefan Hajnoczi
On Wed, Jul 26, 2023 at 09:26:45AM +0200, Stefano Garzarella wrote: > 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.

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

2023-07-26 Thread Richard Henderson
On 7/26/23 02:43, Peter Maydell wrote: (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 st

[PATCH v2] softmmu/physmem: try opening file readonly before failure in file_ram_open

2023-07-26 Thread Thiner Logoer
Users may give "-mem-path" a read only file and expect the file to be mapped read-write privately. Allow this but give a warning since other users may surprise when the ram file is readonly and qemu suddenly aborts elsewhere. Suggested-by: David Hildenbrand Signed-off-by: Thiner Logoer --- See

[PATCH] ui/dbus: fix clang compilation issue

2023-07-26 Thread marcandre . lureau
From: Marc-André Lureau ../ui/dbus-listener.c:236:9: error: expected expression Error *err = NULL; See: https://gitlab.com/qemu-project/qemu/-/issues/1782#note_1488517427 Signed-off-by: Marc-André Lureau --- ui/dbus-listener.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) d

[PATCH 1/1] qemu-nbd: regression with arguments passing into nbd_client_thread()

2023-07-26 Thread Denis V. Lunev
Unfortunately commit 03b67621445d601c9cdc7dfe25812e9f19b81488 Author: Denis V. Lunev Date: Mon Jul 17 16:55:40 2023 +0200 qemu-nbd: pass structure into nbd_client_thread instead of plain char* has introduced a regression. struct NbdClientOpts resides on stack inside 'if' block. T

Re: [PATCH] migration: Allow user to specify migration available bandwidth

2023-07-26 Thread Peter Xu
On Tue, Jul 25, 2023 at 06:10:18PM +0100, Daniel P. Berrangé wrote: > On Tue, Jul 25, 2023 at 12:38:23PM -0400, Peter Xu wrote: > > I see you used "convergance" explicitly even after PeterM's reply, is that > > what you prefer over "convergence"? I do see more occurances of > > "convergence" as a

Re: [PATCH v10 08/10] migration: Implement MigrateChannelList to qmp migration flow.

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 02:18:31PM +, Het Gala wrote: > Integrate MigrateChannelList with all transport backends > (socket, exec and rdma) for both src and dest migration > endpoints for qmp migration. > > For current series, limit the size of MigrateChannelList > to single element (single int

[PULL v2 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

[PATCH 11/44] Introduce Raspberry PI 4 machine

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/arm/bcm2835_peripherals.c| 20 +++- hw/arm/bcm2836.c| 2 + hw/arm/bcm2838.c| 2 + hw/arm/meson.build | 2 +- hw/arm/raspi.c | 28 +++-- hw/arm/raspi4b.c| 182 +++

Re: [virtio-dev] [RFC PATCH] docs/interop: define STANDALONE protocol feature for vhost-user

2023-07-26 Thread Erik Schilling
On Tue Jul 4, 2023 at 4:54 PM CEST, Stefano Garzarella wrote: > On Tue, Jul 04, 2023 at 01:36:00PM +0100, Alex Bennée wrote: > >Currently QEMU has to know some details about the back-end to be able > >to setup the guest. While various parts of the setup can be delegated > >to the backend (for examp

Re: How to tame CI?

2023-07-26 Thread Juan Quintela
Daniel P. Berrangé wrote: > On Wed, Jul 26, 2023 at 02:00:03PM +0100, Peter Maydell wrote: >> 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-w

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

2023-07-26 Thread Richard Henderson
On 7/26/23 01:17, Ard Biesheuvel wrote: 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

Re: How to tame CI?

2023-07-26 Thread Thomas Huth
On 26/07/2023 15.00, Peter Maydell wrote: 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

[PATCH 44/44] Append added properties to mailbox test

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- tests/qtest/bcm2838-mbox-property-test.c | 82 1 file changed, 82 insertions(+) diff --git a/tests/qtest/bcm2838-mbox-property-test.c b/tests/qtest/bcm2838-mbox-property-test.c index e833529a00..68e2b11db6 100644 --- a/tests/qtest/bcm2

[PATCH v10 10/10] migration: modify test_multifd_tcp_none() to use new QAPI syntax.

2023-07-26 Thread Het Gala
modify multifd tcp common test to incorporate the new QAPI syntax defined. Suggested-by: Aravind Retnakaran Signed-off-by: Het Gala Reviewed-by: Daniel P. Berrangé --- tests/qtest/migration-test.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/qtest/migration-t

[PATCH v10 03/10] migration: convert socket backend to accept MigrateAddress

2023-07-26 Thread Het Gala
Socket transport backend for 'migrate'/'migrate-incoming' QAPIs accept new wire protocol of MigrateAddress struct. It is achived by parsing 'uri' string and storing migration parameters required for socket connection into well defined SocketAddress struct. Suggested-by: Aravind Retnakaran Signed

[PATCH 27/44] Add GENET register access macros

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- include/hw/net/bcm2838_genet.h | 76 ++ 1 file changed, 76 insertions(+) diff --git a/include/hw/net/bcm2838_genet.h b/include/hw/net/bcm2838_genet.h index 4b549ed431..bfe5e3ab31 100644 --- a/include/hw/net/bcm2838_genet.h +++ b/

Re: [PATCH] migration: Allow user to specify migration available bandwidth

2023-07-26 Thread Peter Xu
On Wed, Jul 26, 2023 at 08:21:35AM +0200, Markus Armbruster wrote: > Peter Xu writes: > > > Hi, Markus, > > > > On Tue, Jul 25, 2023 at 01:10:01PM +0200, Markus Armbruster wrote: > > [...] > > >> For better or worse, we duplicate full documentation between > >> MigrationParameter, MigrateSetPar

Re: [PATCH v10 09/10] migration: Implement MigrateChannelList to hmp migration flow.

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 02:18:32PM +, Het Gala wrote: > Integrate MigrateChannelList with all transport backends > (socket, exec and rdma) for both src and dest migration > endpoints for hmp migration. > > Suggested-by: Aravind Retnakaran > Signed-off-by: Het Gala > --- > migration/migratio

[PATCH 26/44] Add GENET register structs. Part 4

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- include/hw/net/bcm2838_genet.h | 40 ++ 1 file changed, 40 insertions(+) diff --git a/include/hw/net/bcm2838_genet.h b/include/hw/net/bcm2838_genet.h index 4cf70a17d3..4b549ed431 100644 --- a/include/hw/net/bcm2838_genet.h +++ b/

[PATCH 18/44] Add RNG200 RNG and RBG

2023-07-26 Thread Sergey Kambalin
Signed-off-by: Sergey Kambalin --- hw/misc/bcm2838_rng200.c | 218 ++- 1 file changed, 217 insertions(+), 1 deletion(-) diff --git a/hw/misc/bcm2838_rng200.c b/hw/misc/bcm2838_rng200.c index a17e8f2cda..bfc40658e2 100644 --- a/hw/misc/bcm2838_rng200.c +++ b/hw

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

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 02:18:29PM +, Het Gala wrote: > MigrateChannelList allows to connect accross multiple interfaces. > Add MigrateChannelList struct as argument to migration QAPIs. > > We plan to include multiple channels in future, to connnect > multiple interfaces. Hence, we choose 'Mig

[PATCH v10 07/10] migration: modify migration_channels_and_uri_compatible() for new QAPI syntax

2023-07-26 Thread Het Gala
migration_channels_and_uri_compatible() check for transport mechanism suitable for multifd migration gets executed when the caller calls old uri syntax. It needs it to be run when using the modern MigrateChannel QAPI syntax too. After URI -> 'MigrateChannel' : migration_channels_and_uri_compatible

[PATCH v10 00/10] migration: Modify 'migrate' and 'migrate-incoming' QAPI commands for migration

2023-07-26 Thread Het Gala
This is v10 patchset of modified 'migrate' and 'migrate-incoming' QAPI design for upstream review. Would like to thank all the maintainers that actively participated in the v9 patchset discussion and gave insightful suggestions to improve the patches. Link to previous upstream community patchset

Re: How to tame CI?

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 02:00:03PM +0100, Peter Maydell wrote: > 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 >

[PATCH v10 01/10] migration: New QAPI type 'MigrateAddress'

2023-07-26 Thread Het Gala
This patch introduces well defined MigrateAddress struct and its related child objects. The existing argument of 'migrate' and 'migrate-incoming' QAPI - 'uri' is of type string. The current implementation follows double encoding scheme for fetching migration parameters like 'uri' and this is not a

Re: How to tame CI?

2023-07-26 Thread Daniel P . Berrangé
On Wed, Jul 26, 2023 at 04:36:32PM +0200, Juan Quintela wrote: > Daniel P. Berrangé wrote: > > On Wed, Jul 26, 2023 at 02:00:03PM +0100, Peter Maydell wrote: > >> 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 > >

  1   2   3   >