Re: [PATCH v1 1/8] virtio/virtio-pci: Handle extra notification data

2024-03-05 Thread Eugenio Perez Martin
On Mon, Mar 4, 2024 at 8:46 PM Jonah Palmer wrote: > > Add support to virtio-pci devices for handling the extra data sent > from the driver to the device when the VIRTIO_F_NOTIFICATION_DATA > transport feature has been negotiated. > > The extra data that's passed to the virtio-pci device when this

Re: [PATCH v1 4/8] virtio-mmio: Lock ioeventfd state with VIRTIO_F_NOTIFICATION_DATA

2024-03-05 Thread Eugenio Perez Martin
On Mon, Mar 4, 2024 at 8:46 PM Jonah Palmer wrote: > > Prevent ioeventfd from being enabled/disabled when a virtio-mmio device > has negotiated the VIRTIO_F_NOTIFICATION_DATA transport feature. > > Due to ioeventfd not being able to carry the extra data associated with > this feature, the ioeventf

Re: [PATCH v3 00/26] migration: Improve error reporting

2024-03-05 Thread Peter Xu
On Mon, Mar 04, 2024 at 01:28:18PM +0100, Cédric Le Goater wrote: > migration: Report error when shutdown fails > migration: Remove SaveStateHandler and LoadStateHandler typedefs > migration: Add documentation for SaveVMHandlers > migration: Do not call PRECOPY_NOTIFY_SETUP notifiers in cas

Re: [PATCH v1 3/8] virtio-mmio: Handle extra notification data

2024-03-05 Thread Eugenio Perez Martin
On Mon, Mar 4, 2024 at 8:46 PM Jonah Palmer wrote: > > Add support to virtio-mmio devices for handling the extra data sent from > the driver to the device when the VIRTIO_F_NOTIFICATION_DATA transport > feature has been negotiated. > > The extra data that's passed to the virtio-mmio device when th

Re: [RFC 0/8] virtio,vhost: Add VIRTIO_F_NOTIFICATION_DATA support

2024-03-05 Thread Eugenio Perez Martin
On Tue, Mar 5, 2024 at 4:21 AM Xinying Yu wrote: > > Of course, I am glad to do. And I need to clarify that our use case only > support VIRTIO_F_NOTIFICATION_DATA transport feature on DPDK vDPA framework > which the backend type is NET_CLIENT_DRIVER_VHOST_USER and use > user_feature_bits. So

Re: [PATCH v7 2/2] hw/acpi: Implement the SRAT GI affinity structure

2024-03-05 Thread Ankit Agrawal
>>> Please add a test.  tests/qtest/bios-tables-test.c >>> + relevant table dumps. >> >> Here I need to add a test that creates a vfio-pci device and numa >> nodes and link using the acpi-generic-initiator object. One thing >> here is that the -device vfio-pci needs a host= argument. I >> probably

Re: [PATCH v4 11/15] spapr: nested: Introduce H_GUEST_[GET|SET]_STATE hcalls.

2024-03-05 Thread Harsh Prateek Bora
Hi Nick, On 2/27/24 15:40, Nicholas Piggin wrote: On Tue Feb 20, 2024 at 6:36 PM AEST, Harsh Prateek Bora wrote: Introduce the nested PAPR hcalls: - H_GUEST_GET_STATE which is used to get state of a nested guest or a guest VCPU. The value field for each element in the request is

Re: [PATCH v4 12/15] spapr: nested: Use correct source for parttbl info for nested PAPR API.

2024-03-05 Thread Harsh Prateek Bora
Hi Nick, On 2/27/24 15:46, Nicholas Piggin wrote: On Tue Feb 20, 2024 at 6:36 PM AEST, Harsh Prateek Bora wrote: For nested PAPR API, we use SpaprMachineStateNestedGuest struct to store partition table info, use the same in spapr_get_pate_nested() via helper. Signed-off-by: Michael Neuling Si

Re: [PATCH v3 03/26] migration: Always report an error in block_save_setup()

2024-03-05 Thread Cédric Le Goater
On 3/4/24 22:04, Fabiano Rosas wrote: Cédric Le Goater writes: This will prepare ground for futur changes adding an Error** argument to the save_setup() handler. We need to make sure that on failure, block_save_setup() always sets a new error. Cc: Stefan Hajnoczi Signed-off-by: Cédric Le Goa

Re: [PATCH v4 14/15] spapr: nested: Introduce cap-nested-papr for Nested PAPR API

2024-03-05 Thread Harsh Prateek Bora
On 2/27/24 15:52, Nicholas Piggin wrote: On Tue Feb 20, 2024 at 6:36 PM AEST, Harsh Prateek Bora wrote: Introduce a SPAPR capability cap-nested-papr which enables nested PAPR API for nested guests. This new API is to enable support for KVM on PowerVM and the support in Linux kernel has alread

Re: [PATCH v4 15/15] spapr: nested: Set the PCR when logical PVR is set

