Re: [Qemu-devel] [PATCH v2 0/3] script for crash-testing -device

2017-05-12 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20170513033316.22395-1-ehabk...@redhat.com Subject: [Qemu-devel] [PATCH v2 0/3] script for crash-testing -device === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1

[Qemu-devel] [PATCH v2 3/3] scripts: Test script to look for -device crashes

2017-05-12 Thread Eduardo Habkost
Test code to check if we can crash QEMU using -device. It will test all accel/machine/device combinations by default, which may take a few hours (it's more than 90k test cases). There's a "-r" option that makes it test a random sample of combinations. The scripts contains a whitelist for: 1)

[Qemu-devel] [PATCH v2 0/3] script for crash-testing -device

2017-05-12 Thread Eduardo Habkost
Changes v1 -> v2: * Use a simpler method to query QEMU exit code in qemu.py * Use only qemu.py module, instead of qtest.py * New whitelist entries: * "could not find stage1 bootloader" * Segfaults when using devices: a15mpcore_priv, sb16, cs4231a, arm-gicv3 * Format "success" line using

[Qemu-devel] [PATCH v2 1/3] qemu.py: Don't set _popen=None on error/shutdown

2017-05-12 Thread Eduardo Habkost
Keep the Popen object around to we can query its exit code later. To keep the existing 'self._popen is None' checks working, add a is_running() method, that will check if the process is still running. Signed-off-by: Eduardo Habkost --- scripts/qemu.py | 12 +++- 1

[Qemu-devel] [PATCH v2 2/3] qemu.py: Add QEMUMachine.exitcode() method

2017-05-12 Thread Eduardo Habkost
Allow the exit code of QEMU to be queried by scripts. Signed-off-by: Eduardo Habkost --- scripts/qemu.py | 4 1 file changed, 4 insertions(+) diff --git a/scripts/qemu.py b/scripts/qemu.py index 16934f1e02..ebe1c4b919 100644 --- a/scripts/qemu.py +++ b/scripts/qemu.py

[Qemu-devel] [PATCH] maintainers: Add myself as a NetBSD reviewer

2017-05-12 Thread Kamil Rytarowski
I volunteer to review NetBSD patches. Adding myself will help to not miss some of them. Restore NetBSD as a maintained host. All patches to make qemu/pkgsrc building have been emitted to review. Signed-off-by: Kamil Rytarowski --- MAINTAINERS | 6 ++ configure | 1 + 2

Re: [Qemu-devel] [PATCH] tcg: optimize gen_extr_i64_i32()

2017-05-12 Thread Richard Henderson
On 05/12/2017 05:29 PM, Philippe Mathieu-Daudé wrote: Inspired by Richard Henderson comment: http://lists.nongnu.org/archive/html/qemu-devel/2017-05/msg02277.html Patch applied mechanically with this coccinelle semantic patch: @@ expression lo, hi,arg; @@

[Qemu-devel] [PATCH] libvixl: Correct ordering of includes and fix NetBSD build

2017-05-12 Thread Kamil Rytarowski
The __STDC_CONSTANT_MACROS symbol must be defined before including directly or indirectly in order to get support for macros for integer constants like INT8_C(). The vixl/globals.h headers defines __STDC_CONSTANT_MACROS and must be included before other system headers. This change fixes build

Re: [Qemu-devel] [PATCH V4 02/12] net/filter-mirror.c: Add new option to enable vnet support for filter-mirror

2017-05-12 Thread Hailiang Zhang
Hi, On 2017/5/12 9:41, Zhang Chen wrote: We add the vnet_hdr option for filter-mirror, default is disable. If you use virtio-net-pci net driver, please enable it. You can use it for example: -object filter-mirror,id=m0,netdev=hn0,queue=tx,outdev=mirror0,vnet_hdr=on Is there any way to detect

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Xu, Anthony
> -Original Message- > From: Kevin O'Connor [mailto:ke...@koconnor.net] > Sent: Friday, May 12, 2017 5:02 PM > To: Xu, Anthony > Cc: Paolo Bonzini ; qemu-devel@nongnu.org > Subject: Re: [PATCH] target/i386: enable A20 automatically in system >

Re: [Qemu-devel] [RFC v1 8/9] virtio-crypto: add host feature bits support

2017-05-12 Thread Gonglei (Arei)
> From: Cornelia Huck [mailto:cornelia.h...@de.ibm.com] > Sent: Friday, May 12, 2017 7:22 PM > To: Gonglei (Arei) > Cc: qemu-devel@nongnu.org; m...@redhat.com; Huangweidong (C); > pa...@linux.vnet.ibm.com; stefa...@redhat.com; Luonengjun; Linqiangmin; > xin.z...@intel.com; Wubin (H) > Subject: Re:

Re: [Qemu-devel] [RFC v1 6/9] virtio-crypto: rework virtio_crypto_handle_request

