[PATCH for-7.1 13/18] hw/arm/exynos4210: Fill in irq_table[] for internal-combiner-only IRQ lines

2022-04-04 Thread Peter Maydell
In exynos4210_init_board_irqs(), the loop that handles IRQ lines that are in a range that applies to the internal combiner only creates a splitter for those interrupts which go to both the internal combiner and to the external GIC, but it does nothing at all for the interrupts which don't go to the

[PATCH v9 37/45] qtests/bios-tables-test: Add a test for CXL emulation.

2022-04-04 Thread Jonathan Cameron via
The DSDT includes several CXL specific elements and the CEDT table is only present if we enable CXL. The test exercises all current functionality with several CFMWS, CHBS structures in CEDT and ACPI0016/ACPI00017 and _OSC entries in DSDT. Signed-off-by: Jonathan Cameron --- tests/qtest/bios-tab

[PATCH for-7.1 14/18] hw/arm/exynos4210: Connect MCT_G0 and MCT_G1 to both combiners

2022-04-04 Thread Peter Maydell
Currently for the interrupts MCT_G0 and MCT_G1 which are the only ones in the input range of the external combiner and which are also wired to the external GIC, we connect them only to the internal combiner and the external GIC. This seems likely to be a bug, as all other interrupts which are in th

[PATCH for-7.1] hw/arm/virt: Check for attempt to use TrustZone with KVM or HVF

2022-04-04 Thread Peter Maydell
It's not possible to provide the guest with the Security extensions (TrustZone) when using KVM or HVF, because the hardware virtualization extensions don't permit running EL3 guest code. However, we weren't checking for this combination, with the result that QEMU would assert if you tried it: $ qe

[PATCH for-7.1 10/18] hw/arm/exynos4210: Move exynos4210_combiner_get_gpioin() into exynos4210.c

2022-04-04 Thread Peter Maydell
The function exynos4210_combiner_get_gpioin() currently lives in exynos4210_combiner.c, but it isn't really part of the combiner device itself -- it is a function that implements the wiring up of some interrupt sources to multiple combiner inputs. Move it to live with the other SoC-level code in e

[PATCH v9 41/45] qtest/cxl: Add aarch64 virt test for CXL

2022-04-04 Thread Jonathan Cameron via
Add a single complex case for aarch64 virt machine. Signed-off-by: Jonathan Cameron --- tests/qtest/cxl-test.c | 48 + tests/qtest/meson.build | 1 + 2 files changed, 40 insertions(+), 9 deletions(-) diff --git a/tests/qtest/cxl-test.c b/tests/qtest/cxl

[PATCH for-7.1 09/18] hw/arm/exynos4210: Drop ext_gic_irq[] from Exynos4210Irq struct

2022-04-04 Thread Peter Maydell
The only time we use the ext_gic_irq[] array in the Exynos4210Irq struct is during realize of the SoC -- we initialize it with the input IRQs of the external GIC device, and then connect those to outputs of other devices further on in realize (including in the exynos4210_init_board_irqs() function)

[PATCH for-7.1 15/18] hw/arm/exynos4210: Don't connect multiple lines to external GIC inputs

2022-04-04 Thread Peter Maydell
The combiner_grp_to_gic_id[] array includes the EXT_GIC_ID_MCT_G0 and EXT_GIC_ID_MCT_G1 multiple times. This means that we will connect multiple IRQs up to the same external GIC input, which is not permitted. We do the same thing in the code in exynos4210_init_board_irqs() because the conditionals

[PATCH for-7.1 18/18] hw/arm/exynos4210: Drop Exynos4210Irq struct

2022-04-04 Thread Peter Maydell
The only time we use the int_combiner_irq[] and ext_combiner_irq[] arrays in the Exynos4210Irq struct is during realize of the SoC -- we initialize them with the input IRQs of the combiner devices, and then connect those to outputs of other devices in exynos4210_init_board_irqs(). Now that the com