2024-03-05 Thread Harsh Prateek Bora
On 2/27/24 15:53, Nicholas Piggin wrote: On Tue Feb 20, 2024 at 6:36 PM AEST, Harsh Prateek Bora wrote: From: Amit Machhiwal In APIv1, KVM L0 sets the PCR, while in the nested papr APIv2, this doesn't work as the PCR can't be set via the guest state buffer; the logical PVR is set via the GS

Re: [PATCH v3 00/26] migration: Improve error reporting

2024-03-05 Thread Cédric Le Goater
On 3/5/24 09:06, Peter Xu wrote: On Mon, Mar 04, 2024 at 01:28:18PM +0100, Cédric Le Goater wrote: migration: Report error when shutdown fails migration: Remove SaveStateHandler and LoadStateHandler typedefs migration: Add documentation for SaveVMHandlers migration: Do not call PRECO

Re: [PATCH 12/19] get rid of global smbios_ep_type

2024-03-05 Thread Ani Sinha
please add "smbios:" prefix just like your other patches in the commit header. On Tue, 27 Feb 2024, Igor Mammedov wrote: > Signed-off-by: Igor Mammedov I have not checked all the code paths for the changed function signatures and left that instead for the compiler. Assuming the build is fine,

Re: [PATCH v3 04/26] migration: Always report an error in ram_save_setup()

2024-03-05 Thread Cédric Le Goater
On 3/4/24 22:30, Fabiano Rosas wrote: Cédric Le Goater writes: This will prepare ground for futur changes adding an Error** argument to the save_setup() handler. We need to make sure that on failure, ram_save_setup() sets a new error. Signed-off-by: Cédric Le Goater --- migration/ram.c | 1

Re: [RFC PATCH 2/2] gitlab-ci: add manual job to run Coverity

2024-03-05 Thread Daniel P . Berrangé
On Mon, Mar 04, 2024 at 05:06:31PM -0500, Paolo Bonzini wrote: > Add a job that can be run, either manually or on a schedule, to upload > a build to Coverity Scan. The job uses the run-coverity-scan script > in multiple phases of check, download tools and upload, in order to > avoid both wasting t

Re: [PATCH v3 04/26] migration: Always report an error in ram_save_setup()

