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

2023-07-25 Thread Jeuk Kim
This patch includes the following tests Test mmio read Test ufs device initialization and ufs-lu recognition Test I/O (Performs a write followed by a read to verify) Signed-off-by: Jeuk Kim --- MAINTAINERS | 1 + tests/qtest/meson.build | 1 + tests/qtest/ufs-test.c | 575

[PATCH v7 2/4] hw/ufs: Support for Query Transfer Requests

2023-07-25 Thread Jeuk Kim
This commit makes the UFS device support query and nop out transfer requests. The next patch would be support for UFS logical unit and scsi command transfer request. Signed-off-by: Jeuk Kim --- hw/ufs/trace-events | 1 + hw/ufs/ufs.c| 980 +++-

[PATCH v7 3/4] hw/ufs: Support for UFS logical unit

2023-07-25 Thread Jeuk Kim
This commit adds support for ufs logical unit. The LU handles processing for the SCSI command, unit descriptor query request. This commit enables the UFS device to process IO requests. Signed-off-by: Jeuk Kim --- hw/ufs/lu.c | 1445 ++

[PATCH v7 1/4] hw/ufs: Initial commit for emulated Universal-Flash-Storage

2023-07-25 Thread Jeuk Kim
Universal Flash Storage (UFS) is a high-performance mass storage device with a serial interface. It is primarily used as a high-performance data storage device for embedded applications. This commit contains code for UFS device to be recognized as a UFS PCI device. Patches to handle UFS logical

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

2023-07-25 Thread Jeuk Kim
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 created a new file, tests/qtest/ufs-test.c, I added Laurent Vivier to the

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

2023-07-25 Thread dinglimin
>On Tue, 25 Jul 2023 at 10:13, Michael Tokarev wrote: > > > > 25.07.2023 12:00, dinglimin wrote: > > > Replaced a call to malloc() and its respective call to free() with > > > g_malloc() and g_free(). > > > > > > Signed-off-by: dinglimin > > > > > > V1 -> V2:if cpu_memory_rw_debug failed, still

[PATCH v2 5/6] qtest: irq_intercept_[out/in]: return FAIL if no intercepts are installed

2023-07-25 Thread Chris Laplante
This is much better than just silently failing with OK. Signed-off-by: Chris Laplante Reviewed-by: Peter Maydell --- softmmu/qtest.c | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/softmmu/qtest.c b/softmmu/qtest.c index 1719bbddc3..c9751f527f 100644 ---

[PATCH v2 4/6] qtest: bail from irq_intercept_in if name is specified

2023-07-25 Thread Chris Laplante
Named interception of in-GPIOs is not supported yet. Signed-off-by: Chris Laplante Reviewed-by: Peter Maydell --- softmmu/qtest.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/softmmu/qtest.c b/softmmu/qtest.c index 7fd8546ed2..1719bbddc3 100644 ---

[PATCH v2 1/6] hw/gpio/nrf51: implement DETECT signal

2023-07-25 Thread Chris Laplante
Implement nRF51 DETECT signal in the GPIO peripheral. The reference manual makes mention of a per-pin DETECT signal, but these are not exposed to the user. See https://devzone.nordicsemi.com/f/nordic-q-a/39858/gpio-per-pin-detect-signal-available for more information. Currently, I don't see a

[PATCH v2 6/6] qtest: microbit-test: add tests for nRF51 DETECT

2023-07-25 Thread Chris Laplante
Exercise the DETECT mechanism of the GPIO peripheral. Signed-off-by: Chris Laplante Reviewed-by: Peter Maydell --- tests/qtest/microbit-test.c | 42 + 1 file changed, 42 insertions(+) diff --git a/tests/qtest/microbit-test.c b/tests/qtest/microbit-test.c

[PATCH v2 0/6] Add nRF51 DETECT signal with test

2023-07-25 Thread Chris Laplante
This patch series implements the nRF51 DETECT signal in the GPIO peripheral. A qtest is added exercising the signal. To implement the test, named out-GPIO IRQ interception had to be added to the qtest framework. I also took the opportunity to improve IRQ interception a bit by adding 'FAIL'

[PATCH v2 2/6] qtest: factor out qtest_install_gpio_out_intercept

2023-07-25 Thread Chris Laplante
Signed-off-by: Chris Laplante --- softmmu/qtest.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/softmmu/qtest.c b/softmmu/qtest.c index f8d764b719..1c92e5a6a3 100644 --- a/softmmu/qtest.c +++ b/softmmu/qtest.c @@ -365,6 +365,15 @@ void

[PATCH v2 3/6] qtest: implement named interception of out-GPIO