[PATCH for-7.1 06/18] hw/arm/exynos4210: Fix code style nit in combiner_grp_to_gic_id[]

2022-04-04 Thread Peter Maydell
Fix a missing set of spaces around '-' in the definition of combiner_grp_to_gic_id[]. We're about to move this code, so fix the style issue first to keep checkpatch happy with the code-motion patch. Signed-off-by: Peter Maydell --- hw/intc/exynos4210_gic.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH for-7.1 17/18] hw/arm/exynos4210: Put combiners into state struct

2022-04-04 Thread Peter Maydell
Switch the creation of the combiner devices to the new-style "embedded in state struct" approach, so we can easily refer to the object elsewhere during realize. Signed-off-by: Peter Maydell --- include/hw/arm/exynos4210.h | 3 ++ include/hw/intc/exynos4210_combiner.h | 57

[PATCH for-7.1 08/18] hw/arm/exynos4210: Put external GIC into state struct

2022-04-04 Thread Peter Maydell
Switch the creation of the external GIC to the new-style "embedded in state struct" approach, so we can easily refer to the object elsewhere during realize. Signed-off-by: Peter Maydell --- include/hw/arm/exynos4210.h | 2 ++ include/hw/intc/exynos4210_gic.h | 43 ++

Re: [PATCH v1 8/9] qom: add command to print initial properties

2022-04-04 Thread Maxim Davydov
On 3/31/22 14:55, Igor Mammedov wrote: On Tue, 29 Mar 2022 00:15:38 +0300 Maxim Davydov wrote: The command "query-init-properties" is needed to get values of properties after initialization (not only default value). It makes sense, for example, when working with x86_64-cpu. All machine types

Re: [PATCH v5 00/13] KVM: mm: fd-based approach for supporting KVM guest private memory

2022-04-04 Thread Sean Christopherson
On Mon, Apr 04, 2022, Quentin Perret wrote: > On Friday 01 Apr 2022 at 12:56:50 (-0700), Andy Lutomirski wrote: > FWIW, there are a couple of reasons why I'd like to have in-place > conversions: > > - one goal of pKVM is to migrate some things away from the Arm >Trustzone environment (e.g. DR

Re: [PATCH for-7.1] hw/arm/virt: Check for attempt to use TrustZone with KVM or HVF

2022-04-04 Thread Richard Henderson
On 4/4/22 10:53, Peter Maydell wrote: It's not possible to provide the guest with the Security extensions (TrustZone) when using KVM or HVF, because the hardware virtualization extensions don't permit running EL3 guest code. However, we weren't checking for this combination, with the result that

Re: [PATCH] multifd: Copy pages before compressing them with zlib

2022-04-04 Thread Dr. David Alan Gilbert
* Ilya Leoshkevich (i...@linux.ibm.com) wrote: > On Mon, 2022-04-04 at 12:20 +0100, Dr. David Alan Gilbert wrote: > > * Ilya Leoshkevich (i...@linux.ibm.com) wrote: > > > zlib_send_prepare() compresses pages of a running VM. zlib does not > > > make any thread-safety guarantees with respect to chan

Re: [PATCH] target/riscv: Fix incorrect PTE merge in walk_pte

2022-04-04 Thread Ralf Ramsauer
On 01/04/2022 14:22, Ralf Ramsauer wrote: Two non-subsequent PTEs can be mapped to subsequent paddrs. In this case, walk_pte will erroneously merge them. Enforce the split up, by tracking the virtual base address. Let's say we have the mapping: 0x8120 -> 0x89623000 (4K) 0x8120f000 -> 0x8

[PATCH v2] target/riscv: Fix incorrect PTE merge in walk_pte

2022-04-04 Thread Ralf Ramsauer
Two non-subsequent PTEs can be mapped to subsequent paddrs. In this case, walk_pte will erroneously merge them. Enforce the split up, by tracking the virtual base address. Let's say we have the mapping: 0x8120 -> 0x89623000 (4K) 0x8120f000 -> 0x89624000 (4K) Before, walk_pte would have shown

