Re: Qemu on Windows 10 - no acceleration found

2020-03-20 Thread Holger Schranz
... To early in the morning ... It is on GitHub... on Github: https://github.com/intel/haxm/releases/tag/v7.5.6 others: https://www.softpedia.com/get/Programming/Other-Programming-Files/Intel-Hardware-Accelerated-Execution-Manager.shtml

Re: Qemu on Windows 10 - no acceleration found

2020-03-20 Thread Holger Schranz
Hi Jerry, have you read the instructtions on Intel: https://github.com/intel/haxm/wiki/Installation-Instructions-on-Windows May be this helps you Best regards Holger Am 20.03.20 um 21:22 schrieb Jerry Geis: So I tried --enable-whpx and I get Invalid option. Im on Windows 10 and QEMU 4.2.0

[PATCH] target/mips: Fix loongson multimedia condition instructions

2020-03-20 Thread Jiaxun Yang
Loongson multimedia condition instructions were previously implemented as write 0 to rd due to lack of documentation. So I just confirmed with Loongson about their encoding and implemented them correctly. Signed-off-by: Jiaxun Yang --- target/mips/translate.c | 40

[PATCH 1/1] spapr/rtas: Add MinMem to ibm, get-system-parameter RTAS call

2020-03-20 Thread Leonardo Bras
Add support for MinMem SPLPAR Characteristic on emulated RTAS call ibm,get-system-parameter. MinMem represents Minimum Memory, that is described in LOPAPR as: The minimum amount of main store that is needed to power on the partition. Minimum memory is expressed in MB of storage. This provides a

Re: [PATCH] gdbstub: add support to Xfer:auxv:read: packet

2020-03-20 Thread Lirong Yuan
On Fri, Mar 20, 2020 at 2:17 AM Alex Bennée wrote: > > Lirong Yuan writes: > > > On Fri, Mar 6, 2020 at 5:01 PM Lirong Yuan wrote: > > > >> This allows gdb to access the target’s auxiliary vector, > >> which can be helpful for telling system libraries important details > >> about the hardware,

[RFC PATCH] target/ppc: Add capability for enabling secure guests

2020-03-20 Thread Fabiano Rosas
Making use of ppc's Protected Execution Facility (PEF) feature, a guest can become a secure guest (aka. secure VM - SVM) and have its memory protected from access by the host. This feature is mediated by a piece of firmware called the Ultravisor (UV). The transition from a regular to a secure VM

Re: [PATCH v2 1/1] device_tree: Add info message when dumping dtb to file

2020-03-20 Thread Alistair Francis
On Wed, Mar 18, 2020 at 9:03 PM Leonardo Bras wrote: > > When dumping dtb to a file, qemu exits silently before starting the VM. > > Add info message so user can easily track why the proccess exits. > Add error message if dtb dump failed. > > Signed-off-by: Leonardo Bras Thanks for the patch

[PULL 0/1] DTC queue for 5.0

2020-03-20 Thread Alistair Francis
-20200320-1 for you to fetch changes up to 9f252c7c88eacbf21dadcfe117b0d08f2e88ceeb: device_tree: Add info message when dumping dtb to file (2020-03-20 14:55:44 -0700) DTC patches for 5.0

[PULL 1/1] device_tree: Add info message when dumping dtb to file

2020-03-20 Thread Alistair Francis
From: Leonardo Bras When dumping dtb to a file, qemu exits silently before starting the VM. Add info message so user can easily track why the proccess exits. Add error message if dtb dump failed. Signed-off-by: Leonardo Bras Message-Id: <20200319040326.391090-1-leona...@linux.ibm.com>

[PATCH v4] block/nvme: introduce PMR support from NVMe 1.4 spec

2020-03-20 Thread Andrzej Jakowski
This patch introduces support for PMR that has been defined as part of NVMe 1.4 spec. User can now specify a pmrdev option that should point to HostMemoryBackend. pmrdev memory region will subsequently be exposed as PCI BAR 2 in emulated NVMe device. Guest OS can perform mmio read and writes to

Re: [PATCH v11 03/16] s390x: protvirt: Support unpack facility

2020-03-20 Thread Bruce Rogers
On Thu, 2020-03-19 at 09:19 -0400, Janosch Frank wrote: > The unpack facility provides the means to setup a protected guest. A > protected guest cannot be introspected by the hypervisor or any > user/administrator of the machine it is running on. > > Protected guests are encrypted at rest and

Re: [Qemu-devel] [PULL 2/3] hmp: Update info vnc

2020-03-20 Thread Dr. David Alan Gilbert
* Peter Maydell (peter.mayd...@linaro.org) wrote: > On Mon, 17 Jul 2017 at 10:40, Gerd Hoffmann wrote: > > > > From: "Dr. David Alan Gilbert" > > > > The QMP query-vnc interfaces have gained a lot more information that > > the HMP interfaces hasn't got yet. Update it. > > > > Note the output

Re: Qemu on Windows 10 - no acceleration found

2020-03-20 Thread Jerry Geis
So I tried --enable-whpx and I get Invalid option. Im on Windows 10 and QEMU 4.2.0 I'm confused. Then I don't know where to download the HAXM. The place I found is GIT and it wants the user to compile it. I was looking for just an EXE. Thanks Jerry

Re: [PATCH v14 Kernel 7/7] vfio: Selective dirty page tracking if IOMMU backed device pins pages