2023-07-25 Thread Chris Laplante
Adds qtest_irq_intercept_out_named method, which utilizes a new optional name parameter to the irq_intercept_out qtest command. Signed-off-by: Chris Laplante --- softmmu/qtest.c| 24 tests/qtest/libqtest.c | 6 ++ tests/qtest/libqtest.h | 11 +++ 3

Re: [PULL 10/10] target/tricore: Rename tricore_feature

2023-07-25 Thread Michael Tokarev
25.07.2023 22:11, Bastian Koppelmann wrote: ... Michael Tokarev has already picked it up. See https://lore.kernel.org/qemu-devel/20230725145829.37782-11-phi...@linaro.org/T/#u I noticed that too, we did it almost at the same time. But there's nothing wrong with that. It doesn't matter how a

Re: [PATCH 0/6] Add nRF51 DETECT signal with test

2023-07-25 Thread Chris Laplante
> > 2. I also have some implementations for pieces of CLOCK, namely the > > HFCLKSTART/HFCLKSTOP events and HFCLKSTARTED event. Should I include that > > in this patch series, or would you prefer it in a separate series? It is > > unrelated to DETECT and POWER. > > > If you think they're

Re: [PATCH v2 3/4] vdpa: Restore vlan filtering state

2023-07-25 Thread Jason Wang
On Tue, Jul 25, 2023 at 3:48 PM Hawkins Jiawei wrote: > > On 2023/7/25 14:47, Jason Wang wrote: > > On Sun, Jul 23, 2023 at 5:28 PM Hawkins Jiawei wrote: > >> > >> This patch introduces vhost_vdpa_net_load_single_vlan() > >> and vhost_vdpa_net_load_vlan() to restore the vlan > >> filtering state

[ANNOUNCE] QEMU 8.1.0-rc1 is now available

2023-07-25 Thread Michael Roth
Hello, On behalf of the QEMU Team, I'd like to announce the availability of the second release candidate for the QEMU 8.1 release. This release is meant for testing purposes and should not be used in a production environment. http://download.qemu.org/qemu-8.1.0-rc1.tar.xz

Re: [PATCH] vdpa: set old virtio status at cvq isolation probing end

2023-07-25 Thread Jason Wang
On Wed, Jul 26, 2023 at 2:21 AM Eugenio Pérez wrote: > > The device already has a virtio status set by vhost_vdpa_init by the > time vhost_vdpa_probe_cvq_isolation is called. vhost_vdpa_init set > S_ACKNOWLEDGE and S_DRIVER, so it is invalid to just reset it. > > It is invalid to start the device

Re: [PATCH v1 0/9] gfxstream + rutabaga_gfx

2023-07-25 Thread Gurchetan Singh
On Mon, Jul 24, 2023 at 2:56 AM Alyssa Ross wrote: > > Gurchetan Singh writes: > > > In terms of API stability/versioning/packaging, once this series is > > reviewed, the plan is to cut a "gfxstream upstream release branch". We > > will have the same API guarantees as any other QEMU project

[PATCH v2 5/8] hw/arm/virt: Unsupported host CPU model on TCG

2023-07-25 Thread Gavin Shan
The 'host' CPU model isn't supported until KVM or HVF is enabled. For example, the following error messages are seen when the guest is started with option '-cpu cortex-a8'. qemu-system-aarch64: Invalid CPU type: cortex-a8-arm-cpu The valid models are: cortex-a7, cortex-a15, cortex-a35,

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

2023-07-25 Thread Gavin Shan
The supported CPU models instead of typenames should be printed when the user specified CPU type isn't supported in is_cpu_type_supported(), to be consistent with the CPU model specified by user through '-cpu ' option. Correct the error messages to print CPU models, maintained in the newly added

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

2023-07-25 Thread Gavin Shan
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 to @mc to avoid multiple line

[PATCH v2 7/8] hw/arm: Check CPU type in machine_run_board_init()

2023-07-25 Thread Gavin Shan
Set mc->valid_cpu_{types, models} so that the specified CPU type can be checked in machine_run_board_init(). We needn't to do the check by ourselves. Signed-off-by: Gavin Shan --- hw/arm/bananapi_m2u.c | 18 +++-- hw/arm/cubieboard.c | 18 +++-- hw/arm/mps2-tz.c

[PATCH v2 1/8] machine: Use error handling when CPU type is checked

2023-07-25 Thread Gavin Shan
QEMU will be terminated if the specified CPU type isn't supported in machine_run_board_init(). The list of supported CPU type is maintained in mc->valid_cpu_types. The error handling can be used to propagate error messages, to be consistent how the errors are handled for other situations in the