Re: [PATCH] tests/qtest: failover: fix infinite loop

2022-04-04 Thread Dr. David Alan Gilbert
* Laurent Vivier (lviv...@redhat.com) wrote: > If the migration is over before we cancel it, we are > waiting in a loop a state that never comes because the state > is already "completed". > > To avoid an infinite loop, skip the test if the migration > is "completed" before we were able to cancel

Re: [RFC PATCH] tests/qtest: attempt to enable tests for virtio-gpio (!working)

2022-04-04 Thread Dr. David Alan Gilbert
* Alex Bennée (alex.ben...@linaro.org) wrote: > > (expanding the CC list for help, anyone have a better idea about how > vhost-user qtests should work/see obvious issues with this patch?) How exactly does it fail? DAve > Alex Bennée writes: > > > We don't have a virtio-gpio implementation in

[PATCH v5 0/9] s390x/pci: zPCI interpretation support

2022-04-04 Thread Matthew Rosato
For QEMU, the majority of the work in enabling instruction interpretation is handled via SHM bit settings (to indicate to firmware whether or not interpretive execution facilities are to be used) + a new KVM ioctl is used to setup firmware-interpreted forwarding of Adapter Event Notification

[PATCH v5 5/9] s390x/pci: enable for load/store intepretation

2022-04-04 Thread Matthew Rosato
If the appropriate CPU facilty is available as well as the necessary ZPCI_OP ioctl, then the underlying KVM host will enable load/store intepretation for any guest device without a SHM bit in the guest function handle. For a device that will be using interpretation support, ensure the guest functi

[PATCH v5 1/9] Update linux headers

2022-04-04 Thread Matthew Rosato
This is a placeholder that pulls in 5.18-rc1 + unmerged kernel changes required by this item. A proper header sync can be done once the associated kernel code merges. Signed-off-by: Matthew Rosato --- .../linux/input-event-codes.h | 4 +- .../standard-headers/linux/virtio_conf

[PATCH v5 4/9] s390x/pci: add routine to get host function handle from CLP info

2022-04-04 Thread Matthew Rosato
In order to interface with the underlying host zPCI device, we need to know it's function handle. Add a routine to grab this from the vfio CLP capabilities chain. Signed-off-by: Matthew Rosato --- hw/s390x/s390-pci-vfio.c | 83 ++-- include/hw/s390x/s390-pci-

[PATCH v5 2/9] vfio: tolerate migration protocol v1 uapi renames

2022-04-04 Thread Matthew Rosato
The v1 uapi is deprecated and will be replaced by v2 at some point; this patch just tolerates the renaming of uapi fields to reflect v1 / deprecated status. Signed-off-by: Matthew Rosato --- hw/vfio/common.c| 2 +- hw/vfio/migration.c | 19 +++ 2 files changed, 12 insertions

[PATCH v5 3/9] target/s390x: add zpci-interp to cpu models

2022-04-04 Thread Matthew Rosato
The zpci-interp feature is used to specify whether zPCI interpretation is to be used for this guest. Signed-off-by: Matthew Rosato --- hw/s390x/s390-virtio-ccw.c | 1 + target/s390x/cpu_features_def.h.inc | 1 + target/s390x/gen-features.c | 2 ++ target/s390x/kvm/kvm.c

[PATCH v5 9/9] s390x/pci: reflect proper maxstbl for groups of interpreted devices

2022-04-04 Thread Matthew Rosato
The maximum supported store block length might be different depending on whether the instruction is interpretively executed (firmware-reported maximum) or handled via userspace intercept (host kernel API maximum). Choose the best available value during group creation. Signed-off-by: Matthew Rosato

[PATCH v5 6/9] s390x/pci: don't fence interpreted devices without MSI-X

