Re: [PATCH v23 09/20] machine: adding s390 topology to query-cpu-fast

2023-09-20 Thread Markus Armbruster
Nina Schoetterl-Glausch writes: > From: Pierre Morel > > S390x provides two more topology attributes, entitlement and dedication. > > Let's add these CPU attributes to the QAPI command query-cpu-fast. > > Signed-off-by: Pierre Morel > Reviewed-by: Nina Schoetterl-Glausch > Co-developed-by: Nin

Re: [PATCH v6 0/3] hw/{i2c,nvme}: mctp endpoint, nvme management interface model

2023-09-20 Thread Jonathan Cameron via
On Thu, 14 Sep 2023 11:53:40 +0200 Klaus Jensen wrote: > This adds a generic MCTP endpoint model that other devices may derive > from. > > Also included is a very basic implementation of an NVMe-MI device, > supporting only a small subset of the required commands. > > Since this all relies on i

Re: [PATCH v1 05/22] vfio/common: Extract out vfio_kvm_device_[add/del]_fd

2023-09-20 Thread Eric Auger
Hi Zhenzhong, On 8/30/23 12:37, Zhenzhong Duan wrote: > ...which will be used by both legacy and iommufd backend. I prefer genuine sentences in the commit msg. Also you explain what you do but not why. suggestion: Introduce two new helpers, vfio_kvm_device_[add/del]_fd which take as input a file

Re: [PATCH v23 11/20] qapi/s390x/cpu topology: CPU_POLARIZATION_CHANGE qapi event

2023-09-20 Thread Markus Armbruster
Nina Schoetterl-Glausch writes: > From: Pierre Morel > > When the guest asks to change the polarization this change > is forwarded to the upper layer using QAPI. > The upper layer is supposed to take according decisions concerning > CPU provisioning. > > Signed-off-by: Pierre Morel > Reviewed-b

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

2023-09-20 Thread Markus Armbruster
Nina Schoetterl-Glausch writes: > From: Pierre Morel > > The query-cpu-polarization qmp command returns the current > CPU polarization of the machine. > > Signed-off-by: Pierre Morel > Reviewed-by: Thomas Huth > Reviewed-by: Nina Schoetterl-Glausch > Co-developed-by: Nina Schoetterl-Glausch

Re: [PATCH v13 6/9] gfxstream + rutabaga: add initial support for gfxstream

2023-09-20 Thread Mark Cave-Ayland
On 20/09/2023 12:42, Akihiko Odaki wrote: On 2023/08/29 9:36, Gurchetan Singh wrote: This adds initial support for gfxstream and cross-domain.  Both features rely on virtio-gpu blob resources and context types, which are also implemented in this patch. gfxstream has a long and illustrious hist

Re: [PATCH v2 1/1] migration: skip poisoned memory pages on "ram saving" phase

2023-09-20 Thread William Roche
Thank you Zhijian for your feedback. So I'll try to push this change today. Cheers, William. On 9/20/23 12:04, Zhijian Li (Fujitsu) wrote: On 15/09/2023 19:31, William Roche wrote: On 9/15/23 05:13, Zhijian Li (Fujitsu) wrote: I'm okay with "RDMA isn't touched". BTW, could you share you

[Stable-7.2.6 52/63] virtio: Drop out of coroutine context in virtio_load()

2023-09-20 Thread Michael Tokarev
From: Kevin Wolf virtio_load() as a whole should run in coroutine context because it reads from the migration stream and we don't want this to block. However, it calls virtio_set_features_nocheck() and devices don't expect their .set_features callback to run in a coroutine and therefore call fun

[Stable-7.2.6 57/63] linux-user/riscv: Use abi type for target_ucontext

2023-09-20 Thread Michael Tokarev
From: LIU Zhiwei We should not use types dependend on host arch for target_ucontext. This bug is found when run rv32 applications. Signed-off-by: LIU Zhiwei Reviewed-by: Richard Henderson Reviewed-by: Daniel Henrique Barboza Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20230811055438.194

[Stable-7.2.6 56/63] hw/intc: Make rtc variable names consistent

2023-09-20 Thread Michael Tokarev
From: Jason Chien The variables whose values are given by cpu_riscv_read_rtc() should be named "rtc". The variables whose value are given by cpu_riscv_read_rtc_raw() should be named "rtc_r". Signed-off-by: Jason Chien Reviewed-by: Alistair Francis Message-ID: <20230728082502.26439-2-jason.ch..

[Stable-7.2.6 62/63] s390x/ap: fix missing subsystem reset registration