[PATCH v2 6/8] hw/arm/sbsa-ref: Check CPU type in machine_run_board_init()

2023-07-25 Thread Gavin Shan
Set mc->valid_cpu_{types, models} so that the specified CPU type can be checked in machine_run_board_init(). We needn't to do the check by ourselves. Signed-off-by: Gavin Shan --- hw/arm/sbsa-ref.c | 29 - 1 file changed, 12 insertions(+), 17 deletions(-) diff --git

[PATCH v2 8/8] hw/riscv/shakti_c: Check CPU type in machine_run_board_init()

2023-07-25 Thread Gavin Shan
Set mc->valid_cpu_{types, models} so that the specified CPU type can be checked in machine_run_board_init(). We needn't to do the check by ourselves. Signed-off-by: Gavin Shan --- hw/riscv/shakti_c.c | 17 +++-- 1 file changed, 11 insertions(+), 6 deletions(-) diff --git

[PATCH v2 4/8] hw/arm/virt: Check CPU type in machine_run_board_init()

2023-07-25 Thread Gavin Shan
Set mc->valid_cpu_{types, models} so that the specified CPU type can be checked in machine_run_board_init(). We needn't to do the check by ourselves. Signed-off-by: Gavin Shan --- hw/arm/virt.c | 39 ++- 1 file changed, 22 insertions(+), 17 deletions(-) diff

[PATCH v2 0/8] machine: Unified CPU type check

2023-07-25 Thread Gavin Shan
There are two places where the user specified CPU type is checked to see if it's supported or allowed by the board: machine_run_board_init() and mc->init(). We don't have to maintain two duplicate sets of logic. This series intends to move the check to machine_run_board_init(). PATCH[1-3]

Re: [PATCH for-8.2 1/3] target/arm: Do all "ARM_FEATURE_X implies Y" checks in post_init

2023-07-25 Thread Richard Henderson
On 7/24/23 10:43, Peter Maydell wrote: Where architecturally one ARM_FEATURE_X flag implies another ARM_FEATURE_Y, we allow the CPU init function to only set X, and then set Y for it. Currently we do this in two places -- we set a few flags in arm_cpu_post_init() because we need them to decide

Re: [RFC PATCH] vfio-user: add live migration to vfio-user protocol specification

2023-07-25 Thread Stefan Hajnoczi
On Tue, 18 Jul 2023 at 05:42, William Henderson wrote: > > This patch adds live migration to the vfio-user specification, based on the > new > VFIO migration interface introduced in the kernel here: > > https://lore.kernel.org/all/20220224142024.147653-10-yish...@nvidia.com/ Hi, This is not an

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

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

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

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

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

2023-07-25 Thread Het Gala
Sorry, last reply on this patch was accidently replied only to Daniel. Pasting the reply again so it is received by all the active maintianers here. Apologies for the error  On 26/07/23 12:07 am, Daniel P. Berrangé wrote: On Tue, Jul 25, 2023 at 07:34:09PM +0100, Daniel P. Berrangé wrote:

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

2023-07-25 Thread Het Gala
On 26/07/23 12:45 am, Daniel P. Berrangé wrote: On Fri, Jul 21, 2023 at 02:49:35PM +, 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

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

2023-07-25 Thread Het Gala
On 26/07/23 12:08 am, Daniel P. Berrangé wrote: On Fri, Jul 21, 2023 at 02:49:34PM +, 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

Re: [PATCH] block/blkio: enable the completion eventfd

2023-07-25 Thread Stefan Hajnoczi
On Tue, Jul 25, 2023 at 12:37:44PM +0200, Stefano Garzarella wrote: > Until libblkio 1.3.0, virtio-blk drivers had completion eventfd > notifications enabled from the start, but from the next releases > this is no longer the case, so we have to explicitly enable them. > > In fact, the libblkio

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

2023-07-25 Thread Het Gala
On 26/07/23 12:07 am, Daniel P. Berrangé wrote: On Tue, Jul 25, 2023 at 07:34:09PM +0100, Daniel P. Berrangé wrote: On Fri, Jul 21, 2023 at 02:49:31PM +, Het Gala wrote: MigrateChannelList allows to connect accross multiple interfaces. Add MigrateChannelList struct as argument to

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

2023-07-25 Thread Daniel P . Berrangé
On Fri, Jul 21, 2023 at 02:49:37PM +, Het Gala wrote: > modify multifd tcp common test to incorporate the new QAPI > syntax defined. > > Suggested-by: Aravind Retnakaran > Signed-off-by: Het Gala > --- > tests/qtest/migration-test.c | 7 ++- > 1 file changed, 6 insertions(+), 1

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