2022-04-04 Thread Matthew Rosato
Lack of MSI-X support is not an issue for interpreted passthrough devices, so let's let these in. This will allow, for example, ISM devices to be passed through -- but only when interpretation is available and being used. Reviewed-by: Thomas Huth Reviewed-by: Pierre Morel Signed-off-by: Matthew

[PATCH v5 7/9] s390x/pci: enable adapter event notification for interpreted devices

2022-04-04 Thread Matthew Rosato
Use the associated kvm ioctl operation to enable adapter event notification and forwarding for devices when requested. This feature will be set up with or without firmware assist based upon the 'forwarding_assist' setting. Signed-off-by: Matthew Rosato --- hw/s390x/s390-pci-bus.c | 20 +

[PATCH v5 8/9] s390x/pci: let intercept devices have separate PCI groups

2022-04-04 Thread Matthew Rosato
Let's use the reserved pool of simulated PCI groups to allow intercept devices to have separate groups from interpreted devices as some group values may be different. If we run out of simulated PCI groups, subsequent intercept devices just get the default group. Furthermore, if we encounter any PCI

Re: [qemu.qmp PATCH 02/13] fork qemu.qmp from qemu.git

2022-04-04 Thread John Snow
On Fri, Apr 1, 2022 at 1:05 PM Kashyap Chamarthy wrote: > > On Wed, Mar 30, 2022 at 02:24:13PM -0400, John Snow wrote: > > Split python/ from qemu.git, using these commands: > > > > > git subtree split -P python/ -b python-split-v3 > > > mkdir ~/src/tmp > > > cd ~/src/tmp > > > git clone --no-loca

Re: [qemu.qmp PATCH 02/13] fork qemu.qmp from qemu.git

2022-04-04 Thread John Snow
On Mon, Apr 4, 2022 at 2:54 PM John Snow wrote: > > On Fri, Apr 1, 2022 at 1:05 PM Kashyap Chamarthy wrote: > > > > On Wed, Mar 30, 2022 at 02:24:13PM -0400, John Snow wrote: > > > Split python/ from qemu.git, using these commands: > > > > > > > git subtree split -P python/ -b python-split-v3 > >

Re: [PULL 0/3] ppc queue

2022-04-04 Thread Peter Maydell
ilable in the Git repository at: > > https://github.com/legoater/qemu/ tags/pull-ppc-20220404 > > for you to fetch changes up to 0798da8df9fd917515c957ae918d6d979cf5f3fb: > > linux-user/ppc: Narrow type of cc

Re: [RFC PATCH] python: add qmp-send program to send raw qmp commands to qemu

2022-04-04 Thread John Snow
On Wed, Mar 16, 2022 at 5:55 AM Damien Hedde wrote: > > It takes an input file containing raw qmp commands (concatenated json > dicts) and send all commands one by one to a qmp server. When one > command fails, it exits. > > As a convenience, it can also wrap the qemu process to avoid having > to

Re: [PATCH v9 18/45] hw/cxl/device: Implement MMIO HDM decoding (8.2.5.12)

2022-04-04 Thread Tong Zhang
> On Apr 4, 2022, at 8:14 AM, Jonathan Cameron via > wrote: > > From: Ben Widawsky > > A device's volatile and persistent memory are known Host Defined Memory > (HDM) regions. The mechanism by which the device is programmed to claim > the addresses associated with those regions is through d

Re: [PATCH v5 00/13] KVM: mm: fd-based approach for supporting KVM guest private memory

2022-04-04 Thread Andy Lutomirski
On Mon, Apr 4, 2022, at 10:06 AM, Sean Christopherson wrote: > On Mon, Apr 04, 2022, Quentin Perret wrote: >> On Friday 01 Apr 2022 at 12:56:50 (-0700), Andy Lutomirski wrote: >> FWIW, there are a couple of reasons why I'd like to have in-place >> conversions: >> >> - one goal of pKVM is to mi