2020-03-20 Thread Alex Williamson
On Thu, 19 Mar 2020 02:24:33 -0400 Yan Zhao wrote: > On Thu, Mar 19, 2020 at 03:41:14AM +0800, Kirti Wankhede wrote: > > diff --git a/drivers/vfio/vfio_iommu_type1.c > > b/drivers/vfio/vfio_iommu_type1.c > > index 912629320719..deec09f4b0f6 100644 > > --- a/drivers/vfio/vfio_iommu_type1.c > >

Re: discard and v2 qcow2 images

2020-03-20 Thread Alberto Garcia
On Fri 20 Mar 2020 08:35:44 PM CET, Eric Blake wrote: >> This flag is however only supported when qcow_version >= 3. In older >> images the cluster is simply deallocated, exposing any possible >> previous data from the backing file. > > Discard is advisory, and has no requirements that discarded

Re: discard and v2 qcow2 images

2020-03-20 Thread Eric Blake
On 3/20/20 1:58 PM, Alberto Garcia wrote: Hi, when full_discard is false in discard_in_l2_slice() then the selected cluster should be deallocated and it should read back as zeroes. This is done by clearing the cluster offset field and setting OFLAG_ZERO in the L2 entry. This flag is however

Re: [PATCH v14 Kernel 5/7] vfio iommu: Update UNMAP_DMA ioctl to get dirty bitmap before unmap

2020-03-20 Thread Alex Williamson
On Sat, 21 Mar 2020 00:44:32 +0530 Kirti Wankhede wrote: > On 3/20/2020 9:17 PM, Alex Williamson wrote: > > On Fri, 20 Mar 2020 09:40:39 -0600 > > Alex Williamson wrote: > > > >> On Fri, 20 Mar 2020 04:35:29 -0400 > >> Yan Zhao wrote: > >> > >>> On Thu, Mar 19, 2020 at 03:41:12AM +0800,

Re: [PATCH v3] block/nvme: introduce PMR support from NVMe 1.4 spec

2020-03-20 Thread Stefan Hajnoczi
On Fri, Mar 20, 2020 at 5:48 PM Andrzej Jakowski wrote: > > On 3/20/20 8:45 AM, Stefan Hajnoczi wrote: > > Please use qemu_ram_writeback() so that pmem_persist() and qemu_msync() > > are used as appropriate. > > Thx! > qemu_ram_writeback() doesn't return any status. How can I know that actual >

Re: Qemu on Windows 10 - no acceleration found

2020-03-20 Thread Stefan Weil
Am 20.03.20 um 18:20 schrieb Jerry Geis: > Hi All, > > I have tried QEMU on Windows 10 host with and without HyperV active in > the features list. > Neither seemed to affect the "really slow" speed. Either option > results in -enable-kvm giving "no acceleration found". > > How do I enable

Re: [PATCH v14 Kernel 5/7] vfio iommu: Update UNMAP_DMA ioctl to get dirty bitmap before unmap

2020-03-20 Thread Kirti Wankhede
On 3/20/2020 9:17 PM, Alex Williamson wrote: On Fri, 20 Mar 2020 09:40:39 -0600 Alex Williamson wrote: On Fri, 20 Mar 2020 04:35:29 -0400 Yan Zhao wrote: On Thu, Mar 19, 2020 at 03:41:12AM +0800, Kirti Wankhede wrote: DMA mapped pages, including those pinned by mdev vendor drivers,

[PATCH-for-5.0 3/4] tests/docker: Use Python3 PyYAML in the Fedora image

2020-03-20 Thread Philippe Mathieu-Daudé
The Python2 PyYAML is now pointless, switch to the Python3 version. Fixes: bcbf27947 (docker: move tests from python2 to python3) Signed-off-by: Philippe Mathieu-Daudé --- tests/docker/dockerfiles/fedora.docker | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 4/4] tests/docker: Add libepoxy and libudev packages to the Fedora image

2020-03-20 Thread Philippe Mathieu-Daudé
Install optional dependencies of QEMU to get better coverage. Suggested-by: Peter Maydell Signed-off-by: Philippe Mathieu-Daudé --- tests/docker/dockerfiles/fedora.docker | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/docker/dockerfiles/fedora.docker

[PATCH-for-5.0 0/4] tests/docker: Fixes for 5.0

2020-03-20 Thread Philippe Mathieu-Daudé
Easy fixes for our Docker images. Philippe Mathieu-Daudé (4): tests/docker: Keep package list sorted tests/docker: Install gcrypt devel package in Debian image tests/docker: Use Python3 PyYAML in the Fedora image tests/docker: Add libepoxy and libudev packages to the Fedora image

[PATCH-for-5.0 2/4] tests/docker: Install gcrypt devel package in Debian image

2020-03-20 Thread Philippe Mathieu-Daudé
Apparently Debian Stretch was listing gcrypt as a QEMU dependency, but this is not the case anymore in Buster, so we need to install it manually (it it not listed by 'apt-get -s build-dep qemu' in the common debian10.docker anymore). $ ../configure $QEMU_CONFIGURE_OPTS ERROR: User requested

[PATCH 1/4] tests/docker: Keep package list sorted

2020-03-20 Thread Philippe Mathieu-Daudé
Keep package list sorted, this eases rebase/cherry-pick. Fixes: 3a6784813 Signed-off-by: Philippe Mathieu-Daudé --- tests/docker/dockerfiles/centos7.docker | 6 -- tests/docker/dockerfiles/fedora.docker | 6 -- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git