2017-05-12 Thread Gonglei (Arei)
> From: Halil Pasic [mailto:pa...@linux.vnet.ibm.com] > Sent: Friday, May 12, 2017 7:02 PM > > > On 05/08/2017 01:38 PM, Gonglei wrote: > > According to the new spec, we should use different > > requst structure to store the data request based > > on whether VIRTIO_CRYPTO_F_MUX_MODE feature bit

Re: [Qemu-devel] [RFC PATCH v4 0/6] optimize various tcg_gen() functions using extract op

2017-05-12 Thread Julia Lawall
On Fri, 12 May 2017, Philippe Mathieu-Daudé wrote: > * Changes from v3 > > Tried to fix wrong previous attempt... > After getting some nice/fast pieces of advice from Coccinelle folks, I tried > to > improved the script (not much inline documentation yet although). > - correctly check if this

[Qemu-devel] [PATCH RESEND v6] qga: Add support network interface statistics in guest-network-get-interfaces command

2017-05-12 Thread ZhiPeng Lu
we can get the network interface statistics inside a virtual machine by guest-network-get-interfaces command. it is very useful for us to monitor and analyze network traffic. Signed-off-by: ZhiPeng Lu Signed-off-by: Daniel P. Berrange ---

[Qemu-devel] [PATCH] ivshmem-server: Detect and use if there is required -lrt linking

2017-05-12 Thread Kamil Rytarowski
ivshmem-server makes use of the POSIX shared memory object interfaces. This library is provided on NetBSD in -lrt (POSIX Real-time Library). Add ./configure check if there is needed -lrt linking for shm_open() and if so use it. Introduce new configure generated variable LIBS_SHMLIB. This fixes

[Qemu-devel] [PATCH] tcg: optimize gen_extr_i64_i32()

2017-05-12 Thread Philippe Mathieu-Daudé
Inspired by Richard Henderson comment: http://lists.nongnu.org/archive/html/qemu-devel/2017-05/msg02277.html Patch applied mechanically with this coccinelle semantic patch: @@ expression lo, hi,arg; @@ -tcg_gen_extrl_i64_i32(lo, arg); -tcg_gen_extrh_i64_i32(hi, arg);

Re: [Qemu-devel] [PATCH v4 6/6] target/sparc: optimize various functions using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 04:38 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé

Re: [Qemu-devel] [PATCH v4 4/6] target/m68k: optimize bcd_flags() using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 04:38 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe

Re: [Qemu-devel] [PATCH v4 5/6] target/ppc: optimize various functions using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 04:38 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe

Re: [Qemu-devel] [PATCH v4 2/6] target/alpha: optimize cvtlq() using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 04:38 PM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé

Re: [Qemu-devel] [PATCH 6/6] spec/vhost-user spec: Add IOMMU support

2017-05-12 Thread Michael S. Tsirkin
On Fri, May 12, 2017 at 04:21:58PM +0200, Maxime Coquelin wrote: > > > On 05/11/2017 08:25 PM, Michael S. Tsirkin wrote: > > On Thu, May 11, 2017 at 02:32:46PM +0200, Maxime Coquelin wrote: > > > This patch specifies and implements the master/slave communication > > > to support device IOTLB in

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Kevin O'Connor
On Fri, May 12, 2017 at 11:19:00PM +, Xu, Anthony wrote: > > SeaBIOS defaults to enabling A20 and it's a rare beast that disables > > it. One could change x86.h:set_a20 and romlayout.S:transition32 to > > only issue the outb() if the inb() indicates a change is needed. That > > would likely

Re: [Qemu-devel] [PATCH v3 08/15] target/sh4: fold ctx->bstate = BS_BRANCH into gen_conditional_jump

2017-05-12 Thread Philippe Mathieu-Daudé
On 05/10/2017 03:26 PM, Aurelien Jarno wrote: Reviewed-by: Richard Henderson Signed-off-by: Aurelien Jarno Reviewed-by: Philippe Mathieu-Daudé --- target/sh4/translate.c | 9 +++-- 1 file changed, 3 insertions(+), 6

Re: [Qemu-devel] [PATCH v3 1/4] ACPI: Add APEI GHES Table Generation support

2017-05-12 Thread Michael S. Tsirkin
On Sun, Apr 30, 2017 at 01:35:03PM +0800, Dongjiu Geng wrote: > This implements APEI GHES Table by passing the error cper info > to the guest via a fw_cfg_blob. After a CPER info is added, an > SEA/SEI exception will be injected into the guest OS. > > Below is the table layout, the max number of

Re: [Qemu-devel] [PATCH v3 05/15] target/sh4: fix BS_STOP exit

2017-05-12 Thread Philippe Mathieu-Daudé
On 05/10/2017 03:26 PM, Aurelien Jarno wrote: When stopping the translation because the state has changed, goto_tb should not be used as it might link TB with different flags. Reviewed-by: Richard Henderson Signed-off-by: Aurelien Jarno Reviewed-by:

Re: [Qemu-devel] [PATCH v3 4/5] target/ppc: using various functions using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
This patch is also incorrect, please see v4. On 05/12/2017 12:35 AM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target