RE: [PATCH v1] ui/gtk-egl: Check for a valid context before making EGL calls

2022-04-04 Thread Kasireddy, Vivek
Hi Marc-Andre, > > Hi > > On Mon, Mar 7, 2022 at 10:00 PM Kasireddy, Vivek > wrote: > > > > Hi Marc-Andre, > > > > > > > > Hi Vivek > > > > > > On Mon, Mar 7, 2022 at 8:39 AM Vivek Kasireddy > > > wrote: > > > > > > > > Since not all listeners (i.e VirtualConsoles) of GL events have > > > > a

[PATCH v3] hw/misc: applesmc: use host osk as default on macs

2022-04-04 Thread Pedro Tôrres
From: Pedro Tôrres When running on a Mac, QEMU is able to get the host OSK and use it as the default value for the AppleSMC device. The OSK query operation doesn't require administrator privileges and can be executed by any user on the system. This patch is based on Phil Dennis-Jordan's descript

Re: ping [PATCH-for-7.0 v2] qga/vss-win32: fix compilation with clang++

2022-04-04 Thread Helge Konetzka
ping https://lore.kernel.org/qemu-devel/39400817-3dc9-516d-9096-bc1f68862...@zapateado.de/ https://patchew.org/QEMU/39400817-3dc9-516d-9096-bc1f68862...@zapateado.de/ Am 16.03.22 um 14:54 schrieb Helge Konetzka: This fixes: qga/vss-win32/install.cpp:49:24: error: cannot initialize a variable o

Re: [RFC PATCH] python: add qmp-send program to send raw qmp commands to qemu

2022-04-04 Thread Markus Armbruster
Daniel P. Berrangé writes: > On Wed, Mar 16, 2022 at 10:54:55AM +0100, Damien Hedde wrote: >> It takes an input file containing raw qmp commands (concatenated json >> dicts) and send all commands one by one to a qmp server. When one >> command fails, it exits. >> >> As a convenience, it can also

Re: [PATCH v4 2/2] Added parameter to take screenshot with screendump as PNG

2022-04-04 Thread Kshitij Suri
On 01/04/22 4:50 pm, Markus Armbruster wrote: Dave, please have a look at the HMP compatibility issue in hmp-command.hx below. Kshitij Suri writes: Currently screendump only supports PPM format, which is un-compressed and not standard. If "standard" means "have to pay a standards organizat

[Bug 1967814] Re: Ubuntu 20.04.3 - ilzlnx3g1 - virtio-scsi devs on KVM guest having miscompares on disktests when there is a failed path.

2022-04-04 Thread Frank Heimes
Changing the affected package from "linux (Ubuntu)" (kernel) to "qemu (Ubuntu)" as affected package, since the attached patch set is for qemu. ** Package changed: linux (Ubuntu) => qemu (Ubuntu) ** Also affects: qemu Importance: Undecided Status: New ** No longer affects: qemu ** Also

[PATCH] vdpa: Add missing tracing to batch mapping functions

2022-04-04 Thread Eugenio Pérez
These functions were not traced properly. Signed-off-by: Eugenio Pérez --- hw/virtio/vhost-vdpa.c | 2 ++ hw/virtio/trace-events | 2 ++ 2 files changed, 4 insertions(+) diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c index 8adf7c0b92..9e5fe15d03 100644 --- a/hw/virtio/vhost-vdpa.c

Re: [PATCH] vdpa: Add missing tracing to batch mapping functions

2022-04-04 Thread Laurent Vivier
On 05/04/2022 08:36, Eugenio Pérez wrote: These functions were not traced properly. Signed-off-by: Eugenio Pérez --- hw/virtio/vhost-vdpa.c | 2 ++ hw/virtio/trace-events | 2 ++ 2 files changed, 4 insertions(+) diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c index 8adf7c0b92.

<    1   2