Re: [PATCH v15 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-20 Thread Alex Williamson
On Sat, 21 Mar 2020 00:12:04 +0530 Kirti Wankhede wrote: > On 3/20/2020 11:31 PM, Alex Williamson wrote: > > On Fri, 20 Mar 2020 23:19:14 +0530 > > Kirti Wankhede wrote: > > > >> On 3/20/2020 4:27 AM, Alex Williamson wrote: > >>> On Fri, 20 Mar 2020 01:46:41 +0530 > >>> Kirti Wankhede

discard and v2 qcow2 images

2020-03-20 Thread Alberto Garcia
Hi, when full_discard is false in discard_in_l2_slice() then the selected cluster should be deallocated and it should read back as zeroes. This is done by clearing the cluster offset field and setting OFLAG_ZERO in the L2 entry. This flag is however only supported when qcow_version >= 3. In

Re: [PATCH v6 19/61] target/riscv: vector integer divide instructions

2020-03-20 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:45 AM LIU Zhiwei wrote: > > Signed-off-by: LIU Zhiwei > Reviewed-by: Richard Henderson Reviewed-by: Alistair Francis Alistair > --- > target/riscv/helper.h | 33 +++ > target/riscv/insn32.decode | 8 +++ >

Re: [PATCH v6 17/61] target/riscv: vector integer min/max instructions

2020-03-20 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:41 AM LIU Zhiwei wrote: > > Signed-off-by: LIU Zhiwei > Reviewed-by: Richard Henderson Reviewed-by: Alistair Francis Alistair > --- > target/riscv/helper.h | 33 > target/riscv/insn32.decode | 8 +++ >

Re: [PATCH v6 15/61] target/riscv: vector narrowing integer right shift instructions

2020-03-20 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:37 AM LIU Zhiwei wrote: > > Signed-off-by: LIU Zhiwei > Reviewed-by: Richard Henderson Reviewed-by: Alistair Francis Alistair > --- > target/riscv/helper.h | 13 > target/riscv/insn32.decode | 6 ++ >

Re: [PATCH v5 07/18] s390x: protvirt: Inhibit balloon when switching to protected mode

2020-03-20 Thread Halil Pasic
On Thu, 19 Mar 2020 18:31:11 +0100 David Hildenbrand wrote: > [...] > > >> > >> I asked this question already to Michael (cc) via a different > >> channel, but hare is it again: > >> > >> Why does the balloon driver not support VIRTIO_F_IOMMU_PLATFORM? It > >> is absolutely not clear to me. The

Re: [PATCH v6 13/61] target/riscv: vector bitwise logical instructions

2020-03-20 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:33 AM LIU Zhiwei wrote: > > Signed-off-by: LIU Zhiwei > Reviewed-by: Richard Henderson Reviewed-by: Alistair Francis Alistair > --- > target/riscv/helper.h | 25 > target/riscv/insn32.decode | 9 + >

Re: [PATCH v15 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-20 Thread Kirti Wankhede
On 3/20/2020 11:31 PM, Alex Williamson wrote: On Fri, 20 Mar 2020 23:19:14 +0530 Kirti Wankhede wrote: On 3/20/2020 4:27 AM, Alex Williamson wrote: On Fri, 20 Mar 2020 01:46:41 +0530 Kirti Wankhede wrote: +static int vfio_iova_dirty_bitmap(struct vfio_iommu *iommu, dma_addr_t

Re: [PATCH v6 10/61] target/riscv: vector single-width integer add and subtract

2020-03-20 Thread Alistair Francis
On Tue, Mar 17, 2020 at 8:27 AM LIU Zhiwei wrote: > > Signed-off-by: LIU Zhiwei Reviewed-by: Alistair Francis Alistair > --- > target/riscv/helper.h | 21 ++ > target/riscv/insn32.decode | 10 + > target/riscv/insn_trans/trans_rvv.inc.c | 251

[PATCH] block: Avoid memleak on qcow2 image info failure

2020-03-20 Thread Eric Blake
If we fail to get bitmap info, we must not leak the encryption info. Fixes: b8968c875f403 Fixes: Coverity CID 1421894 Signed-off-by: Eric Blake --- block/qcow2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/block/qcow2.c b/block/qcow2.c index d44b45633dbb..e08917ed8462 100644 ---

Re: [Qemu-devel] [PULL 3/4] qcow2: Add list of bitmaps to ImageInfoSpecificQCow2

2020-03-20 Thread Eric Blake
On 3/20/20 12:57 PM, Peter Maydell wrote: On Mon, 11 Feb 2019 at 20:57, Eric Blake wrote: From: Andrey Shinkevich In the 'Format specific information' section of the 'qemu-img info' command output, the supplemental information about existing QCOW2 bitmaps will be shown, such as a bitmap

Re: [PULL v2 0/1] Slirp patches

2020-03-20 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200320155106.549514-1-marcandre.lur...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Subject: [PULL v2 0/1] Slirp patches Message-id: 20200320155106.549514-1-marcandre.lur...@redhat.com

Re: [PATCH] monitor/hmp-cmds: fix bad indentation in 'info migrate_parameters' cmd output

2020-03-20 Thread Dr. David Alan Gilbert
* Daniel P. Berrangé (berra...@redhat.com) wrote: > On Fri, Mar 20, 2020 at 05:31:17PM +, Dr. David Alan Gilbert wrote: > > (Rearranging the text a bit) > > > > * Markus Armbruster (arm...@redhat.com) wrote: > > > > > David (cc'ed) should be able to tell us which fix is right. > > > > > >

[PATCH v2 2/4] qemu: capabilities: add QEMU_CAPS_VIRTFS_MULTIDEVS

2020-03-20 Thread Christian Schoenebeck
The QEMU 9pfs 'multidevs' option exists since QEMU 4.2, so just set this capability based on that QEMU version. Signed-off-by: Christian Schoenebeck --- src/qemu/qemu_capabilities.c | 5 + src/qemu/qemu_capabilities.h | 1 +

Re: [PATCH v15 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-20 Thread Alex Williamson
On Fri, 20 Mar 2020 23:19:14 +0530 Kirti Wankhede wrote: > On 3/20/2020 4:27 AM, Alex Williamson wrote: > > On Fri, 20 Mar 2020 01:46:41 +0530 > > Kirti Wankhede wrote: > > > >> VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: > >> - Start dirty pages tracking while migration is

[PATCH v2 4/4] qemu: add support for 'multidevs' option

2020-03-20 Thread Christian Schoenebeck
This option prevents misbehaviours on guest if a qemu 9pfs export contains multiple devices, due to the potential file ID collisions this otherwise may cause. Signed-off-by: Christian Schoenebeck --- src/qemu/qemu_command.c | 7 +++ src/qemu/qemu_domain.c | 12 2 files

[PATCH v2 1/4] docs: virtfs: add section separators

2020-03-20 Thread Christian Schoenebeck
Signed-off-by: Christian Schoenebeck --- docs/formatdomain.html.in | 7 +++ 1 file changed, 7 insertions(+) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 594146009d..cc2c671c14 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -4084,13

[PATCH v2 0/4] add support for QEMU 9pfs 'multidevs' option

2020-03-20 Thread Christian Schoenebeck
QEMU 4.2 added a new option 'multidevs' for 9pfs. The following patch adds support for this new option to libvirt. In short, what is this about: to distinguish files uniquely from each other in general, numeric file IDs are typically used for comparison, which in practice is the combination of a

[PATCH v2 3/4] conf: add 'multidevs' option

2020-03-20 Thread Christian Schoenebeck
Introduce new 'multidevs' option for filesystem. This option prevents misbehaviours on guest if a qemu 9pfs export contains multiple devices, due to the potential file ID collisions this otherwise may cause. Signed-off-by: Christian Schoenebeck --- docs/formatdomain.html.in

Re: [PATCH v3] block/nvme: introduce PMR support from NVMe 1.4 spec

2020-03-20 Thread Andrzej Jakowski
On 3/20/20 8:45 AM, Stefan Hajnoczi wrote: > Please use qemu_ram_writeback() so that pmem_persist() and qemu_msync() > are used as appropriate. Thx! qemu_ram_writeback() doesn't return any status. How can I know that actual msync succeds? Also qemu_ram_writeback() requires me to include

Re: [Qemu-devel] [PULL 3/4] qcow2: Add list of bitmaps to ImageInfoSpecificQCow2

2020-03-20 Thread Peter Maydell
On Mon, 11 Feb 2019 at 20:57, Eric Blake wrote: > > From: Andrey Shinkevich > > In the 'Format specific information' section of the 'qemu-img info' > command output, the supplemental information about existing QCOW2 > bitmaps will be shown, such as a bitmap name, flags and granularity: Hi;

Re: [PATCH v15 Kernel 4/7] vfio iommu: Implementation of ioctl for dirty pages tracking.

2020-03-20 Thread Kirti Wankhede
On 3/20/2020 4:27 AM, Alex Williamson wrote: On Fri, 20 Mar 2020 01:46:41 +0530 Kirti Wankhede wrote: VFIO_IOMMU_DIRTY_PAGES ioctl performs three operations: - Start dirty pages tracking while migration is active - Stop dirty pages tracking. - Get dirty pages bitmap. Its user space

Re: [PATCH] monitor/hmp-cmds: fix bad indentation in 'info migrate_parameters' cmd output

2020-03-20 Thread Daniel P . Berrangé
On Fri, Mar 20, 2020 at 05:31:17PM +, Dr. David Alan Gilbert wrote: > (Rearranging the text a bit) > > * Markus Armbruster (arm...@redhat.com) wrote: > > > David (cc'ed) should be able to tell us which fix is right. > > > > @tls_creds and @tls_hostname look like they could have the same

Re: [PATCH v2 6/6] scripts/coverity-scan: Add Docker support

2020-03-20 Thread Paolo Bonzini
On 19/03/20 20:33, Peter Maydell wrote: > +# TODO: how do you get 'docker build' to print the output of the > +# commands it is running to its stdout? This would be useful for debug. > +DOCKER_BUILDKIT=1 docker build -t coverity-scanner \ > + --secret

Re: [PULL 06/35] spapr: Fail CAS if option vector table cannot be parsed

2020-03-20 Thread Peter Maydell
On Mon, 3 Feb 2020 at 06:11, David Gibson wrote: > > From: Greg Kurz > > Most of the option vector helpers have assertions to check their > arguments aren't null. The guest can provide an arbitrary address > for the CAS structure that would result in such null arguments. > Fail CAS with

Re: [PATCH] monitor/hmp-cmds: fix bad indentation in 'info migrate_parameters' cmd output

2020-03-20 Thread Dr. David Alan Gilbert
(Rearranging the text a bit) * Markus Armbruster (arm...@redhat.com) wrote: > David (cc'ed) should be able to tell us which fix is right. > > @tls_creds and @tls_hostname look like they could have the same issue. A certain Markus removed the Null checks in 8cc99dc because 4af245d guaranteed

Re: [PATCH] hw/rdma/vmw/pvrdma_dev_ring: Replace strncpy with pstrcpy

2020-03-20 Thread Julia Suvorova
On Fri, Mar 20, 2020 at 4:20 PM Stefan Hajnoczi wrote: > > On Wed, Mar 18, 2020 at 02:48:49PM +0100, Julia Suvorova wrote: > > ring->name is defined as 'char name[MAX_RING_NAME_SZ]'. Replace untruncated > > strncpy with QEMU function. > > This case prevented QEMU from compiling with

Re: [PATCH] Update copyright date for user-facing copyright strings

2020-03-20 Thread Philippe Mathieu-Daudé
On 3/16/20 12:20 PM, Peter Maydell wrote: Update the copyright date to 2020 for the copyright strings which are user-facing and represent overall copyright info for all of QEMU. Reported-by: John Arbuckle Signed-off-by: Peter Maydell --- include/qemu-common.h | 2 +- docs/conf.py

Re: [PATCH 1/1] s390/ipl: fix off-by-one in update_machine_ipl_properties()

2020-03-20 Thread Cornelia Huck
On Fri, 20 Mar 2020 15:31:01 +0100 Halil Pasic wrote: > In update_machine_ipl_properties() the array ascii_loadparm needs to > hold the 8 char lodparm and a string terminating zero char. s/lodparm/loadparm/ > Let's increase the size of ascii_loadparm accordingly. > > Signed-off-by: Halil

Re: [RFC PATCH for 5.0] configure: disable MTTCG for MIPS guests

2020-03-20 Thread Alex Bennée
Aleksandar Markovic writes: > пет, 20. мар 2020. у 12:45 Alex Bennée је написао/ла: >> >> While debugging check-acceptance failures I found an instability in >> the mips64el test case. Briefly the test case: >> >> retry.py -n 100 -c -- ./mips64el-softmmu/qemu-system-mips64el \ >>

Qemu on Windows 10 - no acceleration found

2020-03-20 Thread Jerry Geis
Hi All, I have tried QEMU on Windows 10 host with and without HyperV active in the features list. Neither seemed to affect the "really slow" speed. Either option results in -enable-kvm giving "no acceleration found". How do I enable acceleration on QEMU for windows. Jerry

Re: [PATCH v2 4/6] linux-user/flatload.c: Use "" for include of QEMU header target_flat.h

2020-03-20 Thread Richard Henderson
On 3/19/20 12:33 PM, Peter Maydell wrote: > The target_flat.h file is a QEMU header, so we should include it using > quotes, not angle brackets. > > Coverity otherwise is unable to find the header: > > "../linux-user/flatload.c", line 40: error #1712: cannot open source file >

Re: [PATCH v2 2/6] thread.h: Fix Coverity version of qemu_cond_timedwait()

2020-03-20 Thread Richard Henderson
On 3/19/20 12:33 PM, Peter Maydell wrote: > For Coverity's benefit, we provide simpler versions of functions like > qemu_mutex_lock(), qemu_cond_wait() and qemu_cond_timedwait(). When > we added qemu_cond_timedwait() in commit 3dcc9c6ec4ea, a cut and > paste error meant that the Coverity version

Re: [PATCH v2 3/6] thread.h: Remove trailing semicolons from Coverity qemu_mutex_lock() etc

2020-03-20 Thread Richard Henderson
On 3/19/20 12:33 PM, Peter Maydell wrote: > All the Coverity-specific definitions of qemu_mutex_lock() and friends > have a trailing semicolon. This works fine almost everywhere because > of QEMU's mandatory-braces coding style and because most callsites are > simple, but target/s390x/sigp.c has a

Re: [PATCH v2 1/6] osdep.h: Drop no-longer-needed Coverity workarounds

2020-03-20 Thread Richard Henderson
On 3/19/20 12:33 PM, Peter Maydell wrote: > In commit a1a98357e3fd in 2018 we added some workarounds for Coverity > not being able to handle the _Float* types introduced by recent > glibc. Newer versions of the Coverity scan tools have support for > these types, and will fail with errors about

Re: [RFC PATCH for 5.0] configure: disable MTTCG for MIPS guests

2020-03-20 Thread Aleksandar Markovic
пет, 20. мар 2020. у 12:45 Alex Bennée је написао/ла: > > While debugging check-acceptance failures I found an instability in > the mips64el test case. Briefly the test case: > > retry.py -n 100 -c -- ./mips64el-softmmu/qemu-system-mips64el \ > -display none -vga none -serial mon:stdio \ >

Re: [RFC PATCH for 5.0] configure: disable MTTCG for MIPS guests

2020-03-20 Thread Aleksandar Markovic
пет, 20. мар 2020. у 18:08 Aleksandar Markovic < aleksandar.qemu.de...@gmail.com> је написао/ла: > > пет, 20. мар 2020. у 12:45 Alex Bennée је написао/ла: > > > > While debugging check-acceptance failures I found an instability in > > the mips64el test case. Briefly the test case: > > > >

[RFC v6 24/24] hw/arm/smmuv3: Allow MAP notifiers

2020-03-20 Thread Eric Auger
We now have all bricks to support nested paging. This uses MAP notifiers to map the MSIs. So let's allow MAP notifiers to be registered. Signed-off-by: Eric Auger --- hw/arm/smmuv3.c | 8 1 file changed, 8 deletions(-) diff --git a/hw/arm/smmuv3.c b/hw/arm/smmuv3.c index

[RFC v6 23/24] hw/arm/smmuv3: Implement fault injection

2020-03-20 Thread Eric Auger
We convert iommu_fault structs received from the kernel into the data struct used by the emulation code and record the evnts into the virtual event queue. Signed-off-by: Eric Auger --- v3 -> v4: - fix compil issue on mingw Exhaustive mapping remains to be done --- hw/arm/smmuv3.c | 71

[RFC v6 22/24] hw/arm/smmuv3: Pass stage 1 configurations to the host

2020-03-20 Thread Eric Auger
In case PASID PciOps are set for the device we call the set_pasid_table() callback on each STE update. This allows to pass the guest stage 1 configuration to the host and apply it at physical level. Signed-off-by: Eric Auger --- v4 -> v5: - Use PciOps instead of config notifiers v3 -> v4: -

[RFC v6 21/24] hw/arm/smmuv3: Fill the IOTLBEntry leaf field on NH_VA invalidation

2020-03-20 Thread Eric Auger
Let's propagate the leaf attribute throughout the invalidation path. This hint is used to reduce the scope of the invalidations to the last level of translation. Not enforcing it induces large performance penalties in nested mode. Signed-off-by: Eric Auger --- hw/arm/smmuv3.c | 16

[RFC v6 19/24] hw/arm/smmuv3: Store the PASID table GPA in the translation config

2020-03-20 Thread Eric Auger
For VFIO integration we will need to pass the Context Descriptor (CD) table GPA to the host. The CD table is also referred to as the PASID table. Its GPA corresponds to the s1ctrptr field of the Stream Table Entry. So let's decode and store it in the configuration structure. Signed-off-by: Eric

[RFC v6 18/24] hw/arm/smmuv3: Advertise MSI_TRANSLATE attribute

2020-03-20 Thread Eric Auger
The SMMUv3 has the peculiarity to translate MSI transactionss. let's advertise the corresponding attribute. Signed-off-by: Eric Auger --- --- hw/arm/smmuv3.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/arm/smmuv3.c b/hw/arm/smmuv3.c index e33eabd028..9bea5f65ae 100644 ---

Re: [PATCH v2 1/2] lockable: fix __COUNTER__ macro to be referenced properly

2020-03-20 Thread Richard Henderson
On 3/19/20 4:34 PM, dnbrd...@gmail.com wrote: > From: Daniel Brodsky > > - __COUNTER__ doesn't work with ## concat > - replaced ## with glue() macro so __COUNTER__ is evaluated > > Fixes: 3284c3ddc4 > > Signed-off-by: Daniel Brodsky > --- > include/qemu/lockable.h | 2 +- >

[RFC v6 16/24] vfio/pci: Set up the DMA FAULT region

2020-03-20 Thread Eric Auger
Set up the fault region which is composed of the actual fault queue (mmappable) and a header used to handle it. The fault queue is mmapped. Signed-off-by: Eric Auger --- v4 -> v5: - use a single DMA FAULT region. No version selection anymore --- hw/vfio/pci.c | 64

[RFC v6 20/24] hw/arm/smmuv3: Fill the IOTLBEntry arch_id on NH_VA invalidation

2020-03-20 Thread Eric Auger
When the guest invalidates one S1 entry, it passes the asid. When propagating this invalidation downto the host, the asid information also must be passed. So let's fill the arch_id field introduced for that purpose. Signed-off-by: Eric Auger --- hw/arm/smmuv3.c | 1 + 1 file changed, 1

[RFC v6 11/24] vfio: Introduce helpers to DMA map/unmap a RAM section

2020-03-20 Thread Eric Auger
Let's introduce two helpers that allow to DMA map/unmap a RAM section. Those helpers will be called for nested stage setup in another call site. Also the vfio_listener_region_add/del() structure may be clearer. Signed-off-by: Eric Auger --- v5 -> v6: - add Error ** --- hw/vfio/common.c |

[RFC v6 13/24] vfio: Pass stage 1 MSI bindings to the host

2020-03-20 Thread Eric Auger
We register the stage1 MSI bindings when enabling the vectors and we unregister them on container disconnection. Signed-off-by: Eric Auger --- v4 -> v5: - use VFIO_IOMMU_SET_MSI_BINDING v2 -> v3: - only register the notifier if the IOMMU translates MSIs - record the msi bindings in a

[RFC v6 14/24] vfio: Helper to get IRQ info including capabilities

2020-03-20 Thread Eric Auger
As done for vfio regions, add helpers to retrieve irq info including their optional capabilities. Signed-off-by: Eric Auger --- hw/vfio/common.c | 97 +++ hw/vfio/trace-events | 1 + include/hw/vfio/vfio-common.h | 7 +++ 3 files changed,

[RFC v6 17/24] vfio/pci: Implement the DMA fault handler

2020-03-20 Thread Eric Auger
Whenever the eventfd is triggered, we retrieve the DMA fault(s) from the mmapped fault region and inject them in the iommu memory region. Signed-off-by: Eric Auger --- hw/vfio/pci.c | 50 ++ hw/vfio/pci.h | 1 + 2 files changed, 51 insertions(+)

[RFC v6 10/24] vfio: Introduce hostwin_from_range helper

2020-03-20 Thread Eric Auger
Let's introduce a hostwin_from_range() helper that returns the hostwin encapsulating an IOVA range or NULL if none is found. This improves the readibility of callers and removes the usage of hostwin_found. Signed-off-by: Eric Auger --- hw/vfio/common.c | 36 +---

[RFC v6 12/24] vfio: Set up nested stage mappings

2020-03-20 Thread Eric Auger
In nested mode, legacy vfio_iommu_map_notify cannot be used as there is no "caching" mode and we do not trap on map. On Intel, vfio_iommu_map_notify was used to DMA map the RAM through the host single stage. With nested mode, we need to setup the stage 2 and the stage 1 separately. This patch

[RFC v6 08/24] pci: introduce PCIPASIDOps to PCIDevice

2020-03-20 Thread Eric Auger
From: Liu Yi L This patch introduces PCIPASIDOps for IOMMU related operations. https://lists.gnu.org/archive/html/qemu-devel/2018-03/msg00078.html https://lists.gnu.org/archive/html/qemu-devel/2018-03/msg00940.html So far, to setup virt-SVA for assigned SVA capable device, needs to configure

[RFC v6 15/24] vfio/pci: Register handler for iommu fault

2020-03-20 Thread Eric Auger
We use the new extended IRQ VFIO_IRQ_TYPE_NESTED type and VFIO_IRQ_SUBTYPE_DMA_FAULT subtype to set/unset a notifier for physical DMA faults. The associated eventfd is triggered, in nested mode, whenever a fault is detected at IOMMU physical level. The actual handler will be implemented in

[RFC v6 07/24] iommu: Introduce generic header

2020-03-20 Thread Eric Auger
This header is meant to exposes data types used by several IOMMU devices such as struct for SVA and nested stage configuration. Signed-off-by: Eric Auger --- include/hw/iommu/iommu.h | 28 1 file changed, 28 insertions(+) create mode 100644 include/hw/iommu/iommu.h

[RFC v6 09/24] vfio: Force nested if iommu requires it

2020-03-20 Thread Eric Auger
In case we detect the address space is translated by a virtual IOMMU which requires HW nested paging to integrate with VFIO, let's set up the container with the VFIO_TYPE1_NESTING_IOMMU iommu_type. Signed-off-by: Eric Auger --- v4 -> v5: - fail immediatly if nested is wanted but not supported

[RFC v6 03/24] memory: Add IOMMU_ATTR_VFIO_NESTED IOMMU memory region attribute

2020-03-20 Thread Eric Auger
We introduce a new IOMMU Memory Region attribute, IOMMU_ATTR_VFIO_NESTED that tells whether the virtual IOMMU requires HW nested paging for VFIO integration. Current Intel virtual IOMMU device supports "Caching Mode" and does not require 2 stages at physical level to be integrated with VFIO.

[RFC v6 05/24] memory: Introduce IOMMU Memory Region inject_faults API

2020-03-20 Thread Eric Auger
This new API allows to inject @count iommu_faults into the IOMMU memory region. Signed-off-by: Eric Auger --- include/exec/memory.h | 25 + memory.c | 10 ++ 2 files changed, 35 insertions(+) diff --git a/include/exec/memory.h

[RFC v6 04/24] memory: Add IOMMU_ATTR_MSI_TRANSLATE IOMMU memory region attribute

2020-03-20 Thread Eric Auger
We introduce a new IOMMU Memory Region attribute, IOMMU_ATTR_MSI_TRANSLATE which tells whether the virtual IOMMU translates MSIs. ARM SMMU will expose this attribute since, as opposed to Intel DMAR, MSIs are translated as any other DMA requests. Signed-off-by: Eric Auger ---

[RFC v6 06/24] memory: Add arch_id and leaf fields in IOTLBEntry

2020-03-20 Thread Eric Auger
TLB entries are usually tagged with some ids such as the asid or pasid. When propagating an invalidation command from the guest to the host, we need to pass this id. Also we add a leaf field which indicates, in case of invalidation notification, whether only cache entries for the last level of

[RFC v6 01/24] update-linux-headers: Import iommu.h

2020-03-20 Thread Eric Auger
Update the script to import the new iommu.h uapi header. Signed-off-by: Eric Auger --- scripts/update-linux-headers.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/update-linux-headers.sh b/scripts/update-linux-headers.sh index 29c27f4681..5b64ee3912 100755 ---

[RFC v6 02/24] header update against 5.6.0-rc3 and IOMMU/VFIO nested stage APIs

2020-03-20 Thread Eric Auger
This is an update against https://github.com/eauger/linux/tree/will-arm-smmu-updates-2stage-v10 Signed-off-by: Eric Auger --- linux-headers/COPYING | 2 + linux-headers/asm-x86/kvm.h | 1 + linux-headers/linux/iommu.h | 375

[RFC v6 00/24] vSMMUv3/pSMMUv3 2 stage VFIO integration

2020-03-20 Thread Eric Auger
Up to now vSMMUv3 has not been integrated with VFIO. VFIO integration requires to program the physical IOMMU consistently with the guest mappings. However, as opposed to VTD, SMMUv3 has no "Caching Mode" which allows easy trapping of guest mappings. This means the vSMMUV3 cannot use the same VFIO

[Bug 1867519] Re: qemu 4.2 segfaults on VF detach

2020-03-20 Thread Launchpad Bug Tracker
This bug was fixed in the package qemu - 1:4.2-3ubuntu3 --- qemu (1:4.2-3ubuntu3) focal; urgency=medium * d/p/stable/lp-1867519-*: Stabilize qemu 4.2 with upstream patches @qemu-stable (LP: #1867519) -- Christian Ehrhardt Wed, 18 Mar 2020 13:57:57 +0100 ** Changed in: qemu

Re: [PULL v2 05/13] target/rx: CPU definitions

2020-03-20 Thread Peter Maydell
On Fri, 20 Mar 2020 at 16:32, Philippe Mathieu-Daudé wrote: > -fwrapv is here indeed. > > I use >

Re: [PULL v2 05/13] target/rx: CPU definitions

2020-03-20 Thread Philippe Mathieu-Daudé
On 3/20/20 5:21 PM, Peter Maydell wrote: On Fri, 20 Mar 2020 at 16:19, Richard Henderson wrote: On 3/20/20 9:04 AM, Philippe Mathieu-Daudé wrote: Not related to this patch, but this line generates a warning with Clang: CC rx-softmmu/target/rx/cpu.o target/rx/cpu.c:158:33: warning:

Re: [PATCH v3 3/3] Acceptance test: provides to use RDMA transport for migration test

2020-03-20 Thread Willian Rampazzo
Hi Oksana, On Fri, Mar 20, 2020 at 12:16 PM Oksana Vohchana wrote: > > Adds test for RDMA migration check > > Signed-off-by: Oksana Vohchana > --- > tests/acceptance/migration.py | 12 > 1 file changed, 12 insertions(+) > > diff --git a/tests/acceptance/migration.py

Re: [PATCH v9 02/10] scripts: Coccinelle script to use ERRP_AUTO_PROPAGATE()

2020-03-20 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > 20.03.2020 16:58, Markus Armbruster wrote: >> Vladimir Sementsov-Ogievskiy writes: [...] >>> I will not be surprised, if we missed some more interesting cases :) >>> But we should proceed. What is our plan? Will you queue v10 for 5.1? >> >> v10's PATCH 1+2

Re: [PATCH v3 2/3] Acceptance test: provides new functions

2020-03-20 Thread Willian Rampazzo
Hi Oksana, On Fri, Mar 20, 2020 at 12:15 PM Oksana Vohchana wrote: > > Provides new functions related to the rdma migration test > Adds functions to check if service RDMA is enabled and gets > the ip address on the interface where it was configured > > Signed-off-by: Oksana Vohchana > --- >

Re: [PULL v2 05/13] target/rx: CPU definitions

2020-03-20 Thread Peter Maydell
On Fri, 20 Mar 2020 at 16:19, Richard Henderson wrote: > > On 3/20/20 9:04 AM, Philippe Mathieu-Daudé wrote: > > Not related to this patch, but this line generates a warning with Clang: > > > > CC rx-softmmu/target/rx/cpu.o > > target/rx/cpu.c:158:33: warning: The result of the left shift

Re: [PULL 0/4] Python queue for 5.0 soft freeze

2020-03-20 Thread Philippe Mathieu-Daudé
On 3/20/20 5:14 PM, Peter Maydell wrote: On Fri, 20 Mar 2020 at 16:11, Philippe Mathieu-Daudé wrote: On 3/20/20 4:59 PM, Peter Maydell wrote: On Wed, 18 Mar 2020 at 01:12, Eduardo Habkost wrote: The following changes since commit d649689a8ecb2e276cc20d3af6d416e3c299cb17: Merge

Re: [PATCH v10 2/9] scripts: Coccinelle script to use ERRP_AUTO_PROPAGATE()

2020-03-20 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Script adds ERRP_AUTO_PROPAGATE macro invocation where appropriate and > does corresponding changes in code (look for details in > include/qapi/error.h) > > Usage example: > spatch --sp-file scripts/coccinelle/auto-propagated-errp.cocci \ > --macro-file

Re: [PULL v2 05/13] target/rx: CPU definitions

2020-03-20 Thread Richard Henderson
On 3/20/20 9:04 AM, Philippe Mathieu-Daudé wrote: > Not related to this patch, but this line generates a warning with Clang: > >   CC  rx-softmmu/target/rx/cpu.o > target/rx/cpu.c:158:33: warning: The result of the left shift is undefined > because the left operand is negative >     address =

Re: [PATCH] ppc/ppc405_boards: Remove unnecessary NULL check

2020-03-20 Thread Markus Armbruster
Philippe Mathieu-Daudé writes: > This code is inside the "if (dinfo)" condition, so testing > again here whether it is NULL is unnecessary. > > Fixes: dd59bcae7 (Don't size flash memory to match backing image) > Reported-by: Coverity (CID 1421917) > Suggested-by: Peter Maydell > Signed-off-by:

Re: [PULL 0/4] Python queue for 5.0 soft freeze

2020-03-20 Thread Peter Maydell
On Fri, 20 Mar 2020 at 16:11, Philippe Mathieu-Daudé wrote: > > On 3/20/20 4:59 PM, Peter Maydell wrote: > > On Wed, 18 Mar 2020 at 01:12, Eduardo Habkost wrote: > >> > >> The following changes since commit > >> d649689a8ecb2e276cc20d3af6d416e3c299cb17: > >> > >>Merge remote-tracking branch

  1   2   3   >