[PATCH v2 3/3] virtio-crypto: don't modify elem->in/out_sg

2020-09-17 Thread Stefan Hajnoczi
A number of iov_discard_front/back() operations are made by virtio-crypto. The elem->in/out_sg iovec arrays are modified by these operations, resulting virtqueue_unmap_sg() calls on different addresses than were originally mapped. This is problematic because dirty memory may not be logged correctl

Re: QEMU policy for real file tests

2020-09-17 Thread Thomas Huth
On 17/09/2020 11.37, Daniel P. Berrangé wrote: > On Thu, Sep 17, 2020 at 10:26:36AM +0100, Alex Bennée wrote: >> >> Christian Schoenebeck writes: >> >>> Hi, >>> >>> is there a QEMU policy for test cases that create/write/read/delete real >>> files >>> and directories? E.g. should they be situate

Re: [PATCH 1/3] block/nvme: Initialize constant values with const_le32()

2020-09-17 Thread Stefan Hajnoczi
On Wed, Sep 16, 2020 at 10:40:02PM +0200, Philippe Mathieu-Daudé wrote: > To avoid multiple endianess conversion, as we know the device > registers are in little-endian, directly use const_le32() with > constant values. Can cpu_to_X() be extended to handle constant expressions? That way the progra

Re: [PATCH v3 4/5] s390x/pci: Add routine to get the vfio dma available count

2020-09-17 Thread Cornelia Huck
On Wed, 16 Sep 2020 08:55:00 -0400 Matthew Rosato wrote: > On 9/16/20 6:27 AM, Cornelia Huck wrote: > > On Wed, 16 Sep 2020 09:21:39 +0200 > > Philippe Mathieu-Daudé wrote: > > > >> On 9/15/20 9:14 PM, Matthew Rosato wrote: > >>> Create new files for separating out vfio-specific work for s3

Re: [PATCH v2] virtio: skip legacy support check on machine types less than 5.1