2023-07-25 Thread Daniel P . Berrangé
On Fri, Jul 21, 2023 at 02:49:35PM +, 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 > --- >

Re: [PULL 10/10] target/tricore: Rename tricore_feature

2023-07-25 Thread Bastian Koppelmann
Hi Phil, On Tue, Jul 25, 2023 at 04:58:29PM +0200, Philippe Mathieu-Daudé wrote: > From: Bastian Koppelmann > > this name is used by capstone and will lead to a build failure of QEMU, > when capstone is enabled. So we rename it to tricore_has_feature(), to > match has_feature() in translate.c.

Re: [PULL 0/2] Misc next patches

2023-07-25 Thread Peter Maydell
On Tue, 25 Jul 2023 at 17:26, Daniel P. Berrangé wrote: > > The following changes since commit a279ca4ea07383314b2d2b2f1d550be9482f148e: > > Merge tag 'pull-target-arm-20230725' of > https://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-07-25 > 12:44:39 +0100)

Re: [PULL 0/8] trivial-patches 25-07-2023

2023-07-25 Thread Peter Maydell
On Tue, 25 Jul 2023 at 15:57, Michael Tokarev wrote: > > The following changes since commit 3ee44ec72753ec0ff05ad1569dfa609203d722b2: > > Merge tag 'pull-request-2023-07-24' of https://gitlab.com/thuth/qemu into > staging (2023-07-24 18:06:36 +0100) > > are available in the Git repository at:

Re: [PULL 00/10] Misc fixes for 2023-07-25

2023-07-25 Thread Peter Maydell
available in the Git repository at: > > https://github.com/philmd/qemu.git tags/misc-fixes-20230725 > > for you to fetch changes up to f8cfdd2038c1823301e6df753242e465b1dc8539: > > target/tricore: Rename tricore_feature (2023-07-25 14:42:00 +0200) > > --

Re: [PATCH v3 0/8] misc AHCI cleanups

2023-07-25 Thread John Snow
On Tue, Jul 25, 2023 at 9:04 AM Philippe Mathieu-Daudé wrote: > > Hi Niklas, John, Paolo, Kevin, > > On 19/7/23 12:47, Niklas Cassel wrote: > > >> Niklas Cassel (8): > >>hw/ide/ahci: remove stray backslash > >>hw/ide/core: set ERR_STAT in unsupported command completion > >>

Re: [RFC] risc-v vector (RVV) emulation performance issues

2023-07-25 Thread Richard Henderson
On 7/24/23 06:40, Daniel Henrique Barboza wrote: Hi, As some of you are already aware the current RVV emulation could be faster. We have at least one commit (bc0ec52eb2, "target/riscv/vector_helper.c: skip set tail when vta is zero") that tried to address at least part of the problem. Running

Re: [PATCH 3/6] vhost: Do not reset suspended devices on stop

2023-07-25 Thread Eugenio Perez Martin
On Tue, Jul 25, 2023 at 3:09 PM Hanna Czenczek wrote: > > On 25.07.23 12:03, Eugenio Perez Martin wrote: > > On Tue, Jul 25, 2023 at 9:53 AM Hanna Czenczek wrote: > >> On 24.07.23 17:48, Eugenio Perez Martin wrote: > >>> On Fri, Jul 21, 2023 at 6:07 PM Hanna Czenczek wrote: > On 21.07.23

[Qemu PATCH v2 2/9] hw/cxl/cxl-mailbox-utils: Add dynamic capacity region representative and mailbox command support

2023-07-25 Thread Fan Ni
From: Fan Ni Per cxl spec 3.0, add dynamic capacity region representative based on Table 8-126 and extend the cxl type3 device definition to include dc region information. Also, based on info in 8.2.9.8.9.1, add 'Get Dynamic Capacity Configuration' mailbox support. Signed-off-by: Fan Ni ---

[Qemu PATCH v2 9/9] hw/mem/cxl_type3: Add dpa range validation for accesses to dc regions

2023-07-25 Thread Fan Ni
From: Fan Ni Not all dpa range in the dc regions is valid to access until an extent covering the range has been added. Add a bitmap for each region to record whether a dc block in the region has been backed by dc extent. For the bitmap, a bit in the bitmap represents a dc block. When a dc extent

[Qemu PATCH v2 3/9] include/hw/cxl/cxl_device: Rename mem_size as static_mem_size for type3 memory devices