[Qemu-devel] [PULL 8/9] target/s390x: fix SIGNAL PROCESSOR return value

2017-05-12 Thread Richard Henderson
From: Aurelien Jarno The SIGNAL PROCESSOR helper returns its value through the CC register. set_cc_static should be called just after the helper. Signed-off-by: Aurelien Jarno Message-Id: <20170509082800.10756-3-aurel...@aurel32.net> Signed-off-by:

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: optimize rev16() using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
On 05/12/2017 01:50 PM, Richard Henderson wrote: On 05/11/2017 08:35 PM, Philippe Mathieu-Daudé wrote: -tcg_gen_shri_i64(tcg_tmp, tcg_rn, 16); -tcg_gen_andi_i64(tcg_tmp, tcg_tmp, 0x); +tcg_gen_extract_i64(tcg_tmp, tcg_rn, 16, 0x); So your new script didn't work then? This

[Qemu-devel] [PULL 9/9] target/s390x: implement serialization in BRANCH CONDITION

2017-05-12 Thread Richard Henderson
From: Aurelien Jarno Signed-off-by: Aurelien Jarno Message-Id: <20170509082800.10756-4-aurel...@aurel32.net> Signed-off-by: Richard Henderson --- target/s390x/translate.c | 15 +++ 1 file changed, 15 insertions(+) diff

Re: [Qemu-devel] [PATCH v3 5/5] target/sparc: optimize various functions using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
This patch is incorrect, please see v4. On 05/12/2017 12:35 AM, Philippe Mathieu-Daudé wrote: Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target

[Qemu-devel] [PULL 6/9] target/s390x: Use atomic operations for LOAD AND OP

2017-05-12 Thread Richard Henderson
Reviewed-by: Aurelien Jarno Signed-off-by: Richard Henderson --- target/s390x/insn-data.def | 20 ++-- target/s390x/translate.c | 78 +- 2 files changed, 60 insertions(+), 38 deletions(-) diff --git

[Qemu-devel] [PULL 7/9] target/s390x: mask the SIGP order_code using SIGP_ORDER_MASK

2017-05-12 Thread Richard Henderson
From: Aurelien Jarno For that move the definition from kvm.c to cpu.h Reviewed-by: Thomas Huth Reviewed-by: Cornelia Huck Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Aurelien Jarno

[Qemu-devel] [PULL 2/9] target/s390x: Implement LOAD PROGRAM PARAMETER

2017-05-12 Thread Richard Henderson
From: Miroslav Benes Linux arch/s390/kernel/head(64).S uses LPP instruction if it is available in facilities list provided by stfl/stfle instruction. This is the case of newer z/System generations and their qemu definition. The description of LPP is at

[Qemu-devel] [PATCH v4 6/6] target/sparc: optimize various functions using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé --- target/sparc/translate.c | 15

[Qemu-devel] [PULL 5/9] target/s390x: Use atomic operations for COMPARE SWAP

2017-05-12 Thread Richard Henderson
Reviewed-by: Aurelien Jarno Signed-off-by: Richard Henderson --- target/s390x/helper.h | 1 + target/s390x/insn-data.def | 10 +++--- target/s390x/mem_helper.c | 40 ++ target/s390x/translate.c | 83

[Qemu-devel] [PULL 4/9] target/s390x: Implement LOAD PAIR DISJOINT

2017-05-12 Thread Richard Henderson
From: Eric Bischoff Reviewed-by: Aurelien Jarno Signed-off-by: Eric Bischoff Message-Id: <20170228120134.7921-1-ebisch...@suse.com> [rth: Combine the two via insn->data; free the address temps.] Signed-off-by: Richard Henderson

[Qemu-devel] [PULL 1/9] target/s390x: Implement STORE FACILITIES LIST EXTENDED

2017-05-12 Thread Richard Henderson
At the same time, improve STORE FACILITIES LIST so that we don't hard-code the list for all cpus. Signed-off-by: Richard Henderson --- target/s390x/helper.h | 2 ++ target/s390x/insn-data.def | 2 ++ target/s390x/misc_helper.c | 59

[Qemu-devel] [PATCH v4 3/6] target/arm: optimize rev16() using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé --- target/arm/translate-a64.c | 6 ++ 1

[Qemu-devel] [PATCH v4 4/6] target/m68k: optimize bcd_flags() using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé Acked-by: Laurent Vivier

[Qemu-devel] [PULL 3/9] target/s390x: Diagnose specification exception for atomics

2017-05-12 Thread Richard Henderson
All of the interlocked access facility instructions raise a specification exception for unaligned accesses. Do this by using the (previously unused) unaligned_access hook. Reviewed-by: Aurelien Jarno Signed-off-by: Richard Henderson ---

[Qemu-devel] [PATCH v4 2/6] target/alpha: optimize cvtlq() using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé --- target/alpha/translate.c | 3 +-- 1 file

[Qemu-devel] [PULL 0/9] Queued s390 patches