2020-09-17 Thread Dr. David Alan Gilbert
* Cornelia Huck (coh...@redhat.com) wrote: > On Thu, 17 Sep 2020 10:48:28 +0200 > Stefano Garzarella wrote: > > > On Wed, Sep 16, 2020 at 11:08:48AM +0200, Cornelia Huck wrote: > > > On Tue, 15 Sep 2020 15:05:14 +0200 > > > Stefano Garzarella wrote: > > > > > > > Commit 9b3a35ec82 ("virtio: v

Re: [PATCH 0/2] meson: move libmpathpersist test

2020-09-17 Thread Thomas Huth
On 16/09/2020 18.26, Paolo Bonzini wrote: > Move the libmpathpersist test, as well as its dependency > libudev, to meson. This should fix or help debugging > https://travis-ci.com/github/huth/qemu/jobs/385737549#L4528 Thanks, this indeed decreased the amount of linker errors after I applied the p

Re: [PATCH 14/15] spapr: Simplify error handling in spapr_memory_plug()

2020-09-17 Thread Greg Kurz
On Thu, 17 Sep 2020 09:38:49 +0200 Markus Armbruster wrote: > David Gibson writes: > > > On Tue, Sep 15, 2020 at 01:43:40PM +0200, Greg Kurz wrote: > >> On Tue, 15 Sep 2020 13:58:53 +0300 > >> Vladimir Sementsov-Ogievskiy wrote: > >> > >> > 14.09.2020 15:35, Greg Kurz wrote: > >> > > As recom

[PATCH v7 05/12] i440fx/acpi: do not add hotplug related amls for cold plugged bridges

2020-09-17 Thread Ani Sinha
Cold plugged bridges are not hot unpluggable, even when their hotplug property (acpi-pci-hotplug-with-bridge-support) is turned off. Please see the function acpi_pcihp_pc_no_hotplug(). However, with the current implementaton, Windows would try to hot-unplug a pci bridge when it's hotplug switch is

[PATCH v7 12/12] tests/acpi: add DSDT.hpbrroot DSDT table blob to test global i440fx hotplug

2020-09-17 Thread Ani Sinha
This change adds a new DSDT golden master table blob to test disabling hotplug on both pci root bus and pci bridges. Also reverts the change in file bios-tables-test-allowed-diff.h to make sure its now empty so that future modifications to acpi tables can be caught. The following is the disassembl

[PATCH v7 03/12] tests/acpi: add a new ACPI table in order to test root pci hotplug on/off

2020-09-17 Thread Ani Sinha
A new binary ACPI table tests/data/acpi/pc/DSDT.roothp is added in order to unit test hotplug on/off capability on the root pci bus for i440fx. The diff between the table DSDT.bridge and DSDT.roothp is listed below: @@ -1,30 +1,30 @@ /* * Intel ACPI Component Architecture * AML/ASL+ Disassemb

[PATCH v7 02/12] tests/acpi: add new unit test to test hotplug off/on feature on the root pci bus

2020-09-17 Thread Ani Sinha
Ability to turn hotplug off on the pci root bus for i440fx was added in commit: 3d7e78aaf0 ("Introduce a new flag for i440fx to disable PCI hotplug on the root bus") This change adds a unit test in order to test this feature. Signed-off-by: Ani Sinha Reviewed-by: Igor Mammedov --- tests/qt

[PATCH v7 01/12] tests/acpi: mark addition of table DSDT.roothp for unit testing root pci hotplug

2020-09-17 Thread Ani Sinha
A new binary acpi table tests/data/acpi/pc/DSDT.roothp is added in order to unit test the feature flag that can disable/enable root pci bus hotplug on i440fx. This feature was added with the commit: 3d7e78aaf0 ("Introduce a new flag for i440fx to disable PCI hotplug on the root bus") This chan

[PATCH v7 04/12] Fix a gap where acpi_pcihp_find_hotplug_bus() returns a non-hotpluggable bus

2020-09-17 Thread Ani Sinha
When ACPI hotplug for the root bus is disabled, the bsel property for that bus is not set. Please see the following commit: 3d7e78aaf ("Introduce a new flag for i440fx to disable PCI hotplug on the root bus"). As a result, when acpi_pcihp_find_hotplug_bus() is called with bsel set to 0, it ma

Re: [PATCH v1 0/2] Add timeout mechanism to qmp actions

2020-09-17 Thread Fam Zheng
On 2020-09-17 15:36, Zhenyu Ye wrote: > Hi Stefan, > > On 2020/9/14 21:27, Stefan Hajnoczi wrote: > >> > >> Theoretically, everything running in an iothread is asynchronous. However, > >> some 'asynchronous' actions are not non-blocking entirely, such as > >> io_submit(). This will block while th

[PATCH v7 00/12] i440fx/acpi: addition of feature and bug fixes.

2020-09-17 Thread Ani Sinha
In v7, I have updated the commit log for patch #10 to include the diff between the ACPI DSDT table blobs that were added. This was done to help review the patch and for documentation. Ani Sinha (12): tests/acpi: mark addition of table DSDT.roothp for unit testing root pci hotplug tests/a

[PATCH v7 07/12] tests/acpi: unit test for 'acpi-pci-hotplug-with-bridge-support' bridge flag

2020-09-17 Thread Ani Sinha
This change adds a new unit test for the global flag 'acpi-pci-hotplug-with-bridge-support' which is available for cold plugged pci bridges in i440fx. The flag can be used to turn off ACPI based hotplug support on all pci bridges. Signed-off-by: Ani Sinha Reviewed-by: Igor Mammedov --- tests/qt

[PATCH v3 4/4] chardev/spice: build spice chardevs as module

2020-09-17 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- util/module.c | 2 ++ chardev/meson.build | 7 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/util/module.c b/util/module.c index 34772e7d87eb..86781c207f7d 100644 --- a/util/module.c +++ b/util/module.c @@ -268,6 +268,8 @@ static stru

[PATCH v7 06/12] tests/acpi: list added acpi table binary file for pci bridge hotplug test

2020-09-17 Thread Ani Sinha
The file 'tests/data/acpi/pc/DSDT.hpbridge' is a newly added acpi table file for testing the pci bridge option 'acpi-pci-hotplug-with-bridge-support' under i440fx. This change documents this fact. Signed-off-by: Ani Sinha Reviewed-by: Igor Mammedov --- tests/qtest/bios-tables-test-allowed-diff.

[PATCH v7 08/12] tests/acpi: add newly added acpi DSDT table blob for pci bridge hotplug flag

2020-09-17 Thread Ani Sinha
This patch adds a binary blob corresponding to the DSDT acpi table. It is used to unit test the flag 'acpi-pci-hotplug-with-bridge-support' used with pci bridges. This change also clears the file tests/qtest/bios-tables-test-allowed-diff.h so that future changes which affect the table can be caugh

[PATCH v3 1/4] ui/spice-app: don't use qemu_chr_open_spice_port directly

2020-09-17 Thread Gerd Hoffmann
Save the parent object's open function pointer in the (new) VCChardevClass struct instead before overwriting it, so we can look it up when needed. Signed-off-by: Gerd Hoffmann --- ui/spice-app.c | 17 + 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/ui/spice-app.c

[PATCH v7 09/12] piix4: don't reserve hw resources when hotplug is off globally

2020-09-17 Thread Ani Sinha
When acpi hotplug is turned off for both root pci bus as well as for pci bridges, we should not generate the related ACPI code for DSDT table or initialize related hw ports or reserve hw resources. This change makes sure all those operations are turned off in the case ACPI pci hotplug is off global

[PATCH v3 0/4] build spice chardevs as module

2020-09-17 Thread Gerd Hoffmann
v3: - fix spice-app - init objects before spice - meson cleanup Gerd Hoffmann (4): ui/spice-app: don't use qemu_chr_open_spice_port directly chardev/spice: make qemu_chr_open_spice_port static chardev/spice: simplify chardev setup chardev/spice: build spice chardevs as module include/

[PATCH v7 11/12] tests/acpi: unit test exercising global pci hotplug off for i440fx

2020-09-17 Thread Ani Sinha
This change adds a unit test to exercise the case when hotplug is disabled both for pci root bus and the pci bridges by passing the following two switches to qemu: -global PIIX4_PM.acpi-root-pci-hotplug=off -global PIIX4_PM.acpi-pci-hotplug-with-bridge-support=off bios-tables-test-allowed-dif

[PATCH v7 10/12] tests/acpi: update golden master DSDT binary table blobs for q35

2020-09-17 Thread Ani Sinha
In the change d7f82561fe ("piix4: don't reserve hw resources when hotplug is off globally"), we make changes to the ACPI DSDT tables such that some ACPI code are not generated when bsel is absent. Since as of this point in time, in q35 machines, we do not use bsel for pci buses, we need to update t

Re: riscv32 wait() problem, qemu or glibc?

2020-09-17 Thread Andreas K . Hüttel
Am Donnerstag, 17. September 2020, 00:05:10 EEST schrieb Alistair Francis: > On Wed, Sep 16, 2020 at 2:09 PM Andreas K. Hüttel wrote: > > > My guess is that somewhere in QEMU the types don't match what RV32 is > > > using. It's probably worth printing out the size, alignment and value > > > of ev

[PATCH] target/i386: Fix VM migration when interrupt based APF is enabled

2020-09-17 Thread Vitaly Kuznetsov
VM with interrupt based APF enabled fails to migrate: qemu-system-x86_64: error: failed to set MSR 0x4b564d02 to 0xf3 We have two issues: 1) There is a typo in kvm_put_msrs() and we write async_pf_int_msr to MSR_KVM_ASYNC_PF_EN (instead of MSR_KVM_ASYNC_PF_INT) 2) We restore MSR_KVM_ASYNC_PF_EN

[PATCH v3 2/4] chardev/spice: make qemu_chr_open_spice_port static

2020-09-17 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- include/chardev/spice.h | 3 --- chardev/spice.c | 8 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/include/chardev/spice.h b/include/chardev/spice.h index 99f26aedde54..1115502cdfbd 100644 --- a/include/chardev/spice.h +++ b/incl

Re: [PATCH v2] qemu-img: Support bitmap --merge into backing image

2020-09-17 Thread Max Reitz
On 15.09.20 15:31, Eric Blake wrote: > On 9/15/20 3:57 AM, Max Reitz wrote: >> On 14.09.20 21:10, Eric Blake wrote: >>> If you have the chain 'base.qcow2 <- top.qcow2' and want to merge a >>> bitmap from top into base, qemu-img was failing with: >>> >>> qemu-img: Could not open 'top.qcow2': Could n

Re: [PATCH v7 00/12] i440fx/acpi: addition of feature and bug fixes.

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917100947.21106-1-...@anisinha.ca/ Hi, This series seems to have some coding style problems. See output below for more information: N/A. Internal error while reading log file The full log is available at http://patchew.org/logs/20200917100947.21106

[PATCH v3 3/4] chardev/spice: simplify chardev setup

2020-09-17 Thread Gerd Hoffmann
Initialize spice before chardevs. That allows to register the spice chardevs directly in the init function and removes the need to maintain a linked list of chardevs just for registration. Signed-off-by: Gerd Hoffmann --- include/chardev/spice.h | 1 - include/ui/qemu-spice.h | 1 - chardev/s

Re: [PATCH v10 00/12] *** A Method for evaluating dirty page rate ***

2020-09-17 Thread Zheng Chuan
On 2020/9/17 17:38, Dr. David Alan Gilbert wrote: > * Zheng Chuan (zhengch...@huawei.com) wrote: >> >> >> On 2020/9/17 17:15, Dr. David Alan Gilbert wrote: >>> * Chuan Zheng (zhengch...@huawei.com) wrote: v9 -> v10: rename find_page_matched as find_block_matched fix wrong

Re: [PATCH v3 0/4] build spice chardevs as module

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917101320.25285-1-kra...@redhat.com/ Hi, This series failed build test on FreeBSD host. Please find the details below. The full log is available at http://patchew.org/logs/20200917101320.25285-1-kra...@redhat.com/testing.FreeBSD/?type=message. --

Re: [PATCH 0/2] meson: move libmpathpersist test

2020-09-17 Thread Paolo Bonzini
On 17/09/20 11:59, Thomas Huth wrote: > On 16/09/2020 18.26, Paolo Bonzini wrote: >> Move the libmpathpersist test, as well as its dependency >> libudev, to meson. This should fix or help debugging >> https://travis-ci.com/github/huth/qemu/jobs/385737549#L4528 > > Thanks, this indeed decreased th

Re: [RFC PATCH v2 3/4] hw/i386/acpi-build: Turn off support of PCIe native hot-plug and SHPC in _OSC

2020-09-17 Thread Julia Suvorova
On Thu, Sep 17, 2020 at 8:01 AM Igor Mammedov wrote: > > On Wed, 16 Sep 2020 21:14:36 +0200 > Julia Suvorova wrote: > > > On Wed, Sep 16, 2020 at 8:03 PM Julia Suvorova wrote: > > > > > > On Fri, Aug 21, 2020 at 2:13 PM Igor Mammedov wrote: > > > > > > > > On Tue, 18 Aug 2020 23:52:26 +0200 > >

Re: Use patchew to push successfully applied series to GitLab

2020-09-17 Thread Gerd Hoffmann
Hi, > What if we used git-publish to always push to gitlab when submitting > patches, and have it include the gitlab ref in the cover letter. Well, when pushing to gitlab anyway for CI runs this should be done *before* publishing the patch series on the list ... > That would trigger CI jobs in

[PATCH] docker.py: always use --rm

2020-09-17 Thread Paolo Bonzini
Avoid that containers pile up. Signed-off-by: Paolo Bonzini --- tests/docker/Makefile.include | 1 - tests/docker/docker.py| 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index 3daabaa2fd..75704268ff 1

Re: [PATCH] docker.py: always use --rm

2020-09-17 Thread Daniel P . Berrangé
On Thu, Sep 17, 2020 at 12:44:41PM +0200, Paolo Bonzini wrote: > Avoid that containers pile up. > > Signed-off-by: Paolo Bonzini > --- > tests/docker/Makefile.include | 1 - > tests/docker/docker.py| 4 ++-- > 2 files changed, 2 insertions(+), 3 deletions(-) > > diff --git a/tests/docke

Re: Why QEMU treats each instruction as one translation block?

2020-09-17 Thread Peter Maydell
On Thu, 17 Sep 2020 at 07:11, casmac wrote: > > The loader works functionally, but we then found that sometimes QEMU is > down-graded - it treats each instruction as one TB. In version 4.2, > debugging shows > that get_page_addr_code_host() from accel/tcg/cputlb.c returns -1, as shown > belo

Re: [PATCH] docker.py: always use --rm

2020-09-17 Thread Paolo Bonzini
On 17/09/20 12:48, Daniel P. Berrangé wrote: > On Thu, Sep 17, 2020 at 12:44:41PM +0200, Paolo Bonzini wrote: >> Avoid that containers pile up. >> >> Signed-off-by: Paolo Bonzini >> --- >> tests/docker/Makefile.include | 1 - >> tests/docker/docker.py| 4 ++-- >> 2 files changed, 2 insert

Re: [PATCH v2] virtio: skip legacy support check on machine types less than 5.1

2020-09-17 Thread Stefano Garzarella
On Thu, Sep 17, 2020 at 11:00:00AM +0100, Dr. David Alan Gilbert wrote: > * Cornelia Huck (coh...@redhat.com) wrote: > > On Thu, 17 Sep 2020 10:48:28 +0200 > > Stefano Garzarella wrote: > > > > > On Wed, Sep 16, 2020 at 11:08:48AM +0200, Cornelia Huck wrote: > > > > On Tue, 15 Sep 2020 15:05:14 +

Re: [PATCH] docker.py: always use --rm

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917104441.31738-1-pbonz...@redhat.com/ Hi, This series failed the docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. The full log is ava

Re: [PATCH] docker.py: always use --rm

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917104441.31738-1-pbonz...@redhat.com/ Hi, This series failed build test on FreeBSD host. Please find the details below. The full log is available at http://patchew.org/logs/20200917104441.31738-1-pbonz...@redhat.com/testing.FreeBSD/?type=messag

Re: [RFC PATCH 02/12] target/arm/kvm64: make MPIDR consistent with CPU Topology

2020-09-17 Thread Andrew Jones
On Thu, Sep 17, 2020 at 09:53:35AM +0200, Andrew Jones wrote: > On Thu, Sep 17, 2020 at 11:20:23AM +0800, Ying Fang wrote: > > MPIDR helps to provide an additional PE identification in a multiprocessor > > system. This patch adds support for setting MPIDR from userspace, so that > > MPIDR is consis

Re: [PATCH v2] virtio: skip legacy support check on machine types less than 5.1

2020-09-17 Thread Cornelia Huck
On Thu, 17 Sep 2020 12:47:21 +0200 Stefano Garzarella wrote: > Okay, so I'll leave the device property. > > > I also need to update a series [1] that I sent to force virtio version 1 > on vhost-vsock devices. > Also in this case I need to care about migration and force it only on new > machine

[PATCH] target/i386: always create kvmclock device

2020-09-17 Thread Vitaly Kuznetsov
QEMU's kvmclock device is only created when KVM PV feature bits for kvmclock (KVM_FEATURE_CLOCKSOURCE/KVM_FEATURE_CLOCKSOURCE2) are exposed to the guest. With 'kvm=off' cpu flag the device is not created and we don't call KVM_GET_CLOCK/KVM_SET_CLOCK upon migration. It was reported that without thes

Re: [PATCH] target/i386: always create kvmclock device

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917111306.819263-1-vkuzn...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: N/A. Internal error while reading log file The full log is available at http://patchew.org/logs/20200917111306

Re: [PATCH] target/i386: always create kvmclock device

2020-09-17 Thread Vitaly Kuznetsov
no-re...@patchew.org writes: > Patchew URL: > https://patchew.org/QEMU/20200917111306.819263-1-vkuzn...@redhat.com/ > > > > Hi, > > This series seems to have some coding style problems. See output below for > more information: > > N/A. Internal error while reading log file error: copy-fd: write

Re: [PATCH v7 3/7] usb/hcd-xhci: Split pci wrapper for xhci base model

2020-09-17 Thread Gerd Hoffmann
Hi, > +static const VMStateDescription vmstate_xhci_pci = { > +.name = "xhci-pci", > +.version_id = 1, > +.fields = (VMStateField[]) { > +VMSTATE_PCI_DEVICE(parent_obj, XHCIPciState), > +VMSTATE_MSIX(parent_obj, XHCIPciState), > +VMSTATE_UINT8_ARRAY(msix_used,

[PATCH v1] s390x/tcg: Implement MONITOR CALL

2020-09-17 Thread David Hildenbrand
Recent upstream Linux uses the MONITOR CALL instruction for things like BUG_ON() and WARN_ON(). We currently inject an operation exception when we hit a MONITOR CALL instruction - which is wrong, as the instruction is not glued to specific CPU features. Doing a simple WARN_ON_ONCE() currently resu

Re: [PATCH 14/15] spapr: Simplify error handling in spapr_memory_plug()

2020-09-17 Thread Markus Armbruster
Greg Kurz writes: > On Thu, 17 Sep 2020 09:38:49 +0200 > Markus Armbruster wrote: > >> David Gibson writes: >> >> > On Tue, Sep 15, 2020 at 01:43:40PM +0200, Greg Kurz wrote: >> >> On Tue, 15 Sep 2020 13:58:53 +0300 >> >> Vladimir Sementsov-Ogievskiy wrote: >> >> >> >> > 14.09.2020 15:35, Gr

Re: QEMU policy for real file tests

2020-09-17 Thread Christian Schoenebeck
On Donnerstag, 17. September 2020 11:55:00 CEST Thomas Huth wrote: > On 17/09/2020 11.37, Daniel P. Berrangé wrote: > > On Thu, Sep 17, 2020 at 10:26:36AM +0100, Alex Bennée wrote: > >> Christian Schoenebeck writes: > >>> Hi, > >>> > >>> is there a QEMU policy for test cases that create/write/rea

Re: [PATCH v2] virtio: skip legacy support check on machine types less than 5.1

2020-09-17 Thread Stefano Garzarella
On Thu, Sep 17, 2020 at 01:00:08PM +0200, Cornelia Huck wrote: > On Thu, 17 Sep 2020 12:47:21 +0200 > Stefano Garzarella wrote: > > > Okay, so I'll leave the device property. > > > > > > I also need to update a series [1] that I sent to force virtio version 1 > > on vhost-vsock devices. > > Als

Re: [RFC PATCH 02/12] target/arm/kvm64: make MPIDR consistent with CPU Topology

2020-09-17 Thread Ying Fang
On 9/17/2020 3:53 PM, Andrew Jones wrote: On Thu, Sep 17, 2020 at 11:20:23AM +0800, Ying Fang wrote: MPIDR helps to provide an additional PE identification in a multiprocessor system. This patch adds support for setting MPIDR from userspace, so that MPIDR is consistent with CPU topology confi

Re: [PATCH 14/15] spapr: Simplify error handling in spapr_memory_plug()

2020-09-17 Thread Daniel P . Berrangé
On Thu, Sep 17, 2020 at 02:04:41PM +0200, Markus Armbruster wrote: > Greg Kurz writes: > > > $ git grep object_property_get_uint -- :^{include,qom/object.c} | wc -l > > 60 > > > > Manual inspecting the output of > > > > $ git grep -W object_property_get_uint -- :^{include,qom/object.c} > > ... >

[RFC v2 00/10] Support disable/enable CPU features for AArch64

2020-09-17 Thread Peng Liang
QEMU does not support disable/enable CPU features in AArch64 for now. This patch series add support for CPU features in AArch64. Firstly, we change the isar struct in ARMCPU to an array for convenience. Secondly, we add support to configure CPU feautres in AArch64 and make sure that the ID regist

[RFC v2 03/10] target/arm: only set ID_PFR1_EL1.GIC for AArch32 guest

2020-09-17 Thread Peng Liang
Some AArch64 CPU doesn't support AArch32 mode, AArch32 registers should be 0. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- target/arm/helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/arm/helper.c b/target/arm/helper.c index 88bd9dd35da8..3a48bc4e

[RFC v2 07/10] target/arm: Allow ID registers to synchronize to KVM

2020-09-17 Thread Peng Liang
There are 2 steps to synchronize the values of system registers from CPU state to KVM: 1. write to the values of system registers from CPU state to (index,value) list by write_cpustate_to_list; 2. write the values in (index,value) list to KVM by write_list_to_kvmstate; In step 1, the values

[RFC v2 01/10] linux-header: Introduce KVM_CAP_ARM_CPU_FEATURE

2020-09-17 Thread Peng Liang
Introduce KVM_CAP_ARM_CPU_FEATURE. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- linux-headers/linux/kvm.h | 1 + 1 file changed, 1 insertion(+) diff --git a/linux-headers/linux/kvm.h b/linux-headers/linux/kvm.h index a28c3667370b..169eb0bb31c8 100644 --- a/linux-headers/linux/kvm

Re: QEMU policy for real file tests

2020-09-17 Thread Daniel P . Berrangé
On Thu, Sep 17, 2020 at 02:06:33PM +0200, Christian Schoenebeck wrote: > On Donnerstag, 17. September 2020 11:55:00 CEST Thomas Huth wrote: > > On 17/09/2020 11.37, Daniel P. Berrangé wrote: > > > On Thu, Sep 17, 2020 at 10:26:36AM +0100, Alex Bennée wrote: > > >> Christian Schoenebeck writes: > >

[RFC v2 02/10] target/arm: Update ID fields

2020-09-17 Thread Peng Liang
Update definitions for ID fields, up to ARMv8.6. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- target/arm/cpu.h | 17 + 1 file changed, 17 insertions(+) diff --git a/target/arm/cpu.h b/target/arm/cpu.h index 6036f61d60b3..d89043448923 100644 --- a/target/arm/cpu.h

[RFC v2 10/10] target/arm: Add CPU features to query-cpu-model-expansion

2020-09-17 Thread Peng Liang
Add CPU features to the result of query-cpu-model-expansion so that other applications (such as libvirt) can know the supported CPU features. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- target/arm/monitor.c | 4 1 file changed, 4 insertions(+) diff --git a/target/arm/monito

Re: [PATCH] target/i386: always create kvmclock device

2020-09-17 Thread Antoine Damhet
On Thu, Sep 17, 2020 at 01:13:06PM +0200, Vitaly Kuznetsov wrote: > QEMU's kvmclock device is only created when KVM PV feature bits for > kvmclock (KVM_FEATURE_CLOCKSOURCE/KVM_FEATURE_CLOCKSOURCE2) are > exposed to the guest. With 'kvm=off' cpu flag the device is not > created and we don't call KVM

[RFC v2 09/10] target/arm: introduce CPU feature dependency mechanism

2020-09-17 Thread Peng Liang
Some CPU features are dependent on other CPU features. For example, ID_AA64PFR0_EL1.FP field and ID_AA64PFR0_EL1.AdvSIMD must have the same value, which means FP and ADVSIMD are dependent on each other, FPHP and ADVSIMDHP are dependent on each other. This commit introduces a mechanism for CPU fea

[RFC v2 04/10] target/arm: convert isar regs to array

2020-09-17 Thread Peng Liang
The isar in ARMCPU is a struct, each field of which represents an ID register. It's not convenient for us to support CPU feature in AArch64. So let's change it to an array first and add an enum as the index of the array for convenience. Since we will never access high 32-bits of ID registers in A

[RFC v2 05/10] target/arm: Introduce kvm_arm_cpu_feature_supported

2020-09-17 Thread Peng Liang
Introduce kvm_arm_cpu_feature_supported to check whether KVM supports to set CPU features in ARM. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- target/arm/kvm_arm.h | 7 +++ target/arm/kvm64.c | 14 ++ 2 files changed, 21 insertions(+) diff --git a/target/arm/kv

Re: [PULL 0/8] Block odirect patches

2020-09-17 Thread Peter Maydell
On Wed, 16 Sep 2020 at 10:47, Daniel P. Berrangé wrote: > > The following changes since commit de39a045bd8d2b49e4f3d07976622c29d58e0bac: > > Merge remote-tracking branch 'remotes/kraxel/tags/vga-20200915-pull-request= > ' into staging (2020-09-15 14:25:05 +0100) > > are available in the Git repo

[RFC v2 08/10] target/arm: Introduce user_mask to indicate whether the feature is set explicitly

2020-09-17 Thread Peng Liang
To add CPU feature dependencies, we need to known whether a CPU feature is set explicitly or automatically by dependencies mechanism. Introduce user_mask to do that. Signed-off-by: zhanghailiang Signed-off-by: Peng Liang --- target/arm/cpu.h | 1 + target/arm/cpu.c | 2 ++ 2 files changed, 3 i

[RFC v2 06/10] target/arm: register CPU features for property

2020-09-17 Thread Peng Liang
The Arm architecture specifies a number of ID registers that are characterized as comprising a set of 4-bit ID fields. Each ID field identifies the presence, and possibly the level of support for, a particular feature in an implementation of the architecture. [1] For most of the ID fields, there i

Re: [PATCH 14/15] spapr: Simplify error handling in spapr_memory_plug()

2020-09-17 Thread Greg Kurz
On Thu, 17 Sep 2020 13:18:51 +0100 Daniel P. Berrangé wrote: > On Thu, Sep 17, 2020 at 02:04:41PM +0200, Markus Armbruster wrote: > > Greg Kurz writes: > > > > > $ git grep object_property_get_uint -- :^{include,qom/object.c} | wc -l > > > 60 > > > > > > Manual inspecting the output of > > > >

Re: QEMU 5.0 virtio-blk performance regression with high queue depths

2020-09-17 Thread Stefan Hajnoczi
On Wed, Sep 16, 2020 at 5:43 PM Denis V. Lunev wrote: > On 9/16/20 5:07 PM, Denis V. Lunev wrote: > > I will make a check today. > > > > Talking about our performance measurements, we have not > > seen ANY performance degradation, especially 30-40%. > > This looking quite strange to me. > > > > Th

Re: QEMU policy for real file tests

2020-09-17 Thread Peter Maydell
On Thu, 17 Sep 2020 at 13:24, Daniel P. Berrangé wrote: > If creating in /tmp then stay below 100 MB, as it can be surprisingly > space constrained in some cases. Also if creating in /tmp/ it's nice to use an obviously qemu-testing related filename. If a 'make check' run falls over partway throug

Re: [PATCH v2 00/10] fix some error memleaks

2020-09-17 Thread Pan Nengyuan
ping! Anyone queued the rest(patch 01/02/03/07/08/09)? On 2020/8/31 21:43, Pan Nengyuan wrote: > This series fix some Error/GError memleaks. > > V2: > 1. remove two patches.(One has aleardy applied. The other has fixed.) > 2. change patch 5/10 and 7/10. > > Pan Nengyuan (10): > qga/chann

Re: Python docstrings and licensing/authorship

2020-09-17 Thread Markus Armbruster
Daniel P. Berrangé writes: > On Wed, Sep 16, 2020 at 12:22:37PM -0400, John Snow wrote: [...] >> The real question I have is if anyone thinks it would be "rude" to separate >> out any of the comment preambles (currently not visible at runtime or docs >> in any way, shape or form!) into two pieces

[PATCH 1/2] qom: Clean up object_property_get_enum()'s error value

2020-09-17 Thread Markus Armbruster
object_property_get_enum() is the only object_property_FOO() that is documented to return an undefined value on error. It does no such thing, actually: it returns 0 on some errors, and -1 on others. Needlessly complicated. Always return -1 on error, and adjust the contract. Signed-off-by: Marku

[PATCH 0/2] qpm: Minor error value corrections

2020-09-17 Thread Markus Armbruster
Markus Armbruster (2): qom: Clean up object_property_get_enum()'s error value qom: Correct error values in two contracts include/qom/object.h | 10 +- qom/object.c | 6 +++--- tests/check-qom-proplist.c | 2 ++ 3 files changed, 10 insertions(+), 8 deletions(-) -

[PATCH 2/2] qom: Correct error values in two contracts

2020-09-17 Thread Markus Armbruster
object_property_get_bool()'s contract claims it returns NULL on error. Pasto; it returns false. object_property_get_int()'s contract claims it returns "negative". It actually returns -1. All the other object_property_get_FOO() contracts specify the exact error value, so do the same here. Signed

Re: [PATCH 1/2] qom: Clean up object_property_get_enum()'s error value

2020-09-17 Thread Daniel P . Berrangé
On Thu, Sep 17, 2020 at 02:55:39PM +0200, Markus Armbruster wrote: > object_property_get_enum() is the only object_property_FOO() that is > documented to return an undefined value on error. It does no such > thing, actually: it returns 0 on some errors, and -1 on others. > > Needlessly complicate

Re: [PATCH 2/2] qom: Correct error values in two contracts

2020-09-17 Thread Daniel P . Berrangé
On Thu, Sep 17, 2020 at 02:55:40PM +0200, Markus Armbruster wrote: > object_property_get_bool()'s contract claims it returns NULL on error. > Pasto; it returns false. > > object_property_get_int()'s contract claims it returns "negative". It > actually returns -1. All the other object_property_ge

Re: [PATCH 0/2] qpm: Minor error value corrections

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917125540.597786-1-arm...@redhat.com/ Hi, This series failed build test on FreeBSD host. Please find the details below. The full log is available at http://patchew.org/logs/20200917125540.597786-1-arm...@redhat.com/testing.FreeBSD/?type=message.

Re: QEMU policy for real file tests

2020-09-17 Thread Thomas Huth
On 17/09/2020 14.06, Christian Schoenebeck wrote: [...] > Final question: if at some later point one large file needs to be created for > some test case, is there some approximate size limit to stay below for not > causing issues with free CI cloud services? FWIW, I know that 4G is already too b

Re: [PATCH 0/2] qpm: Minor error value corrections

2020-09-17 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200917125540.597786-1-arm...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: N/A. Internal error while reading log file The full log is available at http://patchew.org/logs/20200917125540.59

Re: QEMU policy for real file tests

2020-09-17 Thread Peter Maydell
On Thu, 17 Sep 2020 at 14:04, Thomas Huth wrote: > > On 17/09/2020 14.06, Christian Schoenebeck wrote: > [...] > > Final question: if at some later point one large file needs to be created > > for > > some test case, is there some approximate size limit to stay below for not > > causing issues wi

Re: [PATCH 1/2] file-posix: Correctly read max_segments of SG nodes

2020-09-17 Thread Max Reitz
On 12.08.20 00:51, Dmitry Fomichev wrote: > If scsi-generic driver is in use, an SG node can be specified in > the command line in place of a regular SCSI device. In this case, > sg_get_max_segments() fails to open max_segments entry in sysfs > because /dev/sgX is a character device. As the result,

Re: [PATCH 14/15] spapr: Simplify error handling in spapr_memory_plug()

2020-09-17 Thread Markus Armbruster
Daniel P. Berrangé writes: > On Thu, Sep 17, 2020 at 02:04:41PM +0200, Markus Armbruster wrote: >> Greg Kurz writes: >> >> > $ git grep object_property_get_uint -- :^{include,qom/object.c} | wc -l >> > 60 >> > >> > Manual inspecting the output of >> > >> > $ git grep -W object_property_get_uint

Re: [RFC PATCH 02/12] target/arm/kvm64: make MPIDR consistent with CPU Topology

2020-09-17 Thread Ying Fang
On 9/17/2020 6:59 PM, Andrew Jones wrote: On Thu, Sep 17, 2020 at 09:53:35AM +0200, Andrew Jones wrote: On Thu, Sep 17, 2020 at 11:20:23AM +0800, Ying Fang wrote: MPIDR helps to provide an additional PE identification in a multiprocessor system. This patch adds support for setting MPIDR from

Re: [PATCH] meson: report accelerator support

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/16/20 9:41 PM, Paolo Bonzini wrote: > Note that the "real" support is reported. A configuration like > --disable-system --enable-kvm will report "no" for "KVM support" because > no KVM-supported target is being compiled. > > Reported-by: Andrew Jones > Signed-off-by: Paolo Bonzini > --- >

Re: [PATCH 1/2] file-posix: Correctly read max_segments of SG nodes

2020-09-17 Thread Maxim Levitsky
On Thu, 2020-09-17 at 15:16 +0200, Max Reitz wrote: > On 12.08.20 00:51, Dmitry Fomichev wrote: > > If scsi-generic driver is in use, an SG node can be specified in > > the command line in place of a regular SCSI device. In this case, > > sg_get_max_segments() fails to open max_segments entry in sy

Re: [PATCH V2 00/10] fix some comment spelling errors

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 5:54 AM, zhaolichang wrote: > I found that there are many spelling errors in the comments of qemu, > so I used the spellcheck tool to check the spelling errors, this series fixed > this > spelling errors. Your name seems mis-configured in git (it displays it as an username). This shou

Re: [PATCH 1/2] file-posix: Correctly read max_segments of SG nodes

2020-09-17 Thread Maxim Levitsky
On Thu, 2020-09-17 at 16:22 +0300, Maxim Levitsky wrote: > On Thu, 2020-09-17 at 15:16 +0200, Max Reitz wrote: > > On 12.08.20 00:51, Dmitry Fomichev wrote: > > > If scsi-generic driver is in use, an SG node can be specified in > > > the command line in place of a regular SCSI device. In this case,

Re: [PATCH 1/2] qom: Clean up object_property_get_enum()'s error value

2020-09-17 Thread Greg Kurz
On Thu, 17 Sep 2020 14:55:39 +0200 Markus Armbruster wrote: > object_property_get_enum() is the only object_property_FOO() that is > documented to return an undefined value on error. It does no such > thing, actually: it returns 0 on some errors, and -1 on others. > > Needlessly complicated. A

Re: [RFC PATCH 03/12] target/arm/kvm32: make MPIDR consistent with CPU Topology

2020-09-17 Thread Ying Fang
On 9/17/2020 4:07 PM, Andrew Jones wrote: On Thu, Sep 17, 2020 at 11:20:24AM +0800, Ying Fang wrote: MPIDR helps to provide an additional PE identification in a multiprocessor system. This patch adds support for setting MPIDR from userspace, so that MPIDR is consistent with CPU topology confi

Re: [REPORT] Nightly Performance Tests - Wednesday, September 16, 2020

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 10:02 AM, Ahmed Karaman wrote: > On Thu, Sep 17, 2020 at 12:07 AM Ahmed Karaman > wrote: >> >> Host CPU : Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz >> Host Memory : 15.49 GB >> >> Start Time (UTC) : 2020-09-16 21:35:02 >> End Time (UTC) : 2020-09-16 22:07:32 >> Execution T

Re: [PATCH 2/2] qom: Correct error values in two contracts

2020-09-17 Thread Greg Kurz
On Thu, 17 Sep 2020 14:55:40 +0200 Markus Armbruster wrote: > object_property_get_bool()'s contract claims it returns NULL on error. > Pasto; it returns false. > > object_property_get_int()'s contract claims it returns "negative". It > actually returns -1. All the other object_property_get_FOO

Re: [PATCH v3 1/4] ui/spice-app: don't use qemu_chr_open_spice_port directly

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 12:13 PM, Gerd Hoffmann wrote: > Save the parent object's open function pointer in the (new) > VCChardevClass struct instead before overwriting it, so we > can look it up when needed. > > Signed-off-by: Gerd Hoffmann > --- > ui/spice-app.c | 17 + > 1 file changed, 13

Re: [PATCH] target/i386: always create kvmclock device

2020-09-17 Thread Vitaly Kuznetsov
Antoine Damhet writes: > On Thu, Sep 17, 2020 at 01:13:06PM +0200, Vitaly Kuznetsov wrote: >> QEMU's kvmclock device is only created when KVM PV feature bits for >> kvmclock (KVM_FEATURE_CLOCKSOURCE/KVM_FEATURE_CLOCKSOURCE2) are >> exposed to the guest. With 'kvm=off' cpu flag the device is not >

Re: [PATCH v3 2/4] chardev/spice: make qemu_chr_open_spice_port static

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 12:13 PM, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > include/chardev/spice.h | 3 --- > chardev/spice.c | 8 > 2 files changed, 4 insertions(+), 7 deletions(-) > Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH] docker.py: always use --rm

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 12:44 PM, Paolo Bonzini wrote: > Avoid that containers pile up. > > Signed-off-by: Paolo Bonzini > --- > tests/docker/Makefile.include | 1 - > tests/docker/docker.py| 4 ++-- > 2 files changed, 2 insertions(+), 3 deletions(-) > > diff --git a/tests/docker/Makefile.include b/

Re: [REPORT] Nightly Performance Tests - Wednesday, September 16, 2020

2020-09-17 Thread Ahmed Karaman
On Thu, Sep 17, 2020 at 3:28 PM Philippe Mathieu-Daudé wrote: > > On 9/17/20 10:02 AM, Ahmed Karaman wrote: > > On Thu, Sep 17, 2020 at 12:07 AM Ahmed Karaman > > wrote: > >> > >> Host CPU : Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz > >> Host Memory : 15.49 GB > >> > >> Start Time (UT

Re: [PULL 00/24] qtests, unit tests and Cirrus-CI fixes / improvements

2020-09-17 Thread Peter Maydell
On Wed, 16 Sep 2020 at 12:47, Thomas Huth wrote: > > Hi Peter, > > the following changes since commit de39a045bd8d2b49e4f3d07976622c29d58e0bac: > > Merge remote-tracking branch > 'remotes/kraxel/tags/vga-20200915-pull-request' into staging (2020-09-15 > 14:25:05 +0100) > > are available in th

Re: [PATCH 1/3] block/nvme: Initialize constant values with const_le32()

2020-09-17 Thread Philippe Mathieu-Daudé
On 9/17/20 11:55 AM, Stefan Hajnoczi wrote: > On Wed, Sep 16, 2020 at 10:40:02PM +0200, Philippe Mathieu-Daudé wrote: >> To avoid multiple endianess conversion, as we know the device >> registers are in little-endian, directly use const_le32() with >> constant values. > > Can cpu_to_X() be extend

<    1   2   3   4   5   >