2023-07-25 Thread Fan Ni
From: Fan Ni Rename mem_size as static_mem_size for type3 memdev to cover static RAM and pmem capacity, preparing for the introduction of dynamic capacity to support dynamic capacity devices. Signed-off-by: Fan Ni --- hw/cxl/cxl-mailbox-utils.c | 5 +++-- hw/mem/cxl_type3.c | 8

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

2023-07-25 Thread Fan Ni
From: Fan Ni Add (file/memory backed) host backend, all the dynamic capacity regions will share a single, large enough host backend. Set up address space for DC regions to support read/write operations to dynamic capacity for DCD. With the change, following supports are added: 1. add a new

[Qemu PATCH v2 8/9] hw/cxl/events: Add qmp interfaces to add/release dynamic capacity extents

2023-07-25 Thread Fan Ni
From: Fan Ni Since fabric manager emulation is not supported yet, the change implements the functions to add/release dynamic capacity extents as QMP interfaces. 1. Add dynamic capacity extents: For example, the command to add two continuous extents (each is 128MB long) to region 0 (starting at

[Qemu PATCH v2 0/9] Enabling DCD emulation support in Qemu

2023-07-25 Thread Fan Ni
v1[1]->v2: 1. fix a regression issue reported by Ira[2]: 2. fix a compile warning due to uninitialized 'rip' in qmp processing function. [1] https://lore.kernel.org/linux-cxl/20230724162313.34196-1-fan...@samsung.com/T/#t [2]

[Qemu PATCH v2 7/9] hw/cxl/cxl-mailbox-utils: Add mailbox commands to support add/release dynamic capacity response

2023-07-25 Thread Fan Ni
From: Fan Ni Per CXL spec 3.0, two mailbox commands are implemented: Add Dynamic Capacity Response (Opcode 4802h) 8.2.9.8.9.3, and Release Dynamic Capacity (Opcode 4803h) 8.2.9.8.9.4. Signed-off-by: Fan Ni --- hw/cxl/cxl-mailbox-utils.c | 253

[Qemu PATCH v2 6/9] hw/mem/cxl_type3: Add DC extent list representative and get DC extent list mailbox support

2023-07-25 Thread Fan Ni
From: Fan Ni Add dynamic capacity extent list representative to the definition of CXLType3Dev and add get DC extent list mailbox command per CXL.spec.3.0:.8.2.9.8.9.2. Signed-off-by: Fan Ni --- hw/cxl/cxl-mailbox-utils.c | 71 + hw/mem/cxl_type3.c

[Qemu PATCH v2 1/9] hw/cxl/cxl-mailbox-utils: Add dc_event_log_size field to output payload of identify memory device command

2023-07-25 Thread Fan Ni
From: Fan Ni Based on CXL spec 3.0 Table 8-94 (Identify Memory Device Output Payload), dynamic capacity event log size should be part of output of the Identify command. Add dc_event_log_size to the output payload for the host to get the info. Signed-off-by: Fan Ni ---

[Qemu PATCH v2 4/9] hw/mem/cxl_type3: Add support to create DC regions to type3 memory devices

2023-07-25 Thread Fan Ni
From: Fan Ni With the change, when setting up memory for type3 memory device, we can create DC regions A property 'num-dc-regions' is added to ct3_props to allow users to pass the number of DC regions to create. To make it easier, other region parameters like region base, length, and block size

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

2023-07-25 Thread Daniel P . Berrangé
On Fri, Jul 21, 2023 at 02:49:34PM +, 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

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 07:34:09PM +0100, Daniel P. Berrangé wrote: > On Fri, Jul 21, 2023 at 02:49:31PM +, Het Gala wrote: > > MigrateChannelList allows to connect accross multiple interfaces. > > Add MigrateChannelList struct as argument to migration QAPIs. > > > > We plan to include

Re: [PATCH v2 6/6] python/machine: remove unused sock_dir argument

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:33:36PM -0400, John Snow wrote: > On Tue, Jul 25, 2023 at 2:26 PM Daniel P. Berrangé > wrote: > > > > On Tue, Jul 25, 2023 at 02:03:37PM -0400, John Snow wrote: > > > By using a socketpair for all of the sockets managed by the VM class and > > > its extensions, we

Re: [PATCH 06/14] target/arm/ptw: Pass an ARMSecuritySpace to arm_hcr_el2_eff_secstate()

2023-07-25 Thread Richard Henderson
On 7/24/23 07:38, Peter Maydell wrote: Does it? HCR_EL2 says "behaves as 0 if EL2 is not enabled in the current Security state". If the current Security state is Root then EL2 isn't enabled (because there's no such thing as EL2 Root), so the function should return 0, shouldn't it? I guess

Re: [PATCH v2 6/6] python/machine: remove unused sock_dir argument