2017-05-12 Thread Richard Henderson
://github.com/rth7680/qemu.git tags/pull-s390-20170512 for you to fetch changes up to 538fad597d898f677f81cb4daacd37e7cdc18e6e: target/s390x: implement serialization in BRANCH CONDITION (2017-05-12 15:48:41 -0700) Queued target/s390

[Qemu-devel] [RFC PATCH v4 0/6] optimize various tcg_gen() functions using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
* Changes from v3 Tried to fix wrong previous attempt... After getting some nice/fast pieces of advice from Coccinelle folks, I tried to improved the script (not much inline documentation yet although). - correctly check if this optimizable? - document as Mersenne number instead of prime (Eric

[Qemu-devel] [RFC PATCH v4 1/6] coccinelle: add a script to optimize tcg op using tcg_gen_extract()

2017-05-12 Thread Philippe Mathieu-Daudé
If you have coccinelle installed you can apply this script using: $ spatch \ --macro-file scripts/cocci-macro-file.h \ --dir target --in-place You can also use directly Peter Senna Tschudin docker image (easier): $ docker run -v `pwd`:`pwd` -w `pwd` petersenna/coccinelle

[Qemu-devel] [PATCH v4 5/6] target/ppc: optimize various functions using extract op

2017-05-12 Thread Philippe Mathieu-Daudé
Patch created mechanically using Coccinelle script via: $ spatch --macro-file scripts/cocci-macro-file.h --in-place \ --sp-file scripts/coccinelle/tcg_gen_extract.cocci --dir target Signed-off-by: Philippe Mathieu-Daudé --- target/ppc/translate.c | 21

[Qemu-devel] [PATCH 3/3] target/xtensa: support output to chardev console

2017-05-12 Thread Max Filippov
In semihosting mode QEMU allows guest to read and write host file descriptors directly, including descriptors 0..2, a.k.a. stdin, stdout and stderr. Sometimes it's desirable to have semihosting console controlled by -serial option, e.g. to connect it to network. Add semihosting console to

[Qemu-devel] [PATCH 2/3] target/xtensa: fix return value of read/write simcalls

2017-05-12 Thread Max Filippov
Return value of read/write simcalls is not calculated correctly in case of operations crossing page boundary and in case of short reads/writes. Read and write simcalls should return the size of data actually read/written or -1 in case of error. Cc: qemu-sta...@nongnu.org Signed-off-by: Max

[Qemu-devel] [PATCH 0/3] target/xtensa semihosting fixes

2017-05-12 Thread Max Filippov
Hello, this series fixes two issues in xtensa semihosting read/write calls: incorrect direction flags used to map physical memory and incorrect return value for requests crossing page boundary, and allows using QEMU chardev for stdout and stderr output in semihosting mode. Max Filippov (3):

[Qemu-devel] [PATCH 1/3] target/xtensa: fix mapping direction in read/write simcalls

2017-05-12 Thread Max Filippov
Read and write simcalls map physical memory to access I/O buffers, but 'read' simcall need to map it for writing and 'write' simcall need to map it for reading, i.e. the opposite of what they do now. Fix that. Cc: qemu-sta...@nongnu.org Signed-off-by: Max Filippov ---

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Xu, Anthony
wrote: > > On 12/05/2017 20:55, Xu, Anthony wrote: > > > If that's the case, QEMU/TCG should work with SeaBios even with > ignoring A20. > > > > > > During SeaBios boot, there are >350 port 92 access, if we don't need to > handle A20, > > > we can make A20 configurable in Seabios, It may reduce

Re: [Qemu-devel] [PATCH v9 01/13] qcow2: Unallocate unmapped zero clusters if no backing file

2017-05-12 Thread John Snow
On 05/12/2017 12:06 PM, Max Reitz wrote: > On 2017-05-11 16:56, Eric Blake wrote: >> [revisiting this older patch version, even though the final version in >> today's pull request changed somewhat from this approach] >> >> On 04/12/2017 04:49 AM, Kevin Wolf wrote: >>> Am 11.04.2017 um 03:17 hat

Re: [Qemu-devel] multiple -append?

2017-05-12 Thread Laszlo Ersek
On 05/12/17 16:20, Rob Landley wrote: > When I feed a second -append to qemu-system-i386 they don't get > concatenated, the second replaces the first. Why is it called "append" then? This behavior dates back to commit a20dd508aa38 ("simplified invocation - added automatic IDE disk geometry

[Qemu-devel] QEMU seg-fault with intermediate image streaming -- bdrv_reopen() in stream_start()

2017-05-12 Thread Kashyap Chamarthy
Reproducer -- [Disk image chain: disk1.qcow2 <- b.qcow2 <- c.qcow2] $ qemu-system-x86_64 -display none -nodefconfig -nodefaults \ -m 512 -device virtio-scsi-pci,id=scsi \ -device virtio-serial-pci \ -drive driver=qcow2,file.driver=file,file.filename=./disk1.qcow2,id=virtio0

Re: [Qemu-devel] [PATCH v3 15/15] target/sh4: use cpu_loop_exit_restore

2017-05-12 Thread Richard Henderson
On 05/10/2017 11:26 AM, Aurelien Jarno wrote: Use cpu_loop_exit_restore when using cpu_restore_state and cpu_loop_exit together. Signed-off-by: Aurelien Jarno --- target/sh4/op_helper.c | 10 ++ 1 file changed, 2 insertions(+), 8 deletions(-) Reviewed-by:

Re: [Qemu-devel] [PATCH v3 14/15] target/sh4: trap unaligned accesses

2017-05-12 Thread Richard Henderson
On 05/10/2017 11:26 AM, Aurelien Jarno wrote: SH4 requires that memory accesses are naturally aligned, except for the SH4-A movua.l instructions which can do unaligned loads. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Aurelien Jarno ---

Re: [Qemu-devel] [PATCH v3 09/15] target/sh4: optimize gen_store_fpr64

2017-05-12 Thread Richard Henderson
On 05/10/2017 11:26 AM, Aurelien Jarno wrote: Using extr and avoiding intermediate temps. Signed-off-by: Aurelien Jarno --- target/sh4/translate.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) Reviewed-by: Richard Henderson r~

Re: [Qemu-devel] [RFC PATCH 2/8] iommu/vt-d: add bind_pasid_table function

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:11:59 +0800 "Liu, Yi L" wrote: > From: Jacob Pan > > Add Intel VT-d ops to the generic iommu_bind_pasid_table API > functions. > > The primary use case is for direct assignment of SVM capable > device. Originated from

Re: [Qemu-devel] [RFC PATCH 4/8] iommu/vt-d: Add iommu do invalidate function

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:12:01 +0800 "Liu, Yi L" wrote: > From: Jacob Pan > > This patch adds Intel VT-d specific function to implement > iommu_do_invalidate API. > > The use case is for supporting caching structure invalidation > of assigned

Re: [Qemu-devel] [RFC PATCH 3/8] iommu: Introduce iommu do invalidate API function

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:12:00 +0800 "Liu, Yi L" wrote: > From: "Liu, Yi L" > > When a SVM capable device is assigned to a guest, the first level page > tables are owned by the guest and the guest PASID table pointer is > linked to the device context

Re: [Qemu-devel] [RFC PATCH 1/8] iommu: Introduce bind_pasid_table API function

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:11:58 +0800 "Liu, Yi L" wrote: > From: Jacob Pan > > Virtual IOMMU was proposed to support Shared Virtual Memory (SVM) use > case in the guest: > https://lists.gnu.org/archive/html/qemu-devel/2016-11/msg05311.html > >

Re: [Qemu-devel] [RFC PATCH 6/8] VFIO: do pasid table binding

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:12:03 +0800 "Liu, Yi L" wrote: > From: "Liu, Yi L" > > This patch adds IOCTL processing in vfio_iommu_type1 for > VFIO_IOMMU_SVM_BIND_TASK. Binds the PASID table bind by > calling iommu_ops->bind_pasid_table to link the whole

Re: [Qemu-devel] [RFC PATCH 5/8] VFIO: Add new IOTCL for PASID Table bind propagation

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:12:02 +0800 "Liu, Yi L" wrote: > From: "Liu, Yi L" > > This patch adds VFIO_IOMMU_SVM_BIND_TASK for potential PASID table > binding requests. > > On VT-d, this IOCTL cmd would be used to link the guest PASID page table > to

Re: [Qemu-devel] [RFC PATCH 7/8] VFIO: Add new IOCTL for IOMMU TLB invalidate propagation

2017-05-12 Thread Alex Williamson
On Wed, 26 Apr 2017 18:12:04 +0800 "Liu, Yi L" wrote: > From: "Liu, Yi L" > > This patch adds VFIO_IOMMU_TLB_INVALIDATE to propagate IOMMU TLB > invalidate request from guest to host. > > In the case of SVM virtualization on VT-d, host IOMMU

Re: [Qemu-devel] [PATCH 7/7] curl: do not do aio_poll when waiting for a free CURLState

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:05PM +0200, Paolo Bonzini wrote: > Instead, put the CURLAIOCB on a wait list; curl_clean_state will > wake the corresponding coroutine. > > Because of CURL's callback-based structure, we cannot easily convert > everything to CoMutex/CoQueue; keeping the QemuMutex is

Re: [Qemu-devel] [PATCH 6/7] curl: convert readv to coroutines

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:04PM +0200, Paolo Bonzini wrote: > This is pretty simple. The bottom half goes away because, unlike > bdrv_aio_readv, coroutine-based read can return immediately without > yielding. However, for simplicity I kept the former bottom half > handler in a separate

Re: [Qemu-devel] [PATCH 5/7] curl: convert CURLAIOCB to byte values

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:03PM +0200, Paolo Bonzini wrote: > This is in preparation for the conversion from bdrv_aio_readv to > bdrv_co_preadv, and it also requires changing some of the size_t values > to uint64_t. This was broken before for disks > 2TB, but now it would > break at 4GB. > >

Re: [Qemu-devel] [PATCH 4/7] curl: split curl_find_state/curl_init_state

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:02PM +0200, Paolo Bonzini wrote: > If curl_easy_init fails, a CURLState is left with s->in_use = 1. Split > curl_init_state in two, so that we can distinguish the two failures and > call curl_clean_state if needed. > > While at it, simplify curl_find_state, removing

Re: [Qemu-devel] [PATCH V2] migration: expose qemu_announce_self() via qmp

2017-05-12 Thread Vlad Yasevich
On 05/12/2017 03:24 PM, Dr. David Alan Gilbert wrote: > * Vlad Yasevich (vyase...@redhat.com) wrote: >> On 02/20/2017 07:16 PM, Germano Veit Michel wrote: >>> qemu_announce_self() is triggered by qemu at the end of migrations >>> to update the network regarding the path to the guest l2addr. >>>

Re: [Qemu-devel] [PATCH v3 1/4] ACPI: Add APEI GHES Table Generation support

2017-05-12 Thread Laszlo Ersek
On 04/30/17 07:35, Dongjiu Geng wrote: > This implements APEI GHES Table by passing the error cper info > to the guest via a fw_cfg_blob. After a CPER info is added, an > SEA/SEI exception will be injected into the guest OS. > > Below is the table layout, the max number of error soure is 11, >

Re: [Qemu-devel] [PULL for-2.9 1/3] coroutine: remove GThread implementation

2017-05-12 Thread Eric Blake
On 05/12/2017 09:37 AM, Stefan Hajnoczi wrote: > From: "Daniel P. Berrange" > > The GThread implementation is not functional enough to actually > run QEMU reliably. While it was potentially useful for debugging, > we have a scripts/qemugdb/coroutine.py to enable tracing of >

Re: [Qemu-devel] [PATCH V5 0/9] calculate blocktime for postcopy live migration

2017-05-12 Thread Eric Blake
On 05/12/2017 08:31 AM, Alexey Perevalov wrote: > The rationale for that idea is following: > vCPU could suspend during postcopy live migration until faulted > page is not copied into kernel. Downtime on source side it's a value - > time interval since source turn vCPU off, till destination start

Re: [Qemu-devel] [PATCH V4 9/9] migration: postcopy_blocktime documentation

2017-05-12 Thread Eric Blake
On 05/12/2017 06:31 AM, Alexey Perevalov wrote: > Signed-off-by: Alexey Perevalov > --- > docs/migration.txt | 10 ++ > 1 file changed, 10 insertions(+) > > diff --git a/docs/migration.txt b/docs/migration.txt > index 1b940a8..d0f5a6d 100644 > ---

Re: [Qemu-devel] [PATCH V4 8/9] migration: add postcopy total blocktime into query-migrate

2017-05-12 Thread Eric Blake
On 05/12/2017 06:31 AM, Alexey Perevalov wrote: > Postcopy total blocktime is available on destination side only. > But query-migrate was possible only for source. This patch > adds ability to call query-migrate on destination. To distinguish > src/dst, state of the MigrationState is using,

Re: [Qemu-devel] [Qemu-ppc] [PATCH v9 6/6] migration: spapr: migrate pending_events of spapr state

2017-05-12 Thread Daniel Henrique Barboza
On 05/12/2017 03:28 AM, David Gibson wrote: On Fri, May 05, 2017 at 05:47:46PM -0300, Daniel Henrique Barboza wrote: From: Jianjun Duan In racing situations between hotplug events and migration operation, a rtas hotplug event could have not yet be delivered to the

Re: [Qemu-devel] [PATCH 2/3] migration: Remove use of old MigrationParams

2017-05-12 Thread Eric Blake
On 05/12/2017 05:55 AM, Juan Quintela wrote: >>> @@ -1239,6 +1240,7 @@ void qmp_migrate(const char *uri, bool has_blk, bool >>> blk, >>> } >>> >>> if (has_inc && inc) { >>> +migrate_set_block_enabled(s, true); >>> migrate_set_block_shared(s, true); >> >> [2] >> >>

Re: [Qemu-devel] [Qemu-ppc] [PATCH v9 4/6] hw/ppc/spapr.c: migrate pending_dimm_unplugs of spapr state

2017-05-12 Thread Daniel Henrique Barboza
On 05/12/2017 03:12 AM, David Gibson wrote: On Fri, May 05, 2017 at 05:47:44PM -0300, Daniel Henrique Barboza wrote: To allow for a DIMM unplug event to resume its work if a migration occurs in the middle of it, this patch migrates the non-empty pending_dimm_unplugs QTAILQ that stores the

Re: [Qemu-devel] [PATCH 1/3] migration: Create block capabilities for shared and enable

2017-05-12 Thread Eric Blake
On 05/11/2017 11:32 AM, Juan Quintela wrote: > Those two capabilities were added through the command line. Notice that > we just created them. This is just the boilerplate. > > Signed-off-by: Juan Quintela > Reviewed-by: Eric Blake > > -- > > Make

Re: [Qemu-devel] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread John Snow
On 05/12/2017 03:46 PM, Eric Blake wrote: > On 05/12/2017 01:07 PM, Max Reitz wrote: >> On 2017-05-11 20:27, John Snow wrote: >>> Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 >>> >>> Or, rather, force the open of a backing image if one was specified >>> for creation. Using a

Re: [Qemu-devel] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread Eric Blake
On 05/12/2017 01:07 PM, Max Reitz wrote: > On 2017-05-11 20:27, John Snow wrote: >> Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 >> >> Or, rather, force the open of a backing image if one was specified >> for creation. Using a similar -unsafe option as rebase, allow qemu-img >> to

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Kevin O'Connor
On Fri, May 12, 2017 at 09:16:31PM +0200, Paolo Bonzini wrote: > On 12/05/2017 20:55, Xu, Anthony wrote: > > If that's the case, QEMU/TCG should work with SeaBios even with ignoring > > A20. > > > > During SeaBios boot, there are >350 port 92 access, if we don't need to > > handle A20, > > we

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: optimize rev16() using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 12:22 PM, Aurelien Jarno wrote: On 2017-05-12 12:05, Richard Henderson wrote: On 05/12/2017 11:21 AM, Aurelien Jarno wrote: +uint64_t mask1 = sf ? 0x00ff00ff00ff00ffull : 0x00ff00ff; +uint64_t mask2 = sf ? 0xff00ff00ff00ff00ull : 0xff00ff00; + +

[Qemu-devel] [PATCH] block: Correct documentation for BLOCK_WRITE_THRESHOLD

2017-05-12 Thread Eric Blake
Use the correct command name. Signed-off-by: Eric Blake --- qapi/block-core.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json index 614181b..206e33b 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json

Re: [Qemu-devel] [PATCH V2] migration: expose qemu_announce_self() via qmp

2017-05-12 Thread Dr. David Alan Gilbert
* Vlad Yasevich (vyase...@redhat.com) wrote: > On 02/20/2017 07:16 PM, Germano Veit Michel wrote: > > qemu_announce_self() is triggered by qemu at the end of migrations > > to update the network regarding the path to the guest l2addr. > > > > however it is also useful when there is a network

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: optimize rev16() using extract op

2017-05-12 Thread Aurelien Jarno
On 2017-05-12 12:05, Richard Henderson wrote: > On 05/12/2017 11:21 AM, Aurelien Jarno wrote: > > +uint64_t mask1 = sf ? 0x00ff00ff00ff00ffull : 0x00ff00ff; > > +uint64_t mask2 = sf ? 0xff00ff00ff00ff00ull : 0xff00ff00; > > + > > +tcg_gen_shri_i64(tcg_tmp, tcg_rn, 8); > > +

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Paolo Bonzini
On 12/05/2017 20:55, Xu, Anthony wrote: > >> On 12/05/2017 01:55, Xu, Anthony wrote: >>> Hi Paolo, >>> >>> In KVM mode, seems A20 is ignored. >>> Do you see any potential issue here? >> >> No; recent processors don't have A20 at all. > > I mean A20 in guest, not A20 in host. > Guest is

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: optimize rev16() using extract op

2017-05-12 Thread Richard Henderson
On 05/12/2017 11:21 AM, Aurelien Jarno wrote: +uint64_t mask1 = sf ? 0x00ff00ff00ff00ffull : 0x00ff00ff; +uint64_t mask2 = sf ? 0xff00ff00ff00ff00ull : 0xff00ff00; + +tcg_gen_shri_i64(tcg_tmp, tcg_rn, 8); +tcg_gen_andi_i64(tcg_tmp, tcg_tmp, mask1); +tcg_gen_shli_i64(tcg_rd,

Re: [Qemu-devel] [PATCH] target/i386: enable A20 automatically in system management mode

2017-05-12 Thread Xu, Anthony
> On 12/05/2017 01:55, Xu, Anthony wrote: > > Hi Paolo, > > > > In KVM mode, seems A20 is ignored. > > Do you see any potential issue here? > > No; recent processors don't have A20 at all. I mean A20 in guest, not A20 in host. Guest is running on old platform, it tries to control A20

Re: [Qemu-devel] [PATCH RESEND v2 00/21] qdev/sysbus: Set user_creatable=false by default on sysbus

2017-05-12 Thread Eduardo Habkost
Ping? If there are no objections to this series, I plan to merge it through the Machine Core tree. If anybody is interested, below are the results of squashing patches 2-20 together: --- hw/core/sysbus.c | 11 +++ hw/i386/amd_iommu.c | 2 ++ hw/i386/intel_iommu.c| 2

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: optimize rev16() using extract op

2017-05-12 Thread Aurelien Jarno
On 2017-05-12 09:50, Richard Henderson wrote: > On 05/11/2017 08:35 PM, Philippe Mathieu-Daudé wrote: > > -tcg_gen_shri_i64(tcg_tmp, tcg_rn, 16); > > -tcg_gen_andi_i64(tcg_tmp, tcg_tmp, 0x); > > +tcg_gen_extract_i64(tcg_tmp, tcg_rn, 16, 0x); > > So your new script didn't work

Re: [Qemu-devel] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread Max Reitz
On 2017-05-11 20:27, John Snow wrote: > Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 > > Or, rather, force the open of a backing image if one was specified > for creation. Using a similar -unsafe option as rebase, allow qemu-img > to ignore the backing file validation if possible. >

Re: [Qemu-devel] [PATCH 12/12] migration: migration.h was not needed

2017-05-12 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > This files don't use any function from migration.h, so drop it. > > Signed-off-by: Juan Quintela > --- > block/qed.c | 1 - > hw/i386/pc_q35.c| 1 - > hw/virtio/vhost-user.c | 1 - > hw/virtio/vhost-vsock.c

Re: [Qemu-devel] [PATCH 09/12] migration: Split vmstate-types.c from vmstate.c

2017-05-12 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Now one just has the interperter, and the other has the basic types. > Once there, add copyright boilerplate. > > Signed-off-by: Juan Quintela I think this is generally OK, but as discussed on IRC, I think you need to check the

Re: [Qemu-devel] [PATCH 05/12] migration: Move colo.h to migration/

2017-05-12 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > There are functions only used by migration code. That's only mostly true; see the current 'integrate colo frame with block replication and net compare' series (posted 22nd April). That adds colo_handle_shutdown to this header and calls it from vl.c (

Re: [Qemu-devel] [RFC PATCH v3 1/5] coccinelle: add a script to optimize tcg op using tcg_gen_extract()

2017-05-12 Thread Eric Blake
On 05/12/2017 12:36 AM, Philippe Mathieu-Daudé wrote: > In this patch > http://lists.nongnu.org/archive/html/qemu-devel/2017-05/msg01466.html > Aurelien does: > > -tcg_gen_shri_i32(cpu_sr_q, src, SR_Q); > -tcg_gen_andi_i32(cpu_sr_q, cpu_sr_q, 1); > +tcg_gen_extract_i32(cpu_sr_q, src,

Re: [Qemu-devel] [PATCH 3/3] net/filter-rewriter: Remove unused option in filter-rewirter

2017-05-12 Thread Eric Blake
On 05/11/2017 08:35 PM, Zhang Chen wrote: > Signed-off-by: Zhang Chen In the subject: s/rewirter/rewriter/ > --- > qemu-options.hx | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/qemu-options.hx b/qemu-options.hx > index

Re: [Qemu-devel] [PATCH v8 0/4] Improve convert and dd commands

2017-05-12 Thread Max Reitz
On 2017-05-09 11:48, Daniel P. Berrange wrote: > Update to > > v1: https://lists.gnu.org/archive/html/qemu-devel/2017-01/msg05699.html > v2: https://lists.gnu.org/archive/html/qemu-devel/2017-02/msg00728.html > v3: https://lists.gnu.org/archive/html/qemu-devel/2017-02/msg04391.html > v4:

Re: [Qemu-devel] [Qemu-block] [PULL 05/58] qemu-img: Update documentation for -U

2017-05-12 Thread Max Reitz
On 2017-05-11 16:32, Kevin Wolf wrote: > From: Fam Zheng > > Signed-off-by: Fam Zheng > Signed-off-by: Kevin Wolf > --- > qemu-img-cmds.hx | 36 ++-- > 1 file changed, 18 insertions(+), 18 deletions(-) > >

Re: [Qemu-devel] [PATCH v3 2/3] arm64: kvm: inject SError with virtual syndrome

2017-05-12 Thread James Morse
Hi gengdongjiu, On 05/05/17 14:19, gengdongjiu wrote: > On 2017/5/2 23:37, James Morse wrote: > > ... I think you expect an SError to arrive at EL2 and have its ESR recorded > > in > > vcpu->arch.fault.vsesr_el2. Some time later KVM decides to inject an SError > > into > > the guest, and this

Re: [Qemu-devel] KVM "fake DAX" device flushing

2017-05-12 Thread Kevin Wolf
Am 12.05.2017 um 15:42 hat Stefan Hajnoczi geschrieben: > On Thu, May 11, 2017 at 05:38:40PM -0400, Rik van Riel wrote: > > On Thu, 2017-05-11 at 14:17 -0400, Stefan Hajnoczi wrote: > > > On Wed, May 10, 2017 at 09:26:00PM +0530, Pankaj Gupta wrote: > > > > * For live migration use case, if host

Re: [Qemu-devel] [Qemu-block] [PATCH] qcow2: remove extra local_error variable

2017-05-12 Thread Max Reitz
On 2017-05-11 17:03, Alberto Garcia wrote: > Commit d7086422b1c1e75e320519cfe26176db6ec97a37 added a local_err > variable global to the qcow2_amend_options() function, so there's no > need to have this other one. > > Signed-off-by: Alberto Garcia > --- > block/qcow2.c | 5

  1   2   3   >