2024-03-05 Thread Cédric Le Goater
On 3/5/24 06:29, Prasad Pandit wrote: On Mon, 4 Mar 2024 at 18:01, Cédric Le Goater wrote: This will prepare ground for futur changes adding an Error** argument * futur -> future Fixed in all first 5 patches. +ret = qemu_fflush(f); +if (ret) { * if (ret) -> if (ret < 0) yep.

Re: [PATCH v3 12/26] migration: Add Error** argument to .save_setup() handler

2024-03-05 Thread Thomas Huth
On 04/03/2024 13.28, Cédric Le Goater wrote: The purpose is to record a potential error in the migration stream if qemu_savevm_state_setup() fails. Most of the current .save_setup() handlers can be modified to use the Error argument instead of managing their own and calling locally error_report()

[PATCH RFC v3 3/6] pcie_sriov: Check PCI Express for SR-IOV PF

2024-03-05 Thread Akihiko Odaki
SR-IOV requires PCI Express. Signed-off-by: Akihiko Odaki --- hw/pci/pcie_sriov.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c index aac12e70f122..c449ddd0ac39 100644 --- a/hw/pci/pcie_sriov.c +++ b/hw/pci/pcie_sriov.c @@ -41,6 +41,11 @@ bool

[PATCH RFC v3 1/6] hw/pci: Do not add ROM BAR for SR-IOV VF

2024-03-05 Thread Akihiko Odaki
A SR-IOV VF cannot have a ROM BAR. Co-developed-by: Yui Washizu Signed-off-by: Akihiko Odaki --- hw/pci/pci.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/pci/pci.c b/hw/pci/pci.c index cb5ac46e9f27..201ff64e11cc 100644 --- a/hw/pci/pci.c +++ b/hw/pci/pci.c @@ -2359,6 +2359,14

[PATCH RFC v3 5/6] virtio-pci: Implement SR-IOV PF

2024-03-05 Thread Akihiko Odaki
Allow user to attach SR-IOV VF to a virtio-pci PF. Signed-off-by: Akihiko Odaki --- hw/virtio/virtio-pci.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index 1a7039fb0c68..f6a2dbb3b5e2 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virt

[PATCH RFC v3 4/6] pcie_sriov: Allow user to create SR-IOV device

2024-03-05 Thread Akihiko Odaki
A user can create a SR-IOV device by specifying the PF with the sriov-pf property of the VFs. The VFs must be added before the PF. A user-creatable VF must have PCIDeviceClass::sriov_vf_user_creatable set. Such a VF cannot refer to the PF because it is created before the PF. A PF that user-creata

[PATCH RFC v3 2/6] pcie_sriov: Ensure PF and VF are mutually exclusive

2024-03-05 Thread Akihiko Odaki
A device cannot be a SR-IOV PF and a VF at the same time. Signed-off-by: Akihiko Odaki --- hw/pci/pcie_sriov.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c index 09a53ed30027..aac12e70f122 100644 --- a/hw/pci/pcie_sriov.c +++ b/hw/pci/pcie_sr

[PATCH RFC v3 6/6] virtio-net: Implement SR-IOV VF

2024-03-05 Thread Akihiko Odaki
A virtio-net device can be added as a SR-IOV VF to another virtio-pci device that will be the PF. Signed-off-by: Akihiko Odaki --- hw/virtio/virtio-net-pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio/virtio-net-pci.c b/hw/virtio/virtio-net-pci.c index e03543a70a75..dba4987d6e

[PATCH RFC v3 0/6] virtio-net: add support for SR-IOV emulation

2024-03-05 Thread Akihiko Odaki
Based-on: <20240228-reuse-v8-0-282660281...@daynix.com> ("[PATCH v8 00/15] hw/pci: SR-IOV related fixes and improvements") Introduction This series is based on the RFC series submitted by Yui Washizu[1]. See also [2] for the context. This series enables SR-IOV emulation for virtio-n

Re: [PATCH] hw/intc/apic: fix memory leak

2024-03-05 Thread Philippe Mathieu-Daudé
On 4/3/24 23:41, Paolo Bonzini wrote: deliver_bitmask is allocated on the heap in apic_deliver(), but there are many paths in the function that return before the corresponding g_free() is reached. Fix this by switching to g_autofree and, while at it, also switch to g_new. Do the same in apic_de

Re: [PATCH v5 08/65] kvm: handle KVM_EXIT_MEMORY_FAULT

2024-03-05 Thread Isaku Yamahata
On Thu, Feb 29, 2024 at 01:36:29AM -0500, Xiaoyao Li wrote: > From: Chao Peng > > When geeting KVM_EXIT_MEMORY_FAULT exit, it indicates userspace needs to > do the memory conversion on the RAMBlock to turn the memory into desired > attribute, i.e., private/shared. > > Currently only KVM_MEMORY

Re: [PATCH] hw/intc/apic: fix memory leak

2024-03-05 Thread Bui Quang Minh
On 3/5/24 05:41, Paolo Bonzini wrote: deliver_bitmask is allocated on the heap in apic_deliver(), but there are many paths in the function that return before the corresponding g_free() is reached. Fix this by switching to g_autofree and, while at it, also switch to g_new. Do the same in apic_de

Re: [RFC 1/2] hw/riscv: Add server platform reference machine

2024-03-05 Thread Daniel Henrique Barboza
On 3/5/24 02:56, Wu, Fei wrote: On 3/5/2024 3:35 AM, Daniel Henrique Barboza wrote: On 3/4/24 07:25, Fei Wu wrote: The RISC-V Server Platform specification[1] defines a standardized set of hardware and software capabilities, that portable system software, such as OS and hypervisors can rel

Re: [PATCH 13/19] smbios: extend smbios-entry-point-type with 'auto' value

2024-03-05 Thread Ani Sinha
On Tue, 27 Feb 2024, Igor Mammedov wrote: > later patches will use it to pick SMBIOS version at runtime > depending on configuration. > > Signed-off-by: Igor Mammedov Reviewed-by: Ani Sinha > --- > qapi/machine.json | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git

Re: [PATCH] target/arm: Fix 32-bit SMOPA

2024-03-05 Thread Philippe Mathieu-Daudé
Hi Richard, On 5/3/24 03:31, Richard Henderson wrote: The while the 8-bit input elements are sequential in the input vector, the 32-bit output elements are not sequential in the output matrix. Do not attempt to compute 2 32-bit outputs at the same time. Cc: qemu-sta...@nongnu.org Fixes: 23a5e38

Re: [External] Re: [PATCH v1 1/1] memory tier: acpi/hmat: create CPUless memory tiers after obtaining HMAT info

2024-03-05 Thread Ho-Ren (Jack) Chuang
On Sun, Mar 3, 2024 at 6:42 PM Huang, Ying wrote: > > Hi, Jack, > > "Ho-Ren (Jack) Chuang" writes: > > > * Introduce `mt_init_with_hmat()` > > We defer memory tier initialization for those CPUless NUMA nodes > > until acquiring HMAT info. `mt_init_with_hmat()` is introduced to > > post-create CPU

Re: [PATCH 0/2] Fix CI build on Free BSD 13

2024-03-05 Thread Peter Maydell
On Mon, 4 Mar 2024 at 21:17, Alex Bennée wrote: > > Daniel P. Berrangé writes: > > > FreeBSD seems to have prematurely purged the 13.2 images from gcloud, > > despite 13.3 not being announced until tomorrow. Historically the old > > images were left available for quite some time, until we noticed

Re: [PATCH v2] docs/conf.py: Remove usage of distutils

2024-03-05 Thread Peter Maydell
On Mon, 4 Mar 2024 at 21:15, Alex Bennée wrote: > > Thomas Huth writes: > > > The macOS jobs in our CI recently started failing, complaining that > > the distutils module is not available anymore. And indeed, according to > > https://peps.python.org/pep-0632/ it's been deprecated since a while >

Re: [PULL 0/5] Hppa latest patches

2024-03-05 Thread Peter Maydell
On Sun, 3 Mar 2024 at 05:47, wrote: > > From: Helge Deller > > The following changes since commit e1007b6bab5cf97705bf4f2aaec1f607787355b8: > > Merge tag 'pull-request-2024-03-01' of https://gitlab.com/thuth/qemu into > staging (2024-03-01 10:14:32 +) > > are available in the Git repositor

Re: [PATCH] make-release: switch to .xz format by default

2024-03-05 Thread Peter Maydell
On Mon, 4 Mar 2024 at 18:52, Michael Tokarev wrote: > > For a long time, we provide two compression formats in the > download area, .bz2 and .xz. There's absolutely no reason > to provide two in parallel, .xz compresses better, and all > the links we use points to .xz. Downstream distributions >

Re: [RFC PATCH] tests: bump QOS_PATH_MAX_ELEMENT_SIZE again

2024-03-05 Thread Paolo Bonzini
On Mon, Mar 4, 2024 at 10:06 PM Alex Bennée wrote: > > We "fixed" a bug with LTO builds with 100c459f194 (tests/qtest: bump > up QOS_PATH_MAX_ELEMENT_SIZE) but it seems it has triggered again. > Lets be more assertive raising QOS_PATH_MAX_ELEMENT_SIZE to make it go > away again. > > Resolves: http

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

2024-03-05 Thread Laurent Vivier
On 2/1/24 06:45, Jason Wang wrote: On Wed, Jan 24, 2024 at 6:40 PM Laurent Vivier wrote: On resume e1000e_vm_state_change() always calls e1000e_autoneg_resume() that sets link_down to false, and thus activates the link even if we have disabled it. The problem can be reproduced starting qemu i

Re: [PATCH 00/19] Workaround Windows failing to find 64bit SMBIOS entry point with SeaBIOS

2024-03-05 Thread Michael S. Tsirkin
On Tue, Feb 27, 2024 at 04:47:30PM +0100, Igor Mammedov wrote: > Windows (10) bootloader when running on top of SeaBIOS, fails to find > > SMBIOSv3 entry point. Tracing it shows that it looks for v2 anchor markers > > only and not v3. Tricking it into believing that entry point

Re: [PATCH 00/41] target/sparc: Implement VIS4

2024-03-05 Thread Mark Cave-Ayland
On 02/03/2024 05:15, Richard Henderson wrote: I whipped this up over the Christmas break, but I'm just now getting around to posting. I have not attempted to model the newer cpus that have these features, but it is possible to enable the features manually via -cpu properties. Possibly the firs

KVM/QEMU Community Call 5th March Agenda Items

2024-03-05 Thread Alex Bennée
The KVM/QEMU community call is at: https://meet.jit.si/kvmcallmeeting @ 5/3/2024 14:00 UTC Are there any agenda items for the sync-up? I maintain the invite on our Linaro project calendar here: https://calendar.google.com/calendar/event?action=TEMPLATE&tmeid=MWd2dWI5NDM1bzdocnJlbTBhM

Re: [PATCH 00/19] Workaround Windows failing to find 64bit SMBIOS entry point with SeaBIOS

2024-03-05 Thread Igor Mammedov
On Tue, 5 Mar 2024 05:08:05 -0500 "Michael S. Tsirkin" wrote: > On Tue, Feb 27, 2024 at 04:47:30PM +0100, Igor Mammedov wrote: > > Windows (10) bootloader when running on top of SeaBIOS, fails to find > > > > SMBIOSv3 entry point. Tracing it shows that it looks for v2 anchor markers

Re: [Question] Can I start qemu-system-aarch64 with a vmlinux(ELF format)?

2024-03-05 Thread Kunkun Jiang via
Hi Peter, On 2024/2/29 17:44, Peter Maydell wrote: On Thu, 29 Feb 2024 at 03:01, Kunkun Jiang wrote: Hi Peter, On 2024/2/27 23:28, Peter Maydell wrote: On Tue, 27 Feb 2024 at 14:42, Kunkun Jiang via wrote: Hi everybody, I want to start qemu-system-aarch64 with a vmlinux, which is an ELF f

Re: [PATCH v7 2/2] hw/acpi: Implement the SRAT GI affinity structure

2024-03-05 Thread Jonathan Cameron via
On Tue, 5 Mar 2024 08:17:18 + Ankit Agrawal wrote: > >>> Please add a test.  tests/qtest/bios-tables-test.c > >>> + relevant table dumps. > >> > >> Here I need to add a test that creates a vfio-pci device and numa > >> nodes and link using the acpi-generic-initiator object. One thing > >> h

Re: [PATCH v2] docs/conf.py: Remove usage of distutils

2024-03-05 Thread Thomas Huth
On 04/03/2024 19.04, Daniel P. Berrangé wrote: On Mon, Mar 04, 2024 at 06:11:58PM +0100, Thomas Huth wrote: On 04/03/2024 17.56, Peter Maydell wrote: On Mon, 4 Mar 2024 at 13:04, Thomas Huth wrote: The macOS jobs in our CI recently started failing, complaining that the distutils module is no

[PATCH v2 1/2] [debug] log kvm supported cpuid

2024-03-05 Thread Gerd Hoffmann
--- target/i386/kvm/kvm.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c index 42970ab046fa..7298822cb511 100644 --- a/target/i386/kvm/kvm.c +++ b/target/i386/kvm/kvm.c @@ -276,6 +276,20 @@ static struct kvm_cpuid2 *try_get_cpuid(K

[PATCH v2 2/2] kvm: add support for guest physical bits

2024-03-05 Thread Gerd Hoffmann
Query kvm for supported guest physical address bits, in cpuid function 8008, eax[23:16]. Usually this is identical to host physical address bits. With NPT or EPT being used this might be restricted to 48 (max 4-level paging address space size) even if the host cpu supports more physical addre

[PATCH v2 0/2] kvm: add support for guest physical bits

2024-03-05 Thread Gerd Hoffmann
The matching kernel bits are here: https://lore.kernel.org/kvm/20240305103506.613950-1-kra...@redhat.com/T/ Gerd Hoffmann (2): [debug] log kvm supported cpuid kvm: add support for guest physical bits target/i386/cpu.h | 1 + target/i386/cpu.c | 1 + target/i386/kvm/kvm.c | 31 +

Re: [PATCH v2 1/2] [debug] log kvm supported cpuid

2024-03-05 Thread Gerd Hoffmann
> target/i386/kvm/kvm.c | 14 ++ Oops, that was not meant to be posted. Please ignore and look at patch 2/2. thanks, Gerd

Re: [Question] Can I start qemu-system-aarch64 with a vmlinux(ELF format)?

2024-03-05 Thread Peter Maydell
On Tue, 5 Mar 2024 at 10:36, Kunkun Jiang wrote: > > Hi Peter, > > On 2024/2/29 17:44, Peter Maydell wrote: > > On Thu, 29 Feb 2024 at 03:01, Kunkun Jiang wrote: > >> Hi Peter, > >> > >> On 2024/2/27 23:28, Peter Maydell wrote: > >>> On Tue, 27 Feb 2024 at 14:42, Kunkun Jiang via > >>> wrote: >

Re: [PATCH v5 05/18] mcdstub: memory helper functions added

2024-03-05 Thread nicolas.e...@lauterbach.com
On 29/02/2024 17:56, Alex Bennée wrote: I think there is some scope to re-factor some code that is shared with cpu_memory_rw_debug. In fact rather than using this to feed mcd_read_write_memory() maybe you really just want a cpu_physical_memory_rw_debug()? Although as you are going from vaddr an

[PULL 00/12] Cocoa patches for 2024-03-05

2024-03-05 Thread Philippe Mathieu-Daudé
The following changes since commit 52e7db443bd8d233acc3977bd150bdadb62db86c: Merge tag 'hppa-latest-pull-request' of https://github.com/hdeller/qemu-hppa into staging (2024-03-04 16:01:33 +) are available in the Git repository at: https://github.com/philmd/qemu.git tags/darwi

[PULL 02/12] ui/cocoa: Fix window clipping on macOS 14

2024-03-05 Thread Philippe Mathieu-Daudé
From: David Parsons macOS Sonoma changes the NSView.clipsToBounds to false by default where it was true in earlier version of macOS. This causes the window contents to be occluded by the frame at the top of the window. This fixes the issue by conditionally compiling the clipping on Sonoma to true

[PULL 08/12] ui/cocoa: Let the platform toggle fullscreen

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki It allows making the window full screen by clicking full screen button provided by the platform (the left-top green button) and save some code. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-6-e89f70bdd...@dayn

[PULL 05/12] ui/cocoa: Release specific mouse buttons

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki ui/cocoa used to release all mouse buttons when it sees NSEventTypeLeftMouseUp, NSEventTypeRightMouseUp, or NSEventTypeOtherMouseUp, but it can instead release specific one according to the delivered event. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Pet

[PULL 03/12] ui/cocoa: Split [-QemuCocoaView handleEventLocked:]

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki Currently [-QemuCocoaView handleEventLocked:] parses the passed event, stores operations to be done to variables, and perform them according to the variables. This construct will be cluttered with variables and hard to read when we need more different operations for different

[PULL 07/12] ui/cocoa: Fix pause label coordinates

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki A subview is positioned in the superview so the superview's frame should be used instead of one of the window to determine the coordinates. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-5-e89f70bdd...@daynix.c

[PULL 04/12] ui/cocoa: Immediately call [-QemuCocoaView handleMouseEvent:buttons:]

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki Instead of using mouse_event variable to tell to handle a mouse event later, immediately call [-QemuCocoaView handleMouseEvent:buttons:]. Signed-off-by: Akihiko Odaki Reviewed-by: Peter Maydell Tested-by: Rene Engel Message-ID: <20240224-cocoa-v12-2-e89f70bdd...@daynix.com

[PULL 10/12] ui/cocoa: Make window resizable

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki The window will be resizable when zoom-to-fit is on. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-8-e89f70bdd...@daynix.com> Signed-off-by: Philippe Mathieu-Daudé --- ui/cocoa.m | 3 +++ 1 file changed, 3 i

[PULL 06/12] ui/cocoa: Scale with NSView instead of Core Graphics

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki Core Graphics is not accelerated and slow. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-4-e89f70bdd...@daynix.com> Signed-off-by: Philippe Mathieu-Daudé --- ui/cocoa.m | 24 ++-- 1 file

[PULL 09/12] ui/cocoa: Remove normalWindow

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki QemuCocoaView used to have fullScreenWindow but now it's gone, so we do no longer have to call the window specifically "normalWindow". Instead, refer to it with [-QemuCocoaView window]. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-I

[PULL 12/12] ui/cocoa: Remove stretch_video flag

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki Evaluate [normalWindow styleMask] & NSWindowStyleMaskResizable instead. Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-10-e89f70bdd...@daynix.com> Signed-off-by: Philippe Mathieu-Daudé --- ui/cocoa.m | 19 +++

[PULL 11/12] ui/cocoa: Call console_select() with the BQL

2024-03-05 Thread Philippe Mathieu-Daudé
From: Akihiko Odaki [-QemuCocoaView displayConsole:] can be called anytime so explicitly take the BQL before it calls console_select(). Signed-off-by: Akihiko Odaki Tested-by: Rene Engel Reviewed-by: Peter Maydell Message-ID: <20240224-cocoa-v12-9-e89f70bdd...@daynix.com> Signed-off-by: Phili

[PULL 01/12] ui/cocoa: add zoom-interpolation display option

2024-03-05 Thread Philippe Mathieu-Daudé
From: Carwyn Ellis Provides a new display option, zoom-interpolation, that enables interpolation of the scaled display when zoom-to-fit is enabled. Also provides a corresponding view menu item to allow this to be toggled as required. Signed-off-by: Carwyn Ellis Reviewed-by: Akihiko Odaki Mess

Re: [PATCH v5 11/18] mcdstub: system and core queries added

2024-03-05 Thread nicolas.e...@lauterbach.com
On 29/02/2024 16:11, Alex Bennée wrote: Hopefully the code can be more generic now and avoid having to re-parse generated xml. I adapted my code to the recent register-related changes. There is still some arm-specific code, but thanks to gdb_get_register_list() and gdb_read_register() I coul

Re: [PATCH] hw/rtc/sun4v-rtc: Relicense to GPLv2-or-later

2024-03-05 Thread Artyom Tarasenko
On Fri, Feb 23, 2024 at 5:13 PM Peter Maydell wrote: > > The sun4v RTC device model added under commit a0e893039cf2ce0 in 2016 > was unfortunately added with a license of GPL-v3-or-later, which is > not compatible with other QEMU code which has a GPL-v2-only license. > > Relicense the code in the

Re: [PATCH 00/60] linux-user and tcg patch queue

2024-03-05 Thread Peter Maydell
On Fri, 1 Mar 2024 at 23:07, Richard Henderson wrote: > > The following changes since commit c0c6a0e3528b88aaad0b9d333e295707a195587b: > > Merge tag 'migration-next-pull-request' of https://gitlab.com/peterx/qemu > into staging (2024-02-28 17:27:10 +) > > are available in the Git repository

Re: [PATCH v5 04/18] gdbstub: DebugClass added to system mode.

2024-03-05 Thread nicolas.e...@lauterbach.com
Hi Alex, I managed to include all of your feedback except for the one on this patch: You shouldn't need empty functions if you are not using them. Moreover you should use the inheritance feature and have something like: static void gdb_debug_class_init(ObjectClass *klass, void *data) { De

Re: [PATCH] hw/rtc/sun4v-rtc: Relicense to GPLv2-or-later

2024-03-05 Thread Philippe Mathieu-Daudé
On 23/2/24 17:13, Peter Maydell wrote: The sun4v RTC device model added under commit a0e893039cf2ce0 in 2016 was unfortunately added with a license of GPL-v3-or-later, which is not compatible with other QEMU code which has a GPL-v2-only license. Relicense the code in the .c and the .h file to GP

Re: [PATCH 15/19] smbios: error out when building type 4 table is not possible

2024-03-05 Thread Ani Sinha
> On 27-Feb-2024, at 21:17, Igor Mammedov wrote: > > If SMBIOS v2 version is requested but number of cores/threads > are more than it's possible to describe with v2, error out > instead of silently ignoring the fact and filling core/thread > count with bogus values. > > This will help caller

Re: [RFC PATCH 2/2] gitlab-ci: add manual job to run Coverity

2024-03-05 Thread Paolo Bonzini
On Tue, Mar 5, 2024 at 9:52 AM Daniel P. Berrangé wrote: > > +- 'scripts/coverity-scan/run-coverity-scan --update-tools-only > > > update-tools.log 2>&1 || cat update-tools.log' > > Slightly shorter as: > > . 2>&1 | tee update-tools.log Note that stdout/stderr are only dumped if the

Re: [PATCH] hw/rtc/sun4v-rtc: Relicense to GPLv2-or-later

2024-03-05 Thread Daniel P . Berrangé
On Fri, Feb 23, 2024 at 04:13:00PM +, Peter Maydell wrote: > The sun4v RTC device model added under commit a0e893039cf2ce0 in 2016 > was unfortunately added with a license of GPL-v3-or-later, which is > not compatible with other QEMU code which has a GPL-v2-only license. > > Relicense the code

[PATCH 03/29] {linux,bsd}-user: Introduce get_task_state()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich A CPU's TaskState is stored in the CPUState's void *opaque field, accessing which is somewhat awkward due to having to use a cast. Introduce a wrapper and use it everywhere. Suggested-by: Alex Bennée Signed-off-by: Ilya Leoshkevich Reviewed-by: Warner Losh Reviewed-by:

[PATCH 04/29] {linux,bsd}-user: Update ts_tid after fork()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich Currently ts_tid contains the parent tid after fork(), which is not correct. So far it has not affected anything, but the upcoming follow-fork-mode child support relies on the correct value, so fix it. Reviewed-by: Alex Bennée Signed-off-by: Ilya Leoshkevich Reviewed-by:

[PATCH 12/29] gdbstub: Implement follow-fork-mode child

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich Currently it's not possible to use gdbstub for debugging linux-user code that runs in a forked child, which is normally done using the `set follow-fork-mode child` GDB command. Purely on the protocol level, the missing piece is the fork-events feature. However, a deeper pr

[PATCH 00/29] maintainer/next for 9.0 (testing, gdbstub, plugins, disas)

2024-03-05 Thread Alex Bennée
As I'm going to be away for most of the tree stabilisation period I'm trying to be proactive clearing my maintainer backlog before the softfreeze. With that in mind heres what is ready to go in: Testing Most stuff is being directly applied as downstreams stop working (c.f. BSD and MacOS breakage)

[PATCH 02/29] gdbstub: Support disablement in a multi-threaded process

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support will require disabling gdbstub in the parent process, which may have multiple threads (which are represented as CPUs). Loop over all CPUs in order to remove breakpoints and disable single-step. Move the respective code into a sep

[PATCH 05/29] gdbstub: Introduce gdbserver_fork_start()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support requires knowing when fork() is about to happen in order to initialize its state. Add a hook for that. Reviewed-by: Alex Bennée Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-5-...@linux.ibm.com> Signed-off-

[PATCH 11/29] gdbstub: Introduce gdb_handle_detach_user()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support needs to perform certain actions when GDB detaches from the stopped parent or the stopped child. Introduce a user-specific hook for this. Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-11-...@linux.ibm.com> S

[PATCH 13/29] tests/tcg: Add two follow-fork-mode tests

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich Add follow-fork-mode child and and follow-fork-mode parent tests. Check for the obvious pitfalls, such as lingering breakpoints, catchpoints, and single-step mode. Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-13-...@linux.ibm.com> Signed-off-by: Alex

[PATCH 01/29] tests: bump QOS_PATH_MAX_ELEMENT_SIZE again

2024-03-05 Thread Alex Bennée
We "fixed" a bug with LTO builds with 100c459f194 (tests/qtest: bump up QOS_PATH_MAX_ELEMENT_SIZE) but it seems it has triggered again. The array is sized according to the maximum anticipated length of a path on the graph. However, the worst case for a depth-first search is to push all nodes on th

[PATCH 14/29] plugins: scoreboard API

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier We introduce a cpu local storage, automatically managed (and extended) by QEMU itself. Plugin allocate a scoreboard, and don't have to deal with how many cpus are launched. This API will be used by new inline functions but callbacks can benefit from this as well. This way,

[PATCH 07/29] {linux,bsd}-user: Pass pid to gdbserver_fork()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support requires knowing the child pid. Pass it down. Reviewed-by: Richard Henderson Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-7-...@linux.ibm.com> Signed-off-by: Alex Bennée --- include/gdbstub/user.h | 2 +-

[PATCH 16/29] plugins: implement inline operation relative to cpu_index

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Instead of working on a fixed memory location, allow to address it based on cpu_index, an element size and a given offset. Result address: ptr + offset + cpu_index * element_size. With this, we can target a member in a struct array from a base pointer. Current semantic is

[PATCH 17/29] plugins: add inline operation per vcpu

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Extends API with three new functions: qemu_plugin_register_vcpu_{tb, insn, mem}_exec_inline_per_vcpu(). Those functions takes a qemu_plugin_u64 as input. This allows to have a thread-safe and type-safe version of inline operations. Reviewed-by: Alex Bennée Reviewed-by:

[PATCH 15/29] plugins: define qemu_plugin_u64

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Additionally to the scoreboard, we define a qemu_plugin_u64, which is a simple struct holding a pointer to a scoreboard, and a given offset. This allows to have a scoreboard containing structs, without having to bring offset to operate on a specific field. Since most of th

[PATCH 08/29] gdbstub: Call gdbserver_fork() both in parent and in child

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support requires post-fork message exchange between the parent and the child. Prepare gdbserver_fork() for this purpose. Rename it to gdbserver_fork_end() to better reflect its purpose. Reviewed-by: Richard Henderson Signed-off-by: Ilya

[PATCH 10/29] gdbstub: Introduce gdb_handle_set_thread_user()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support needs to perform certain actions when GDB switches between the stopped parent and the stopped child. Introduce a user-specific hook for this. Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-10-...@linux.ibm.co

[PATCH 09/29] gdbstub: Introduce gdb_handle_query_supported_user()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support requires advertising the fork-events feature, which is user-specific. Introduce a user-specific hook for this. Reviewed-by: Richard Henderson Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-9-...@linux.ibm.co

[PATCH 23/29] contrib/plugins/howvec: migrate to new per_vcpu API

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Reviewed-by: Alex Bennée Tested-by: Alex Bennée Signed-off-by: Pierrick Bouvier Message-Id: <20240304130036.124418-11-pierrick.bouv...@linaro.org> Signed-off-by: Alex Bennée --- contrib/plugins/howvec.c | 53 1 file changed, 38

[PATCH 06/29] {linux,bsd}-user: Pass pid to fork_end()

2024-03-05 Thread Alex Bennée
From: Ilya Leoshkevich The upcoming follow-fork-mode child support requires knowing the child pid. Pass it down. Reviewed-by: Alex Bennée Reviewed-by: Richard Henderson Signed-off-by: Ilya Leoshkevich Message-Id: <20240219141628.246823-6-...@linux.ibm.com> Signed-off-by: Alex Bennée --- bsd

Re: [PATCH 0/3] ui/gtk: introducing vc->visible

2024-03-05 Thread Marc-André Lureau
Hi Kim I am uncomfortable with the series in general. Not only we don't have the means to draw dmabuf/scanout "when required", so resuming drawing won't work until the guest draws (this is already a problem but you are only making it worse). And I also think reconfiguring the guest by merely mini

[PATCH 26/29] disas: introduce show_opcodes

2024-03-05 Thread Alex Bennée
For plugins we don't expect the raw opcodes in the disassembly. We already deal with this by hand crafting our capstone call but for other diassemblers we need a flag. Introduce show_opcodes which defaults to off. Signed-off-by: Alex Bennée --- include/disas/dis-asm.h | 8 disas/disas.c

[PATCH 29/29] target/riscv: honour show_opcodes when disassembling

2024-03-05 Thread Alex Bennée
This makes the output suitable when used for plugins. Signed-off-by: Alex Bennée --- disas/riscv.c | 28 +++- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/disas/riscv.c b/disas/riscv.c index 8a546d5ea53..9dec8fa966f 100644 --- a/disas/riscv.c +++ b/disa

[PATCH 18/29] tests/plugin: add test plugin for inline operations

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier For now, it simply performs instruction, bb and mem count, and ensure that inline vs callback versions have the same result. Later, we'll extend it when new inline operations are added. Use existing plugins to test everything works is a bit cumbersome, as different events

[PATCH 25/29] plugins: cleanup codepath for previous inline operation

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Reviewed-by: Richard Henderson Reviewed-by: Alex Bennée Signed-off-by: Pierrick Bouvier Message-Id: <20240304130036.124418-13-pierrick.bouv...@linaro.org> Signed-off-by: Alex Bennée --- plugins/plugin.h | 5 - accel/tcg/plugin-gen.c | 13 - plugi

[PATCH 22/29] contrib/plugins/hotblocks: migrate to new per_vcpu API

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Signed-off-by: Pierrick Bouvier Message-Id: <20240304130036.124418-10-pierrick.bouv...@linaro.org> Signed-off-by: Alex Bennée --- contrib/plugins/hotblocks.c | 50 ++--- 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/contr

[PATCH 27/29] disas/hppa: honour show_opcodes

2024-03-05 Thread Alex Bennée
Signed-off-by: Alex Bennée --- disas/hppa.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/disas/hppa.c b/disas/hppa.c index 22dce9b41bb..49e2231ae62 100644 --- a/disas/hppa.c +++ b/disas/hppa.c @@ -1972,9 +1972,11 @@ print_insn_hppa (bfd_vma memaddr, disassemble_info

[PATCH 20/29] tests/plugin/insn: migrate to new per_vcpu API

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Reviewed-by: Luc Michel Signed-off-by: Pierrick Bouvier Message-Id: <20240304130036.124418-8-pierrick.bouv...@linaro.org> Signed-off-by: Alex Bennée --- tests/plugin/insn.c | 106 +--- 1 file changed, 50 insertions(+), 56 deletion

[PATCH 21/29] tests/plugin/bb: migrate to new per_vcpu API

2024-03-05 Thread Alex Bennée
From: Pierrick Bouvier Reviewed-by: Luc Michel Reviewed-by: Alex Bennée Signed-off-by: Pierrick Bouvier Message-Id: <20240304130036.124418-9-pierrick.bouv...@linaro.org> Signed-off-by: Alex Bennée --- tests/plugin/bb.c | 63 +++ 1 file changed, 26

[PATCH 28/29] target/loongarch: honour show_opcodes when disassembling

2024-03-05 Thread Alex Bennée
This makes the output suitable when used for plugins. Signed-off-by: Alex Bennée --- target/loongarch/disas.c | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/target/loongarch/disas.c b/target/loongarch/disas.c index 2040f3e44db..63989a6282d 100644 --- a/target/l

  1   2   3   4   >