2023-07-25 Thread John Snow
On Tue, Jul 25, 2023 at 2:26 PM Daniel P. Berrangé wrote: > > On Tue, Jul 25, 2023 at 02:03:37PM -0400, John Snow wrote: > > By using a socketpair for all of the sockets managed by the VM class and > > its extensions, we don't need the sock_dir argument anymore, so remove > > it. > > > > We only

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

2023-07-25 Thread Daniel P . Berrangé
On Fri, Jul 21, 2023 at 02:49:31PM +, 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

Re: [PATCH v2 6/6] python/machine: remove unused sock_dir argument

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:37PM -0400, John Snow wrote: > By using a socketpair for all of the sockets managed by the VM class and > its extensions, we don't need the sock_dir argument anymore, so remove > it. > > We only added this argument so that we could specify a second, shorter >

Re: [PATCH v2 5/6] python/machine: use socketpair() for qtest connection

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:36PM -0400, John Snow wrote: > Like the QMP and console sockets, begin using socketpairs for the qtest > connection, too. After this patch, we'll be able to remove the vestigial > sock_dir argument, but that cleanup is best done in its own patch. > > Signed-off-by:

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

2023-07-25 Thread Fabiano Rosas
Fabiano Rosas writes: > Peter Xu writes: > >> v2: >> - Patch "migration: Provide explicit error message for file shutdowns" >> - Touched up qapi doc [Fabiano] >> - Added Bugzilla link to commit which I didn't even notice that I was >> fixing a bug.. but rightfully pointed out by Laszlo.

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:35PM -0400, John Snow wrote: > Create a socketpair for the console output. This should help eliminate > race conditions around console text early in the boot process that might > otherwise have been dropped on the floor before being able to connect to > QEMU under

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:34PM -0400, John Snow wrote: > Useful if we want to use ConsoleSocket() for a socket created by > socketpair(). > > Signed-off-by: John Snow > --- > python/qemu/machine/console_socket.py | 29 +++ > 1 file changed, 21 insertions(+), 8

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:33PM -0400, John Snow wrote: > If everything has gone smoothly, we'll already have closed the socket we > gave to the child during post_launch. The other half of the pair that we > gave to the QMP connection should, likewise, be definitively closed by > now. > >

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 02:03:32PM -0400, John Snow wrote: > This property isn't meant to do much else besides return a list of > strings, so move this setup back out into _pre_launch(). > > Signed-off-by: John Snow > --- > python/qemu/machine/machine.py | 5 ++--- > 1 file changed, 2

Re: [PATCH v6 4/6] qapi: Add HvBalloonDeviceInfo sub-type to MemoryDeviceInfo

2023-07-25 Thread Maciej S. Szmigiero
On 25.07.2023 10:25, Markus Armbruster wrote: "Maciej S. Szmigiero" writes: From: "Maciej S. Szmigiero" Used by the hv-balloon driver to report its provided memory state information. Co-developed-by: David Hildenbrand Signed-off-by: Maciej S. Szmigiero --- hw/core/machine-hmp-cmds.c |

Re: [PATCH v6 5/6] qapi: Add HV_BALLOON_STATUS_REPORT event

2023-07-25 Thread Maciej S. Szmigiero
On 25.07.2023 10:04, Markus Armbruster wrote: "Maciej S. Szmigiero" writes: From: "Maciej S. Szmigiero" Used by the hv-balloon driver for (optional) guest memory status reports. Inhowfar optional? What enables / triggers it? They are enabled by "status-report=on" device property, hence

Re: [PATCH v6 0/6] Hyper-V Dynamic Memory Protocol driver (hv-balloon ️)

2023-07-25 Thread David Hildenbrand
That commit would be called something like "pc: Support hv-balloon". If I remove the driver from Kconfig in the initial patch then AFAIK this initial patch will add a dead driver file that it is not possible to build yet, right? Yes, that's also what we did for virtio-mem: (bottom to top)

Re: [PATCH v6 0/6] Hyper-V Dynamic Memory Protocol driver (hv-balloon ️)

2023-07-25 Thread Maciej S. Szmigiero
On 24.07.2023 16:42, David Hildenbrand wrote: On 20.07.23 12:12, Maciej S. Szmigiero wrote: From: "Maciej S. Szmigiero" This is a continuation of the v5 of the patch series located here: https://lore.kernel.org/qemu-devel/cover.1686577753.git.maciej.szmigi...@oracle.com/ We're now in QEMU

[PATCH v2 0/6] python/machine: use socketpair() for console socket