2023-09-20 Thread Michael Tokarev
From: Janosch Frank A subsystem reset contains a reset of AP resources which has been missing. Adding the AP bridge to the list of device types that need reset fixes this issue. Reviewed-by: Jason J. Herne Reviewed-by: Tony Krowiak Signed-off-by: Janosch Frank Fixes: a51b3153 ("s390x/ap: bas

[Stable-7.2.6 55/63] hw/intc: Fix upper/lower mtime write calculation

2023-09-20 Thread Michael Tokarev
From: Jason Chien When writing the upper mtime, we should keep the original lower mtime whose value is given by cpu_riscv_read_rtc() instead of cpu_riscv_read_rtc_raw(). The same logic applies to writes to lower mtime. Signed-off-by: Jason Chien Reviewed-by: Alistair Francis Message-ID: <20230

[Stable-7.2.6 63/63] tpm: fix crash when FD >= 1024 and unnecessary errors due to EINTR

2023-09-20 Thread Michael Tokarev
From: Marc-André Lureau Replace select() with poll() to fix a crash when QEMU has a large number of FDs. Also use RETRY_ON_EINTR to avoid unnecessary errors due to EINTR. Cc: qemu-sta...@nongnu.org Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2020133 Fixes: 56a3c24ffc ("tpm: Probe for conn

[Stable-7.2.6 59/63] target/riscv/pmp.c: respect mseccfg.RLB for pmpaddrX changes

2023-09-20 Thread Michael Tokarev
From: Leon Schuermann When the rule-lock bypass (RLB) bit is set in the mseccfg CSR, the PMP configuration lock bits must not apply. While this behavior is implemented for the pmpcfgX CSRs, this bit is not respected for changes to the pmpaddrX CSRs. This patch ensures that pmpaddrX CSR writes wor

[Stable-7.2.6 60/63] hw/tpm: TIS on sysbus: Remove unsupport ppi command line option

2023-09-20 Thread Michael Tokarev
From: Stefan Berger The ppi command line option for the TIS device on sysbus never worked and caused an immediate segfault. Remove support for it since it also needs support in the firmware and needs testing inside the VM. Reproducer with the ppi=on option passed: qemu-system-aarch64 \ -mach

[Stable-7.2.6 00/63] v3 Patch Round-up for stable 7.2.6, freeze on 2023-09-19

2023-09-20 Thread Michael Tokarev
The following patches are queued for QEMU stable v7.2.6: https://gitlab.com/qemu-project/qemu/-/commits/staging-7.2 Patch freeze is 2023-09-19 (frozen), and the release is planned for 2023-09-21: https://wiki.qemu.org/Planning/7.2 Please respond here or CC qemu-sta...@nongnu.org on any addi

[Stable-7.2.6 58/63] hw/riscv: virt: Fix riscv,pmu DT node path

2023-09-20 Thread Michael Tokarev
From: Conor Dooley On a dtb dumped from the virt machine, dt-validate complains: soc: pmu: {'riscv,event-to-mhpmcounters': [[1, 1, 524281], [2, 2, 524284], [65561, 65561, 524280], [65563, 65563, 524280], [65569, 65569, 524280]], 'compatible': ['riscv,pmu']} should not be valid under {'type': 'o

[Stable-7.2.6 61/63] ui: fix crash when there are no active_console

2023-09-20 Thread Michael Tokarev
From: Marc-André Lureau Thread 1 "qemu-system-x86" received signal SIGSEGV, Segmentation fault. 0x55888630 in dpy_ui_info_supported (con=0x0) at ../ui/console.c:812 812 return con->hw_ops->ui_info != NULL; (gdb) bt #0 0x55888630 in dpy_ui_info_supported (con=0x0) at ../ui

[Stable-7.2.6 53/63] arm64: Restore trapless ptimer access

2023-09-20 Thread Michael Tokarev
From: Colton Lewis Due to recent KVM changes, QEMU is setting a ptimer offset resulting in unintended trap and emulate access and a consequent performance hit. Filter out the PTIMER_CNT register to restore trapless ptimer access. Quoting Andrew Jones: Simply reading the CNT register and writing

[Stable-7.2.6 54/63] hw/char/riscv_htif: Fix printing of console characters on big endian hosts

2023-09-20 Thread Michael Tokarev
From: Thomas Huth The character that should be printed is stored in the 64 bit "payload" variable. The code currently tries to print it by taking the address of the variable and passing this pointer to qemu_chr_fe_write(). However, this only works on little endian hosts where the least significan

[Stable-8.0.5 59/70] include/exec: Provide the tswap() functions for target independent code, too

2023-09-20 Thread Michael Tokarev
From: Thomas Huth In some cases of target independent code, it would be useful to have access to the functions that swap endianess in case it differs between guest and host. Thus re-implement the tswapXX() functions in a new header that can be included separately. The check whether the swapping i

[Stable-8.0.5 69/70] s390x/ap: fix missing subsystem reset registration

2023-09-20 Thread Michael Tokarev
From: Janosch Frank A subsystem reset contains a reset of AP resources which has been missing. Adding the AP bridge to the list of device types that need reset fixes this issue. Reviewed-by: Jason J. Herne Reviewed-by: Tony Krowiak Signed-off-by: Janosch Frank Fixes: a51b3153 ("s390x/ap: bas

[Stable-8.0.5 70/70] tpm: fix crash when FD >= 1024 and unnecessary errors due to EINTR

2023-09-20 Thread Michael Tokarev
From: Marc-André Lureau Replace select() with poll() to fix a crash when QEMU has a large number of FDs. Also use RETRY_ON_EINTR to avoid unnecessary errors due to EINTR. Cc: qemu-sta...@nongnu.org Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2020133 Fixes: 56a3c24ffc ("tpm: Probe for conn

[Stable-8.0.5 00/70] v3 Patch Round-up for stable 8.0.5, freeze on 2023-09-19

2023-09-20 Thread Michael Tokarev
The following patches are queued for QEMU stable v8.0.5: https://gitlab.com/qemu-project/qemu/-/commits/staging-8.0 Patch freeze is 2023-09-19 (frozen), and the release is planned for 2023-09-21: https://wiki.qemu.org/Planning/8.0 Please respond here or CC qemu-sta...@nongnu.org on any addi

[Stable-8.0.5 68/70] ui: fix crash when there are no active_console

2023-09-20 Thread Michael Tokarev
From: Marc-André Lureau Thread 1 "qemu-system-x86" received signal SIGSEGV, Segmentation fault. 0x55888630 in dpy_ui_info_supported (con=0x0) at ../ui/console.c:812 812 return con->hw_ops->ui_info != NULL; (gdb) bt #0 0x55888630 in dpy_ui_info_supported (con=0x0) at ../ui

RE: [PATCH v1 04/22] vfio/common: Introduce vfio_container_add|del_section_window()

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 7:23 PM >Subject: Re: [PATCH v1 04/22] vfio/common: Introduce >vfio_container_add|del_section_window() > >Hi Zhenzhong, >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Introduce helper function

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Cédric Le Goater
On 9/20/23 05:42, Duan, Zhenzhong wrote: -Original Message- From: Cédric Le Goater Sent: Wednesday, September 20, 2023 1:08 AM Subject: Re: [PATCH v1 15/22] Add iommufd configure option On 8/30/23 12:37, Zhenzhong Duan wrote: This adds "--enable-iommufd/--disable-iommufd" to enable

Re: [PATCH v1 06/22] vfio/common: Add a vfio device iterator

2023-09-20 Thread Eric Auger
Hi Zhenzhong, On 8/30/23 12:37, Zhenzhong Duan wrote: > With a vfio device iterator added, we can make some migration and reset > related functions group agnostic. > E.x: > vfio_mig_active > vfio_migratable_device_num > vfio_devices_all_dirty_tracking > vfio_devices_all_device_dirty_tracking > vfi

Re: [PATCH v1 17/22] util/char_dev: Add open_cdev()

2023-09-20 Thread Daniel P . Berrangé
On Wed, Aug 30, 2023 at 06:37:49PM +0800, Zhenzhong Duan wrote: > From: Yi Liu > > /dev/vfio/devices/vfioX may not exist. In that case it is still possible > to open /dev/char/$major:$minor instead. Add helper function to abstract > the cdev open. > > Suggested-by: Jason Gunthorpe > Signed-off-

Re: [PATCH 1/2] migration: Fix rdma migration failed

2023-09-20 Thread Fabiano Rosas
Li Zhijian writes: > From: Li Zhijian > > Destination will fail with: > qemu-system-x86_64: rdma: Too many requests in this message > (3638950032).Bailing. > > migrate with RDMA is different from tcp. RDMA has its own control > message, and all traffic between RDMA_CONTROL_REGISTER_REQUEST and

Re: [PATCH v4 1/1] cxl/vendor: SK hynix Niagara Multi-Headed SLD Device

2023-09-20 Thread Jonathan Cameron via
On Mon, 18 Sep 2023 13:36:56 -0400 Gregory Price wrote: > Create a new device to emulate the SK hynix Niagara MHSLD platform. > > This device has custom CCI commands that allow for applying isolation > to each memory block between hosts. This enables an early form of > dynamic capacity, whereby

Re: [PATCH v4 1/1] cxl/vendor: SK hynix Niagara Multi-Headed SLD Device

2023-09-20 Thread Gregory Price
On Wed, Sep 20, 2023 at 01:46:18PM +0100, Jonathan Cameron wrote: > On Mon, 18 Sep 2023 13:36:56 -0400 > Gregory Price wrote: > > > Create a new device to emulate the SK hynix Niagara MHSLD platform. > > > > Hi Gregory, > > Seems this doesn't drop in directly on top of the rest of v3. > The mh

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 02:01:39PM +0100, Daniel P. Berrangé wrote: > Assuming we must have the exact same FD used for all vfio-pci devices, > then using -object iommufd is the least worst way to get that FD > injected into QEMU from libvirt. Yes, same FD. It is a shared resource. Jason

Re: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Cédric Le Goater
On 9/20/23 10:48, Duan, Zhenzhong wrote: -Original Message- From: Cédric Le Goater Sent: Wednesday, September 20, 2023 1:24 AM Subject: Re: [PATCH v1 13/22] vfio: Add base container On 8/30/23 12:37, Zhenzhong Duan wrote: From: Yi Liu Abstract the VFIOContainer to be a base object

Re: [PATCH v2 0/3] Follow VirtIO initialization properly at vdpa net cvq isolation probing

2023-09-20 Thread Lei Yang
QE tested this series with regression testing, everything works fine. Tested-by: Lei Yang On Sat, Sep 16, 2023 at 1:08 AM Eugenio Pérez wrote: > > This series solves a few issues. The most obvious is that the feature set was > done previous to ACKNOWLEDGE | DRIVER status bit set. Current vdpa

Re: [PATCH 06/52] migration/rdma: Clean up two more harmless signed vs. unsigned issues

2023-09-20 Thread Markus Armbruster
Fabiano Rosas writes: > Markus Armbruster writes: > >> qemu_rdma_exchange_get_response() compares int parameter @expecting >> with uint32_t head->type. Actual arguments are non-negative >> enumeration constants, RDMAControlHeader uint32_t member type, or >> qemu_rdma_exchange_recv() int paramet

Re: [PATCH 12/52] migration/rdma: Drop qemu_rdma_search_ram_block() error handling

2023-09-20 Thread Markus Armbruster
Fabiano Rosas writes: > Markus Armbruster writes: > >> qemu_rdma_search_ram_block() can't fail. Return void, and drop the >> unreachable error handling. >> >> Signed-off-by: Markus Armbruster >> --- >> migration/rdma.c | 22 -- >> 1 file changed, 8 insertions(+), 14 deleti

Re: [PATCH v1 08/22] vfio/common: Move legacy VFIO backend code into separate container.c

2023-09-20 Thread Eric Auger
Hi, On 8/30/23 12:37, Zhenzhong Duan wrote: > From: Yi Liu > > Move all the code really dependent on the legacy VFIO container/group > into a separate file: container.c. What does remain in common.c is > the code related to VFIOAddressSpace, MemoryListeners, migration and > all other general oper

Re: [PATCH 20/52] migration/rdma: Drop dead qemu_rdma_data_init() code for !@host_port

2023-09-20 Thread Markus Armbruster
Peter Xu writes: > On Mon, Sep 18, 2023 at 04:41:34PM +0200, Markus Armbruster wrote: >> qemu_rdma_data_init() neglects to set an Error when it fails because >> @host_port is null. Fortunately, no caller passes null, so this is > > Indeed they all seem to be non-null. > > Before this patch, qemu

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 02:19:42PM +0200, Cédric Le Goater wrote: > On 9/20/23 05:42, Duan, Zhenzhong wrote: > > > > > > > -Original Message- > > > From: Cédric Le Goater > > > Sent: Wednesday, September 20, 2023 1:08 AM > > > Subject: Re: [PATCH v1 15/22] Add iommufd configure option >

Re: [PATCH 00/52] migration/rdma: Error handling fixes

2023-09-20 Thread Markus Armbruster
Daniel P. Berrangé writes: > On Tue, Sep 19, 2023 at 12:49:46PM -0400, Peter Xu wrote: >> On Mon, Sep 18, 2023 at 04:41:14PM +0200, Markus Armbruster wrote: >> > Oh dear, where to start. There's so much wrong, and in pretty obvious >> > ways. This code should never have passed review. I'm refr

Re: [PATCH v1 17/22] util/char_dev: Add open_cdev()

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 01:39:02PM +0100, Daniel P. Berrangé wrote: > > diff --git a/util/chardev_open.c b/util/chardev_open.c > > new file mode 100644 > > index 00..d03e415131 > > --- /dev/null > > +++ b/util/chardev_open.c > > @@ -0,0 +1,61 @@ > > +/* > > + * Copyright (C) 2023 Intel Cor

Re: [PATCH v1 07/22] vfio/common: Refactor vfio_viommu_preset() to be group agnostic

2023-09-20 Thread Eric Auger
On 8/30/23 12:37, Zhenzhong Duan wrote: > So that it doesn't need to be moved into container.c as done > in following patch. This is a bit weird to refer to container.c which is not yet created. I would suggested just reuse the commit title as a commit msg + this will become easier to handle mul

Re: [PATCH v1 17/22] util/char_dev: Add open_cdev()

2023-09-20 Thread Daniel P . Berrangé
On Wed, Sep 20, 2023 at 09:53:46AM -0300, Jason Gunthorpe wrote: > On Wed, Sep 20, 2023 at 01:39:02PM +0100, Daniel P. Berrangé wrote: > > > > diff --git a/util/chardev_open.c b/util/chardev_open.c > > > new file mode 100644 > > > index 00..d03e415131 > > > --- /dev/null > > > +++ b/util/c

Re: [PATCH] riscv: Call set_satp_mode_max_supported in riscv_host_cpu_init

2023-09-20 Thread Andreas Schwab
On Sep 19 2023, Andrew Jones wrote: > This should be fixed by > > https://lore.kernel.org/all/20230911064320.939791-37-alistair.fran...@wdc.com/ Thanks, I can confirm that it fixes the issue. -- Andreas Schwab, SUSE Labs, sch...@suse.de GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4

Re: [PATCH v6 0/3] hw/{i2c,nvme}: mctp endpoint, nvme management interface model

2023-09-20 Thread Klaus Jensen
On Sep 20 07:54, Corey Minyard wrote: > On Wed, Sep 20, 2023 at 12:48:03PM +0100, Jonathan Cameron via wrote: > > On Thu, 14 Sep 2023 11:53:40 +0200 > > Klaus Jensen wrote: > > > > > This adds a generic MCTP endpoint model that other devices may derive > > > from. > > > > > > Also included is a

Re: [PATCH v1 09/22] vfio/container: Introduce vfio_[attach/detach]_device

2023-09-20 Thread Eric Auger
Hi Zhenzhong, In the commit title I would replace vfio/container by vfio/pci to match next patches On 8/30/23 12:37, Zhenzhong Duan wrote: > From: Eric Auger > > We want the VFIO devices to be able to use two different > IOMMU callbacks, the legacy VFIO one and the new iommufd one. s/callbacks/b

Re: [PATCH v6 0/3] hw/{i2c,nvme}: mctp endpoint, nvme management interface model

2023-09-20 Thread Corey Minyard
On Wed, Sep 20, 2023 at 12:48:03PM +0100, Jonathan Cameron via wrote: > On Thu, 14 Sep 2023 11:53:40 +0200 > Klaus Jensen wrote: > > > This adds a generic MCTP endpoint model that other devices may derive > > from. > > > > Also included is a very basic implementation of an NVMe-MI device, > > su

Re: [PATCH 2/2] migration/rdma: zore out head.repeat to make the error more clear

2023-09-20 Thread Fabiano Rosas
Li Zhijian writes: > From: Li Zhijian > > Previously, we got a confusion error that complains > the RDMAControlHeader.repeat: > qemu-system-x86_64: rdma: Too many requests in this message > (3638950032).Bailing. > > Actually, it's caused by an unexpected RDMAControlHeader.type. > After this pat

Re: [PATCH 4/7] block/dirty-bitmap: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Kevin Wolf writes: > Am 19.09.2023 um 07:48 hat Markus Armbruster geschrieben: >> Kevin Wolf writes: >> >> > Am 31.08.2023 um 15:25 hat Markus Armbruster geschrieben: >> >> Local variables shadowing other local variables or parameters make the >> >> code needlessly hard to understand. Tracked

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Cédric Le Goater
On 9/20/23 14:51, Jason Gunthorpe wrote: On Wed, Sep 20, 2023 at 02:19:42PM +0200, Cédric Le Goater wrote: On 9/20/23 05:42, Duan, Zhenzhong wrote: -Original Message- From: Cédric Le Goater Sent: Wednesday, September 20, 2023 1:08 AM Subject: Re: [PATCH v1 15/22] Add iommufd configu

Re: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Eric Auger
Hi Cedric, On 9/19/23 19:23, Cédric Le Goater wrote: > On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Yi Liu >> >> Abstract the VFIOContainer to be a base object. It is supposed to be >> embedded by legacy VFIO container and later on, into the new iommufd >> based container. >> >> The base cont

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Daniel P . Berrangé
On Wed, Sep 20, 2023 at 09:51:03AM -0300, Jason Gunthorpe wrote: > On Wed, Sep 20, 2023 at 02:19:42PM +0200, Cédric Le Goater wrote: > > On 9/20/23 05:42, Duan, Zhenzhong wrote: > > > > > > > > > > -Original Message- > > > > From: Cédric Le Goater > > > > Sent: Wednesday, September 20, 2

Re: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Eric Auger
Hi Cédric, On 9/20/23 14:57, Cédric Le Goater wrote: > On 9/20/23 10:48, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>> From: Cédric Le Goater >>> Sent: Wednesday, September 20, 2023 1:24 AM >>> Subject: Re: [PATCH v1 13/22] vfio: Add base container >>> >>> On 8/30/23 12:37, Zhen

Re: [PATCH v2 2/3] hw/mem/cxl_type3: Add missing copyright and license notice

2023-09-20 Thread Philippe Mathieu-Daudé
Hi Jonathan, On 19/9/23 12:19, Jonathan Cameron wrote: This has been missing from the start. Assume it should match with cxl/cxl-component-utils.c as both were part of early postings from Ben. Suggested-by: Philippe Mathieu-Daudé I haven't suggested this license, I only reported these files

Re: [PATCH v2 2/3] hw/mem/cxl_type3: Add missing copyright and license notice

2023-09-20 Thread Michael Tokarev
20.09.2023 17:11, Philippe Mathieu-Daudé: Hi Jonathan, On 19/9/23 12:19, Jonathan Cameron wrote: This has been missing from the start. Assume it should match with cxl/cxl-component-utils.c as both were part of early postings from Ben. Suggested-by: Philippe Mathieu-Daudé I haven't suggested

Re: [RFC PATCH v2 03/21] HostMem: Add private property and associate it with RAM_KVM_GMEM

2023-09-20 Thread Xiaoyao Li
On 9/20/2023 3:30 PM, Markus Armbruster wrote: Xiaoyao Li writes: On 9/19/2023 5:46 PM, Markus Armbruster wrote: Xiaoyao Li writes: From: Isaku Yamahata Add a new property "private" to memory backends. When it's set to true, it indicates the RAMblock of the backend also requires kvm gmem

Re: [PATCH v6 0/3] hw/{i2c,nvme}: mctp endpoint, nvme management interface model

2023-09-20 Thread Corey Minyard
On Wed, Sep 20, 2023 at 06:31:25AM -0700, Klaus Jensen wrote: > On Sep 20 07:54, Corey Minyard wrote: > > On Wed, Sep 20, 2023 at 12:48:03PM +0100, Jonathan Cameron via wrote: > > > On Thu, 14 Sep 2023 11:53:40 +0200 > > > Klaus Jensen wrote: > > > > > > > This adds a generic MCTP endpoint model

Re: [RFC PATCH v2 03/21] HostMem: Add private property and associate it with RAM_KVM_GMEM

2023-09-20 Thread David Hildenbrand
On 20.09.23 16:35, Xiaoyao Li wrote: On 9/20/2023 3:30 PM, Markus Armbruster wrote: Xiaoyao Li writes: On 9/19/2023 5:46 PM, Markus Armbruster wrote: Xiaoyao Li writes: From: Isaku Yamahata Add a new property "private" to memory backends. When it's set to true, it indicates the RAMblock

Re: [PATCH v3 2/6] hw/isa/piix3: Reuse piix3_realize() in piix3_xen_realize()

2023-09-20 Thread Chuck Zmudzinski
On 9/19/2023 4:02 PM, Bernhard Beschow wrote: > > > Am 3. April 2023 12:27:14 UTC schrieb Jason Andryuk : >>On Mon, Apr 3, 2023 at 5:33 AM Anthony PERARD >>wrote: >>> >>> On Sat, Apr 01, 2023 at 10:36:45PM +, Bernhard Beschow wrote: >>> > >>> > >>> > Am 30. März 2023 13:00:25 UTC schrieb An

Re: [PATCH v2 07/20] audio: add Apple Sound Chip (ASC) emulation

2023-09-20 Thread Mark Cave-Ayland
On 14/09/2023 08:06, Volker Rümelin wrote: Am 09.09.23 um 11:48 schrieb Mark Cave-Ayland: The Apple Sound Chip was primarily used by the Macintosh II to generate sound in hardware which was previously handled by the toolbox ROM with software interrupts. Implement both the standard ASC and also

Re: [PATCH 10/21] q800: add easc bool machine class property to switch between ASC and EASC

2023-09-20 Thread Mark Cave-Ayland
On 11/09/2023 06:15, Markus Armbruster wrote: Philippe Mathieu-Daudé writes: On 8/9/23 08:54, Mark Cave-Ayland wrote: On 07/07/2023 09:29, Philippe Mathieu-Daudé wrote: On 2/7/23 17:48, Mark Cave-Ayland wrote: This determines whether the Apple Sound Chip (ASC) is set to enhanced mode (def

[PATCH] target/i386: enumerate bit 56 of MSR_IA32_VMX_BASIC

2023-09-20 Thread Paolo Bonzini
On parts that enumerate IA32_VMX_BASIC MSR bit as 1, any exception vector can be delivered with or without an error code if the other consistency checks are satisfied. Signed-off-by: Paolo Bonzini --- target/i386/cpu.c | 1 + target/i386/cpu.h | 1 + 2 files changed, 2 insertions(+) diff --git

Re: [RFC PATCH v2 03/21] HostMem: Add private property and associate it with RAM_KVM_GMEM

2023-09-20 Thread Markus Armbruster
David Hildenbrand writes: > On 20.09.23 16:35, Xiaoyao Li wrote: >> On 9/20/2023 3:30 PM, Markus Armbruster wrote: >>> Xiaoyao Li writes: >>> On 9/19/2023 5:46 PM, Markus Armbruster wrote: > Xiaoyao Li writes: > >> From: Isaku Yamahata >> >> Add a new property "private

[PATCH] cxl/vendor: update niagara to only build on linux, add KConfig options

2023-09-20 Thread Gregory Price
Niagara uses which presently limits its compatibility to linux hosts. Change build to only build it on linux. Add Kconfig file for skhynix directory, and make niagara depend on CXL_MEM_DEVICE. Add an explicit flag for niagara. Signed-off-by: Gregory Price --- hw/cxl/Kconfig

[PULL v2 00/28] Block layer patches

2023-09-20 Thread Kevin Wolf
The following changes since commit 4907644841e3200aea6475c0f72d3d987e9f3d93: Merge tag 'mem-2023-09-19' of https://github.com/davidhildenbrand/qemu into staging (2023-09-19 13:22:19 -0400) are available in the Git repository at: https://repo.or.cz/qemu/kevin.git tags/for-upstream for you t

Re: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Eric Auger
Hi Zhenzhong, On 9/19/23 19:23, Cédric Le Goater wrote: > On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Yi Liu >> >> Abstract the VFIOContainer to be a base object. It is supposed to be >> embedded by legacy VFIO container and later on, into the new iommufd >> based container. >> >> The base c

Re: Concerns regarding e17bebd049 ("dump: Set correct vaddr for ELF dump")

2023-09-20 Thread Stephen Brennan
Hi Jon, Jon Doron writes: > Hi Stephen, > Like you have said the reason is as I wrote in the commit message, > without "fixing" the vaddr GDB is messing up mapping and working with > the generated core file. For the record I totally love this workaround :) It's clever and gets the job done an

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Eric Auger
On 9/20/23 15:02, Cédric Le Goater wrote: > On 9/20/23 14:51, Jason Gunthorpe wrote: >> On Wed, Sep 20, 2023 at 02:19:42PM +0200, Cédric Le Goater wrote: >>> On 9/20/23 05:42, Duan, Zhenzhong wrote: > -Original Message- > From: Cédric Le Goater > Sent: Wednesday, S

Re: Concerns regarding e17bebd049 ("dump: Set correct vaddr for ELF dump")

2023-09-20 Thread Stephen Brennan
Stephen Brennan writes: > Hi Jon, > > Jon Doron writes: >> Hi Stephen, >> Like you have said the reason is as I wrote in the commit message, >> without "fixing" the vaddr GDB is messing up mapping and working with >> the generated core file. > > For the record I totally love this workaround :)

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 07:37:53PM +0200, Eric Auger wrote: > >> qemu will typically not be able to > >> self-open /dev/iommufd as it is root-only. > > > > I don't understand, we open multiple fds to KVM devices. This is the > > same. > Actually qemu opens the /dev/iommu in case no fd is passed al

Re: [PULL 00/22] implement discard operation for Parallels images

2023-09-20 Thread Stefan Hajnoczi
On Wed, 20 Sept 2023 at 05:22, Denis V. Lunev wrote: > > The following changes since commit 4907644841e3200aea6475c0f72d3d987e9f3d93: > > Merge tag 'mem-2023-09-19' of https://github.com/davidhildenbrand/qemu into > staging (2023-09-19 13:22:19 -0400) > > are available in the Git repository at:

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Alex Williamson
On Wed, 20 Sep 2023 03:42:20 + "Duan, Zhenzhong" wrote: > >-Original Message- > >From: Cédric Le Goater > >Sent: Wednesday, September 20, 2023 1:08 AM > >Subject: Re: [PATCH v1 15/22] Add iommufd configure option > > > >On 8/30/23 12:37, Zhenzhong Duan wrote: > >> This adds "--enab

Re: [PATCH v2 01/28] bsd-user: define TARGET_RFSPAWN for rfork to use vfork(2) semantics, and fix RLIM_INFINITY

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > RLIM_INFINITY on FreeBSD, OpenBSD and NetBSD has value of ~(1<<63), > caculated > one way or another. > > Signed-off-by: Kyle Evans > Signed-off-by: Karim Taha > > Reviewed-by: Richard Henderson . > --- > bsd-user/syscall_defs.h | 8

Re: [PATCH v2 02/28] bsd-user: Define procctl(2) related structs

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Implement procctl flags and related structs: > struct target_procctl_reaper_status > struct target_procctl_reaper_pidinfo > struct target_procctl_reaper_pids > struct target_procctl_reaper_kill > > Signed-off-by: Stacey So

Re: [PATCH v2 03/28] bsd-user: Implement host_to_target_siginfo.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Used in wait6 system call > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > > Reviewed-by: Richard Henderson > --- > bsd-user/signal-common.h | 1 + > bsd-user/signal.c| 6 ++ > 2 files changed, 7

Re: [PATCH v2 04/28] bsd-user: Add freebsd_exec_common and do_freebsd_procctl to qemu.h.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > Reviewed-by: Richard Henderson > --- > bsd-user/qemu.h | 6 ++ > 1 file changed, 6 insertions(+) > Reviewed-by: Warner Losh

Re: [PATCH v2 05/28] bsd-user: add extern declarations for bsd-proc.c conversion functions

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > > Reviewed-by: Richard Henderson > --- > bsd-user/qemu-bsd.h | 38 ++ > 1 file changed, 38 insertions(+) > create mode 100644

Re: [PATCH v2 07/28] bsd-user: Implement target_to_host_rlim and host_to_target_rlim conversion.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.c | 10 ++ > 1 file changed, 10 insertions(+) > Reviewed-by: Warner Losh > diff --git a/bsd-u

Re: [PATCH v2 08/28] bsd-user: Implement host_to_target_rusage and host_to_target_wrusage.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.c | 54 + > 1 file changed, 54 insertions(+) > Reviewed-by

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 12:01:42PM -0600, Alex Williamson wrote: > On Wed, 20 Sep 2023 03:42:20 + > "Duan, Zhenzhong" wrote: > > > >-Original Message- > > >From: Cédric Le Goater > > >Sent: Wednesday, September 20, 2023 1:08 AM > > >Subject: Re: [PATCH v1 15/22] Add iommufd configure

Re: [PATCH v2 09/28] bsd-user: Implement host_to_target_waitstatus conversion.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.c | 17 + > 1 file changed, 17 insertions(+) > Reviewed-by: Warner Losh

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Alex Williamson
On Wed, 20 Sep 2023 14:49:19 -0300 Jason Gunthorpe wrote: > On Wed, Sep 20, 2023 at 07:37:53PM +0200, Eric Auger wrote: > > > >> qemu will typically not be able to > > >> self-open /dev/iommufd as it is root-only. > > > > > > I don't understand, we open multiple fds to KVM devices. This is the

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Daniel P . Berrangé
On Wed, Sep 20, 2023 at 12:01:42PM -0600, Alex Williamson wrote: > On Wed, 20 Sep 2023 03:42:20 + > "Duan, Zhenzhong" wrote: > > > >-Original Message- > > >From: Cédric Le Goater > > >Sent: Wednesday, September 20, 2023 1:08 AM > > >Subject: Re: [PATCH v1 15/22] Add iommufd configure

Re: [PATCH v2 10/28] bsd-user: Get number of cpus.

2023-09-20 Thread Warner Losh
This one is almost right... one tweak is needed I think... On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Kyle Evans > > Signed-off-by: Kyle Evans > Signed-off-by: Karim Taha > --- > bsd-user/bsd-proc.c | 23 +++ > bsd-user/bsd-proc.h | 2 ++ > 2 files change

Re: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Jason Gunthorpe
On Wed, Sep 20, 2023 at 12:17:24PM -0600, Alex Williamson wrote: > > The iommufd design requires one open of the /dev/iommu to be shared > > across all the vfios. > > "requires"? It's certainly of limited value to have multiple iommufd > instances rather than create multiple address spaces withi

Re: [PATCH v2 11/28] bsd-user: Implement getgroups(2) and setgroups(2) system calls.

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > --- > bsd-user/bsd-proc.h | 44 +++ > bsd-user/freebsd/os-syscall.c | 9 +++ > 2 files changed, 53 insertions(+) >

[PATCH v2 2/7] migration: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Tracked down with -Wshadow=local. Clean up: delete inner declarations when they are actually redundant, else rename variables. Signed-off-by: Markus Armbruster Reviewed-by: Peter Xu --- m

[PATCH v2 4/7] block/dirty-bitmap: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Tracked down with -Wshadow=local. Clean up: rename both the pair of parameters and the pair of local variables. While there, move the local variables to function scope. Suggested-by: Kevin

[PATCH v2 6/7] block: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Tracked down with -Wshadow=local. Clean up: delete inner declarations when they are actually redundant, else rename variables. Signed-off-by: Markus Armbruster Reviewed-by: Stefan Hajnoczi

[PATCH v2 0/7] Steps towards enabling -Wshadow=local

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Bugs love to hide in such code. Evidence: PATCH 1. Enabling -Wshadow would prevent bugs like this one. But we'd have to clean up all the offenders first. We got a lot of them. Enabling -W

[PATCH v2 5/7] block/vdi: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Tracked down with -Wshadow=local. Clean up: delete inner declarations when they are actually redundant, else rename variables. Signed-off-by: Markus Armbruster Reviewed-by: Stefan Hajnoczi

[PATCH v2 7/7] qobject atomics osdep: Make a few macros more hygienic

2023-09-20 Thread Markus Armbruster
Variables declared in macros can shadow other variables. Much of the time, this is harmless, e.g.: #define _FDT(exp) \ do { \ int ret = (exp);

[PATCH v2 1/7] migration/rdma: Fix save_page method to fail on polling error

2023-09-20 Thread Markus Armbruster
qemu_rdma_save_page() reports polling error with error_report(), then succeeds anyway. This is because the variable holding the polling status *shadows* the variable the function returns. The latter remains zero. Broken since day one, and duplicated more recently. Fixes: 2da776db4846 (rdma: cor

[PATCH v2 3/7] ui: Clean up local variable shadowing

2023-09-20 Thread Markus Armbruster
Local variables shadowing other local variables or parameters make the code needlessly hard to understand. Tracked down with -Wshadow=local. Clean up: delete inner declarations when they are actually redundant, else rename variables. Signed-off-by: Markus Armbruster Reviewed-by: Peter Maydell -

Re: [PATCH v2 12/28] bsd-user: Implement umask(2), setlogin(2) and getlogin(2)

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.h | 39 +++ > bsd-user/freebsd/os-syscall.c | 12 +++ >

Re: [PATCH v2 13/28] bsd-user: Implement getrusage(2).

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.h | 13 + > bsd-user/freebsd/os-syscall.c | 4 > 2 files changed, 17 insertio

Re: [PATCH 10/21] q800: add easc bool machine class property to switch between ASC and EASC

2023-09-20 Thread Markus Armbruster
Mark Cave-Ayland writes: > On 11/09/2023 06:15, Markus Armbruster wrote: > >> Philippe Mathieu-Daudé writes: [...] >>> I'm not sure when we want a write-only QOM boolean property, so I >>> genuinely ask, since I agree introspecting QOM object fields from >>> the monitor is helpful. >> >> I sus

Re: [PATCH v2 14/28] bsd-user: Implement getrlimit(2) and setrlimit(2)

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > Signed-off-by: Stacey Son > Signed-off-by: Karim Taha > Reviewed-by: Richard Henderson > --- > bsd-user/bsd-proc.h | 59 +++ > bsd-user/freebsd/os-syscall.c | 8 + > 2 fil

Re: [PATCH v2 15/28] bsd-user: Implement several get/set system calls:

2023-09-20 Thread Warner Losh
On Sun, Sep 17, 2023 at 10:39 PM Karim Taha wrote: > From: Stacey Son > > getpid(2), getppid(2), getpgrp(2) > setreuid(2), setregid(2) > getuid(2), geteuid(2), getgid(2), getegid(2), getpgid(2) > setuid(2), seteuid(2), setgid(2), setegid(2), setpgid(2) > > Signed-off-by: Stacey Son > Signed-off

<    1   2   3   >