2023-07-25 Thread John Snow
Like we did for the QMP socket, use socketpair() for the console socket so that hopefully there isn't a race condition during early boot where data might get dropped on the floor. May or may not help with various race conditions where early console output is not showing up in the logs and/or

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

2023-07-25 Thread John Snow
Create a socketpair for the console output. This should help eliminate race conditions around console text early in the boot process that might otherwise have been dropped on the floor before being able to connect to QEMU under "server,nowait". Signed-off-by: John Snow ---

[PATCH v2 6/6] python/machine: remove unused sock_dir argument

2023-07-25 Thread John Snow
By using a socketpair for all of the sockets managed by the VM class and its extensions, we don't need the sock_dir argument anymore, so remove it. We only added this argument so that we could specify a second, shorter temporary directory for cases where the temp/log dirs were "too long" as a

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

2023-07-25 Thread John Snow
If everything has gone smoothly, we'll already have closed the socket we gave to the child during post_launch. The other half of the pair that we gave to the QMP connection should, likewise, be definitively closed by now. However, in the cleanup path, it's possible we've created the socketpair

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

2023-07-25 Thread John Snow
This property isn't meant to do much else besides return a list of strings, so move this setup back out into _pre_launch(). Signed-off-by: John Snow --- python/qemu/machine/machine.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/python/qemu/machine/machine.py

[PATCH v2 5/6] python/machine: use socketpair() for qtest connection

2023-07-25 Thread John Snow
Like the QMP and console sockets, begin using socketpairs for the qtest connection, too. After this patch, we'll be able to remove the vestigial sock_dir argument, but that cleanup is best done in its own patch. Signed-off-by: John Snow --- python/qemu/machine/qtest.py | 49

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

2023-07-25 Thread John Snow
Useful if we want to use ConsoleSocket() for a socket created by socketpair(). Signed-off-by: John Snow --- python/qemu/machine/console_socket.py | 29 +++ 1 file changed, 21 insertions(+), 8 deletions(-) diff --git a/python/qemu/machine/console_socket.py

[PATCH] softmmu/vl: improve select_machine() function

2023-07-25 Thread Vladimir Sementsov-Ogievskiy
- put machine name into error message (helps debugging CI) - fix style (over-80 lines) - use g_autoptr - drop extra error propagation Signed-off-by: Vladimir Sementsov-Ogievskiy --- softmmu/vl.c | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git

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

2023-07-25 Thread Vladimir Sementsov-Ogievskiy
From: Vladimir Sementsov-Ogievskiy Actually block job is not completed without this final flush. It's rather unexpected to have broken target when job was successfully completed long ago and now we fail to flush or process just crashed/killed. Signed-off-by: Vladimir Sementsov-Ogievskiy ---

avocado test failing INTERRUPTED for "Missing asset"

2023-07-25 Thread Peter Maydell
Currently this CI job is failing: https://gitlab.com/qemu-project/qemu/-/jobs/4737819946 because: (05/59) tests/avocado/boot_linux_console.py:BootLinuxConsole.test_arm_exynos4210_initrd: INTERRUPTED: Missing asset

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

2023-07-25 Thread Daniel P . Berrangé
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 word in migration context, though. Ignore my speling erors :-) >

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

2023-07-25 Thread Peter Xu
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, but I'd suggest you repost with a whole patch

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

2023-07-25 Thread Sunil V L
On Mon, Jul 24, 2023 at 05:18:59PM +0200, Igor Mammedov wrote: > On Wed, 12 Jul 2023 22:09:34 +0530 > Sunil V L wrote: > > > The functions which add fw_cfg and virtio to DSDT are same for ARM > > and RISC-V. So, instead of duplicating in RISC-V, move them from > > hw/arm/virt-acpi-build.c to

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

2023-07-25 Thread Fan Ni
On Tue, Jul 25, 2023 at 08:18:08AM -0700, Ira Weiny wrote: > Fan Ni wrote: > > On Thu, May 11, 2023 at 05:56:40PM +, Fan Ni wrote: > > > > FYI. > > > > I have updated the patch series and sent out again. > > > > I suggested anyone who are interested in DCD and using this patch series to >

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

2023-07-25 Thread Peter Maydell
There seems to be an intermittent failure on the s390 host in the qemu:block / io-qcow2-copy-before-write test: https://gitlab.com/qemu-project/qemu/-/jobs/4737819873 The log says the test was expecting to do some reading and writing but got an unexpected 'permission denied' error on the read.

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

2023-07-25 Thread Peter Xu
Hi, Markus, On Tue, Jul 25, 2023 at 01:10:01PM +0200, Markus Armbruster wrote: > Peter Xu writes: > > > Migration bandwidth is a very important value to live migration. It's > > because it's one of the major factors that we'll make decision on when to > > switchover to destination in a precopy

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

2023-07-25 Thread Vladimir Sementsov-Ogievskiy
On 25.07.23 18:13, Denis V. Lunev wrote: On 7/25/23 16:25, Vladimir Sementsov-Ogievskiy wrote: On 24.07.23 10:30, Evanzhang wrote: block_stream will not actively flush l2_table_cache,when qemu process exception exit,causing disk data loss Signed-off-by: Evanzhang ---   block/stream.c | 6

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

2023-07-25 Thread Peter Xu
On Tue, Jul 25, 2023 at 05:09:57PM +0100, Daniel P. Berrangé wrote: > On Tue, Jul 25, 2023 at 11:54:52AM -0400, Peter Xu wrote: > > We can make the semantics specific, no strong opinion here. I wished it > > can be as generic / easy as possible but maybe I went too far. > > > > Though, is there

Re: [PATCH v2] kvm: Remove KVM_CREATE_IRQCHIP support assumption

2023-07-25 Thread Daniel Henrique Barboza
On 7/25/23 09:26, Andrew Jones wrote: Since Linux commit 00f918f61c56 ("RISC-V: KVM: Skeletal in-kernel AIA irqchip support") checking KVM_CAP_IRQCHIP returns non-zero when the RISC-V platform has AIA. The cap indicates KVM supports at least one of the following ioctls: KVM_CREATE_IRQCHIP

[PULL 1/2] crypto: Always initialize splitkeylen

2023-07-25 Thread Daniel P . Berrangé
From: Akihiko Odaki When _FORTIFY_SOURCE=2, glibc version is 2.35, and GCC version is 12.1.0, the compiler complains as follows: In file included from /usr/include/string.h:535, from /home/alarm/q/var/qemu/include/qemu/osdep.h:99, from

[PULL 0/2] Misc next patches

2023-07-25 Thread Daniel P . Berrangé
The following changes since commit a279ca4ea07383314b2d2b2f1d550be9482f148e: Merge tag 'pull-target-arm-20230725' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-07-25 12:44:39 +0100) are available in the Git repository at: https://gitlab.com/berrange/qemu tags/misc

[PULL 0/2] Misc next patches

2023-07-25 Thread Daniel P . Berrangé
The following changes since commit a279ca4ea07383314b2d2b2f1d550be9482f148e: Merge tag 'pull-target-arm-20230725' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2023-07-25 12:44:39 +0100) are available in the Git repository at: https://gitlab.com/berrange/qemu tags/misc

[PULL 1/2] crypto: Always initialize splitkeylen

2023-07-25 Thread Daniel P . Berrangé
From: Akihiko Odaki When _FORTIFY_SOURCE=2, glibc version is 2.35, and GCC version is 12.1.0, the compiler complains as follows: In file included from /usr/include/string.h:535, from /home/alarm/q/var/qemu/include/qemu/osdep.h:99, from

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

2023-07-25 Thread ThinerLogoer
At 2023-07-25 19:42:30, "David Hildenbrand" wrote: >Hi, > >patch subject should start with "softmmu/physmem: Open ..." Sorry I am newbie to the patch submission part. I will resubmit a version of patch if the final acceptable patch after discussion is mostly the same. (For example, if this

Re: [PATCH v4 06/12] virtio-sound: handle VIRTIO_SND_R_PCM_INFO request

2023-07-25 Thread Michael S. Tsirkin
On Tue, Jul 25, 2023 at 06:54:56PM +0400, Marc-André Lureau wrote: > > Marc-André can you please stop with trying to use gmail web client? > > > Trying? I think I have almost exclusively used it over the past 15y or so :) >   Then find a way make it not wrap lines. The result of corrupted

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

2023-07-25 Thread Daniel P . Berrangé
On Tue, Jul 25, 2023 at 11:54:52AM -0400, Peter Xu wrote: > We can make the semantics specific, no strong opinion here. I wished it > can be as generic / easy as possible but maybe I went too far. > > Though, is there anything else we can choose from besides > "max-convergence-bandwidth"? Or am

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

2023-07-25 Thread Peter Xu
On Tue, Jul 25, 2023 at 10:16:52AM +0100, Daniel P. Berrangé wrote: > On Mon, Jul 24, 2023 at 03:47:50PM -0400, Peter Xu wrote: > > On Mon, Jul 24, 2023 at 07:04:29PM +0100, Daniel P. Berrangé wrote: > > > On Mon, Jul 24, 2023 at 01:07:55PM -0400, Peter Xu wrote: > > > > Migration bandwidth is a

  1   2   3   >