[Qemu-devel] [Bug 1744654] Re: commit: 4fe6d78 "virtio: postpone the execution of event_notifier_cleanup function" will cause vhost-user device crash

2018-01-24 Thread Thomas Huth
Thanks for the bug report. Patch has now been reverted: https://git.qemu.org/?p=qemu.git;a=commitdiff;h=1ef8185a0613dd2ed2 ** Changed in: qemu Status: New => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https:/

[Qemu-devel] [PATCH] virtio-balloon: unref the memory region before continuing

2018-01-24 Thread Tiwei Bie
Signed-off-by: Tiwei Bie --- hw/virtio/virtio-balloon.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio/virtio-balloon.c b/hw/virtio/virtio-balloon.c index 14e08d20d0..f2104bfcef 100644 --- a/hw/virtio/virtio-balloon.c +++ b/hw/virtio/virtio-balloon.c @@ -234,6 +234,7 @@ static void

[Qemu-devel] [PULL 13/14] docs: Add section for NVMe VFIO driver

2018-01-24 Thread Fam Zheng
Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-9-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-9-f...@redhat.com> Signed-off-by: Fam Zheng --- docs/qemu-block-drivers.texi | 37 + 1 file changed, 37 insertions(+)

[Qemu-devel] [PULL 09/14] block: Introduce buf register API

2018-01-24 Thread Fam Zheng
Allow block driver to map and unmap a buffer for later I/O, as a performance hint. Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-5-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-5-f...@redhat.com> Signed-off-by: Fam Zheng --- block/block-backend.c

[Qemu-devel] [PULL 12/14] block: Move NVMe constants to a separate header

2018-01-24 Thread Fam Zheng
Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-8-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-8-f...@redhat.com> Signed-off-by: Fam Zheng --- block/nvme.c | 7 +- hw/block/nvme.h | 698 +---

[Qemu-devel] [PULL 14/14] qapi: Add NVMe driver options to the schema

2018-01-24 Thread Fam Zheng
Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-10-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-10-f...@redhat.com> Signed-off-by: Fam Zheng --- qapi/block-core.json | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git

[Qemu-devel] [PULL 05/14] curl: convert to CoQueue

2018-01-24 Thread Fam Zheng
From: Paolo Bonzini Now that CoQueues can use a QemuMutex for thread-safety, there is no need for curl to roll its own coroutine queue. Coroutines can be placed directly on the queue instead of using a list of CURLAIOCBs. Signed-off-by: Paolo Bonzini Message-Id: <20180116142316.30486-5-pbonz..

[Qemu-devel] [PULL 03/14] coroutine-lock: convert CoQueue to use QemuLockable

2018-01-24 Thread Fam Zheng
From: Paolo Bonzini There are cases in which a queued coroutine must be restarted from non-coroutine context (with qemu_co_enter_next). In this cases, qemu_co_enter_next also needs to be thread-safe, but it cannot use a CoMutex and so cannot qemu_co_queue_wait. Use QemuLockable so that the CoQu

[Qemu-devel] [PULL 08/14] block: Add VFIO based NVMe driver

2018-01-24 Thread Fam Zheng
This is a new protocol driver that exclusively opens a host NVMe controller through VFIO. It achieves better latency than linux-aio by completely bypassing host kernel vfs/block layer. $rw-$bs-$iodepth linux-aio nvme:// randread-4k-1 10

[Qemu-devel] [PULL 11/14] qemu-img: Map bench buffer

2018-01-24 Thread Fam Zheng
Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-7-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-7-f...@redhat.com> Signed-off-by: Fam Zheng --- qemu-img.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/qemu-img.c b/qemu-i

[Qemu-devel] [PULL 04/14] coroutine-lock: make qemu_co_enter_next thread-safe

2018-01-24 Thread Fam Zheng
From: Paolo Bonzini qemu_co_queue_next does not need to release and re-acquire the mutex, because the queued coroutine does not run immediately. However, this does not hold for qemu_co_enter_next. Now that qemu_co_queue_wait can synchronize (via QemuLockable) with code that is not running in co

[Qemu-devel] [PULL 02/14] lockable: add QemuLockable

2018-01-24 Thread Fam Zheng
From: Paolo Bonzini QemuLockable is a polymorphic lock type that takes an object and knows which function to use for locking and unlocking. The implementation could use C11 _Generic, but since the support is not very widespread I am instead using __builtin_choose_expr and __builtin_types_compati

[Qemu-devel] [PULL 10/14] block/nvme: Implement .bdrv_(un)register_buf

2018-01-24 Thread Fam Zheng
Forward these two calls to the IOVA manager. Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-6-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-6-f...@redhat.com> Signed-off-by: Fam Zheng --- block/nvme.c | 24 1 file changed,

[Qemu-devel] [PULL 07/14] util: Introduce vfio helpers

2018-01-24 Thread Fam Zheng
This is a library to manage the host vfio interface, which could be used to implement userspace device driver code in QEMU such as NVMe or net controllers. Signed-off-by: Fam Zheng Message-Id: <20180110091846.10699-3-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413

[Qemu-devel] [PULL 06/14] stubs: Add stubs for ram block API

2018-01-24 Thread Fam Zheng
These functions will be wanted by block-obj-y but the actual definition is in obj-y, so stub them to keep the linker happy. Signed-off-by: Fam Zheng Acked-by: Paolo Bonzini Message-Id: <20180110091846.10699-2-f...@redhat.com> Reviewed-by: Stefan Hajnoczi Message-Id: <20180116060901.17413-2-f...

[Qemu-devel] [PULL 01/14] docker: change Fedora base image to fedora:27

2018-01-24 Thread Fam Zheng
From: Paolo Bonzini Using "fedora:latest" makes behavior different depending on when you actually pulled the image from the docker repository. In my case, the supposedly "latest" image was a Fedora 25 download from 8 months ago, and the new "test-debug" test was failing. Use "27" to improve rep

[Qemu-devel] [PULL 00/14] Block and docker patches

2018-01-24 Thread Fam Zheng
The following changes since commit 834a336eb911db8a8ca00e760ee6a85faca19414: Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging (2018-01-24 19:24:26 +) are available in the Git repository at: git://github.com/famz/qemu.git tags/staging-pull-request for you to fet

Re: [Qemu-devel] [PATCH] block/mirror: fix fail to cancel when VM has heavy BLK IO

2018-01-24 Thread Liang Li
On Wed, Jan 24, 2018 at 01:16:39PM -0600, Eric Blake wrote: > On 01/24/2018 12:17 AM, Liang Li wrote: > > We found that when doing drive mirror to a low speed shared storage, > > if there was heavy BLK IO write workload in VM after the 'ready' event, > > drive mirror block job can't be canceled imm

[Qemu-devel] [PATCH qemu v4] RFC: vfio-pci: Allow mmap of MSIX BAR

2018-01-24 Thread Alexey Kardashevskiy
This makes use of a new VFIO_REGION_INFO_CAP_MSIX_MAPPABLE capability which tells that a region with MSIX data can be mapped entirely, i.e. the VFIO PCI driver won't prevent MSIX vectors area from being mapped. With this change, all BARs are mapped in a single chunk and MSIX vectors are emulated o

[Qemu-devel] [PATCH qemu] vfio/common: Remove redundand copy of local variable

2018-01-24 Thread Alexey Kardashevskiy
There is already @hostwin in vfio_listener_region_add() so there is no point in having the other one. Fixes: 2e4109de "vfio/spapr: Create DMA window dynamically (SPAPR IOMMU v2)" Signed-off-by: Alexey Kardashevskiy --- hw/vfio/common.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/vfio/c

[Qemu-devel] [PATCH v1 6/6] vhost-user: add VFIO based accelerators support

2018-01-24 Thread Tiwei Bie
This patch does some small extensions to vhost-user protocol to support VFIO based accelerators, and makes it possible to get the similar performance of VFIO based PCI passthru while keeping the virtio device emulation in QEMU. Any virtio ring compatible devices potentially can be used as the vhos

[Qemu-devel] [PATCH v1 4/6] vfio: support getting VFIOGroup from groupfd

2018-01-24 Thread Tiwei Bie
Add an API to support getting VFIOGroup from groupfd. When groupfd is shared by another process, the VFIOGroup may not have its container and address space in QEMU. Besides, add a reference counter to better support getting VFIOGroup multiple times. Signed-off-by: Tiwei Bie --- hw/vfio/common.c

[Qemu-devel] [PATCH v1 0/6] Extend vhost-user to support VFIO based accelerators

2018-01-24 Thread Tiwei Bie
This patch set does some small extensions to vhost-user protocol to support VFIO based accelerators, and makes it possible to get the similar performance of VFIO based PCI passthru while keeping the virtio device emulation in QEMU. How does accelerator accelerate vhost (data path)

[Qemu-devel] [PATCH v1 5/6] vfio: remove DPRINTF() definition from vfio-common.h

2018-01-24 Thread Tiwei Bie
This macro isn't used by any VFIO code. And its name is too generic. The vfio-common.h (in include/hw/vfio) can be included by other modules in QEMU. It can introduce conflicts. Signed-off-by: Tiwei Bie --- include/hw/vfio/vfio-common.h | 9 - 1 file changed, 9 deletions(-) diff --git a

[Qemu-devel] [PATCH v1 3/6] virtio: support adding sub-regions for notify region

2018-01-24 Thread Tiwei Bie
Provide APIs to support querying whether the page-per-vq is enabled and adding sub-regions for notify region. Signed-off-by: Tiwei Bie --- Makefile.target| 4 hw/virtio/virtio-pci.c | 48 ++ hw/virtio/virtio-pci.h | 5 +

[Qemu-devel] [PATCH v1 2/6] vhost-user: introduce shared vhost-user state

2018-01-24 Thread Tiwei Bie
When multi-queue is enabled for virtio-net, each virtio queue pair will have a vhost_dev, and the only thing they share currently is the chardev. This patch introduces a vhost-user state structure which will be shared by all virtio queue pairs of the same virtio device. Signed-off-by: Tiwei Bie -

[Qemu-devel] [PATCH v1 1/6] vhost-user: support receiving file descriptors in slave_read

2018-01-24 Thread Tiwei Bie
Signed-off-by: Tiwei Bie --- hw/virtio/vhost-user.c | 40 +++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c index 093675ed98..e7108138fd 100644 --- a/hw/virtio/vhost-user.c +++ b/hw/virtio/vhost-u

Re: [Qemu-devel] GRUB countdown problem in VirtualBox

2018-01-24 Thread microsoft gaofei
https://www.virtualbox.org/ticket/17473 . I sent a bug ticket to Oracle , nobody believe what I said .

Re: [Qemu-devel] [PATCH v7 00/23] QMP: out-of-band (OOB) execution support

2018-01-24 Thread Peter Xu
On Wed, Jan 24, 2018 at 01:39:34PM +0800, Peter Xu wrote: > This version should have addressed all comments in previous one, also > fixed another race condition after I addressed all the comments (a new > race condition introduced by addressing the comments...). For some > more details of the race

Re: [Qemu-devel] [PATCH v3 3/3] hostmem-file: add 'sync' option

2018-01-24 Thread Haozhong Zhang
On 01/24/18 22:23 +0200, Michael S. Tsirkin wrote: > On Wed, Jan 17, 2018 at 04:13:25PM +0800, Haozhong Zhang wrote: > > This option controls whether QEMU mmap(2) the memory backend file with > > MAP_SYNC flag, which can fully guarantee the guest write persistence > > to the backend, if MAP_SYNC fl

[Qemu-devel] [PATCH v3 29/45] target/hppa: Add system registers to gdbstub

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/gdbstub.c | 156 ++ 1 file changed, 156 insertions(+) diff --git a/target/hppa/gdbstub.c b/target/hppa/gdbstub.c index fc27aec073..e2e9c4d77f 100644 --- a/target/hppa/gdbstub.c +++ b/target/hppa/gdbs

Re: [Qemu-devel] [PATCH v3 00/22] re-factor softfloat and add fp16 functions

2018-01-24 Thread Howard Spoelstra
On Thu, Jan 25, 2018 at 1:09 AM, Richard Henderson wrote: > On 01/24/2018 01:49 PM, Howard Spoelstra wrote: >> Hi, >> >> I built qemu-system-ppc for OSX and Windows from >> https://github.com/stsquad/qemu/tree/softfloat-refactor-and-fp16-v3 >> and noticed a considerable drop in floating point perf

Re: [Qemu-devel] [PATCH v3 1/3] util/mmap-alloc: support MAP_SYNC in qemu_ram_mmap()

2018-01-24 Thread Haozhong Zhang
On 01/24/18 22:20 +0200, Michael S. Tsirkin wrote: > > index 50385e3f81..dd5876471f 100644 > > --- a/include/qemu/mmap-alloc.h > > +++ b/include/qemu/mmap-alloc.h > > @@ -7,7 +7,8 @@ size_t qemu_fd_getpagesize(int fd); > > > > size_t qemu_mempath_getpagesize(const char *mem_path); > > > > -voi

Re: [Qemu-devel] [PATCH v3 00/45] hppa-softmmu

2018-01-24 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180124232625.30105-1-richard.hender...@linaro.org Subject: [Qemu-devel] [PATCH v3 00/45] hppa-softmmu === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log -

Re: [Qemu-devel] [PATCH v3 00/22] re-factor softfloat and add fp16 functions

2018-01-24 Thread Richard Henderson
On 01/24/2018 01:49 PM, Howard Spoelstra wrote: > Hi, > > I built qemu-system-ppc for OSX and Windows from > https://github.com/stsquad/qemu/tree/softfloat-refactor-and-fp16-v3 > and noticed a considerable drop in floating point performance on both > hosts. > Running Mac OS 9.2 in OSX, using MacBe

[Qemu-devel] [PATCH v3 44/45] target/hppa: Fix 32-bit operand masks for 0E FCVT

2018-01-24 Thread Richard Henderson
We masked the wrong bits, which prevented some of the 32-bit R registers. E.g. "fcnvxf,sgl,sgl fr22R,fr6R". Signed-off-by: Richard Henderson --- target/hppa/translate.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/target/hppa/translate.c b/target/hppa/trans

Re: [Qemu-devel] [PATCH v1 06/21] RISC-V FPU Support

2018-01-24 Thread Richard Henderson
On 01/24/2018 10:58 AM, Jim Wilson wrote: > I think that qemu is correct here, and that you want to use float32_chs. Ok. > Although, looking at this again, I see another statement in a > different place that says: > > Except when otherwise stated, if the result of a floating-point operation is >

[Qemu-devel] [PATCH v3 38/45] target/hppa: Implement a pause instruction

2018-01-24 Thread Richard Henderson
This is an extension to the base ISA, but we can use this in the kernel idle loop to reduce the host cpu time consumed. Signed-off-by: Richard Henderson --- target/hppa/translate.c | 36 1 file changed, 36 insertions(+) diff --git a/target/hppa/translate.c b

[Qemu-devel] [PATCH v3 36/45] target/hppa: Fix comment

2018-01-24 Thread Richard Henderson
From: Helge Deller Signed-off-by: Helge Deller Message-Id: <20171212212319.ga31...@ls3530.fritz.box> Signed-off-by: Richard Henderson --- target/hppa/translate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index a93e86c9

[Qemu-devel] [PATCH v3 43/45] hw/hppa: Add MAINTAINERS entry

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 753e7996ce..bee6b2bec7 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -133,6 +133,7 @@ HPPA (PA-RISC) M: Richard Henderson S: Maintained F: target/hppa/ +F: hw/h

[Qemu-devel] [PATCH v3 37/45] target/hppa: Implement LDSID for system mode

2018-01-24 Thread Richard Henderson
From: Helge Deller Signed-off-by: Helge Deller Message-Id: <20180102203145.ga17...@ls3530.fritz.box> Signed-off-by: Richard Henderson --- target/hppa/translate.c | 14 +- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c

[Qemu-devel] [PATCH v3 33/45] qom: Add MMU_DEBUG_LOAD

2018-01-24 Thread Richard Henderson
This lets us tell bottom levels of virtual memory translation routines that the access is from within QEMU itself and bypass certain tests. Cc: Andreas Färber Signed-off-by: Richard Henderson --- include/qom/cpu.h | 3 ++- target/sh4/op_helper.c | 2 ++ 2 files changed, 4 insertions(+), 1

[Qemu-devel] [PATCH v3 39/45] target/hppa: Implement STWA

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index d84090d479..b9b097acc9 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@

[Qemu-devel] [PATCH v3 28/45] target/hppa: Optimize for flat addressing space

2018-01-24 Thread Richard Henderson
Linux sets sr4-sr7 all to the same value, which means that we need not do any runtime computation to find out what space to use in forming the GVA. Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 11 ++- target/hppa/translate.c | 29 - 2 files c

[Qemu-devel] [PATCH v3 34/45] target/hppa: Use MMU_DEBUG_LOAD when reloading for CR[IIR]

2018-01-24 Thread Richard Henderson
Bypass any tlb protection checks, as this is not a "real" access to memory per the architecture. Signed-off-by: Richard Henderson --- target/hppa/int_helper.c | 2 +- target/hppa/mem_helper.c | 19 ++- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/target/hppa/i

[Qemu-devel] [PATCH v3 21/45] target/hppa: Implement I*TLBA and I*TLBP insns

2018-01-24 Thread Richard Henderson
The TLB can now be populated, but it cannot yet be cleared. Signed-off-by: Richard Henderson --- target/hppa/helper.h | 2 ++ target/hppa/mem_helper.c | 80 ++-- target/hppa/translate.c | 54 ++-- 3 files changed, 132

[Qemu-devel] [PATCH v3 30/45] target/hppa: Add migration for the cpu

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 1 + target/hppa/cpu.c | 1 + target/hppa/machine.c | 181 ++ target/hppa/Makefile.objs | 1 + 4 files changed, 184 insertions(+) create mode 100644 target/hppa/machine.

[Qemu-devel] [PATCH v3 20/45] target/hppa: Log unimplemented instructions

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 1cd57f5a90..6288bb9f67 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@ -4218,6 +4218,8 @@ static DisasJu

[Qemu-devel] [PATCH v3 26/45] target/hppa: Implement SYNCDMA insn

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 41e28ff64c..f3942b1baf 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@ -2312,7 +2312,8 @

[Qemu-devel] [PATCH v3 19/45] target/hppa: Implement the interval timer

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 2 ++ target/hppa/helper.h | 3 +++ target/hppa/cpu.c| 8 target/hppa/int_helper.c | 6 ++ target/hppa/op_helper.c | 36 target/hppa/translate.c | 16 ---

[Qemu-devel] [PATCH v3 23/45] target/hppa: Implement LDWA

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 38 ++ 1 file changed, 38 insertions(+) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 5b77688fc0..3d441ef4ac 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.

[Qemu-devel] [PATCH v3 14/45] target/hppa: Use space registers in data operations

2018-01-24 Thread Richard Henderson
This changes the system virtual address width to 64-bit and incorporates the space registers into load/store operations. Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 14 ++ target/hppa/translate.c | 334 +++- 2 files changed, 201 ins

[Qemu-devel] [PATCH v3 41/45] hw/hppa: Implement DINO system board

2018-01-24 Thread Richard Henderson
From: Helge Deller Now that we have the prerequisites in target/hppa/, implement the hardware for a PA7100LC. This also enables build for hppa-softmmu. Signed-off-by: Helge Deller [rth: Since it is all new code, squashed all branch development withing hw/hppa/ to a single patch.] Signed-off-by

[Qemu-devel] [PATCH v3 17/45] target/hppa: Implement tlb_fill

2018-01-24 Thread Richard Henderson
However since HPPA has a software-managed TLB, and the relevant TLB manipulation instructions are not implemented, this does not actually do anything. Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 29 - target/hppa/int_helper.c | 15 - target/hppa/mem_helper.c | 1

[Qemu-devel] [PATCH v3 45/45] target/hppa: Implement PROBE for system mode

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/helper.h| 3 +-- target/hppa/op_helper.c | 36 +--- target/hppa/translate.c | 20 3 files changed, 42 insertions(+), 17 deletions(-) diff --git a/target/hppa/helper.h b/target/hppa/helper.h

[Qemu-devel] [PATCH v3 09/45] target/hppa: Add control registers

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- linux-user/hppa/target_cpu.h | 2 +- target/hppa/cpu.h| 23 +++ linux-user/main.c| 4 +-- linux-user/signal.c | 4 +-- target/hppa/gdbstub.c| 12 target/hppa/mem_helper.c | 2 +- target/hppa

[Qemu-devel] [PATCH v3 32/45] target/hppa: Only use EXCP_DTLB_MISS

2018-01-24 Thread Richard Henderson
Unknown why this works, but if we return EXCP_ITLB_MISS we will triple-fault the first userland instruction fetch. Is it something to do with having a combined I/DTLB? Signed-off-by: Richard Henderson --- target/hppa/mem_helper.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --g

[Qemu-devel] [PATCH v3 15/45] target/hppa: Avoid privilege level decrease during branches

2018-01-24 Thread Richard Henderson
These instructions force the destination privilege level of the branch destination to be no higher than current. Signed-off-by: Richard Henderson --- target/hppa/translate.c | 52 - 1 file changed, 47 insertions(+), 5 deletions(-) diff --git a/tar

[Qemu-devel] [PATCH v3 40/45] target/hppa: Enable MTTCG

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 6 ++ configure | 1 + 2 files changed, 7 insertions(+) diff --git a/target/hppa/cpu.h b/target/hppa/cpu.h index 79763b254c..3df3ebd19d 100644 --- a/target/hppa/cpu.h +++ b/target/hppa/cpu.h @@ -42,6 +42,12 @@ #define TARGET_P

[Qemu-devel] [PATCH v3 08/45] target/hppa: Add space registers

2018-01-24 Thread Richard Henderson
Not used where they should be yet, but we can copy them. Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 1 + target/hppa/helper.c| 14 ++ target/hppa/translate.c | 73 + 3 files changed, 77 insertions(+), 11 deletions(-

[Qemu-devel] [PATCH v3 31/45] target/hppa: Implement B,GATE insn

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 1 + target/hppa/mem_helper.c | 8 target/hppa/translate.c | 48 3 files changed, 57 insertions(+) diff --git a/target/hppa/cpu.h b/target/hppa/cpu.h index 8a87b8a9b3..797

[Qemu-devel] [PATCH v3 05/45] target/hppa: Split address size from register size

2018-01-24 Thread Richard Henderson
For system mode, we will need 64-bit virtual addresses even when we have 32-bit register sizes. Since the rest of QEMU equates TARGET_LONG_BITS with the address size, redefine everything related to register size in terms of a new TARGET_REGISTER_BITS. Signed-off-by: Richard Henderson --- target

[Qemu-devel] [PATCH v3 35/45] target/hppa: Increase number of temp regs

2018-01-24 Thread Richard Henderson
HP-UX 10.20 CD contains "add r0, r0, r27" in a delay slot, which uses at least 5 temps. Signed-off-by: Richard Henderson --- target/hppa/translate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 5b7824f065..a93e86c9e3

[Qemu-devel] [PATCH v3 07/45] target/hppa: Implement the system mask instructions

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/helper.h| 4 +++ target/hppa/op_helper.c | 14 target/hppa/translate.c | 96 - 3 files changed, 113 insertions(+), 1 deletion(-) diff --git a/target/hppa/helper.h b/target/hppa/helper.h

[Qemu-devel] [PATCH v3 25/45] target/hppa: Implement LCI

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 20 1 file changed, 20 insertions(+) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 082221f450..41e28ff64c 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@ -2462,6 +2462

[Qemu-devel] [PATCH v3 27/45] target/hppa: Implement halt and reset instructions

2018-01-24 Thread Richard Henderson
From: Helge Deller Real hardware would use an external device to control the power. But for the moment let's invent instructions in reserved space, to be used by our custom firmware. Signed-off-by: Helge Deller Signed-off-by: Richard Henderson --- target/hppa/helper.h| 2 ++ target/hppa/

[Qemu-devel] [PATCH v3 12/45] target/hppa: Fill in hppa_cpu_do_interrupt/hppa_cpu_exec_interrupt

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.c | 2 + target/hppa/helper.c | 63 - target/hppa/int_helper.c | 176 ++ target/hppa/translate.c | 16 - target/hppa/Makefile.objs | 1 + 5 files changed, 192

[Qemu-devel] [PATCH v3 06/45] target/hppa: Implement mmu_idx from IA privilege level

2018-01-24 Thread Richard Henderson
Most aspects of privilege are not yet handled. But this gives us the start from which to begin checking. Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 19 + target/hppa/cpu.c | 2 +- target/hppa/translate.c | 55 ++-

[Qemu-devel] [PATCH v3 24/45] target/hppa: Implement LPA

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 1 + target/hppa/helper.h | 1 + target/hppa/mem_helper.c | 21 + target/hppa/op_helper.c | 10 +- target/hppa/translate.c | 30 ++ 5 files changed, 58 insertions(+), 5

[Qemu-devel] [PATCH v3 22/45] target/hppa: Implement P*TLB and P*TLBE insns

2018-01-24 Thread Richard Henderson
We now have all of the TLB manipulation instructions. Signed-off-by: Richard Henderson --- target/hppa/helper.h | 2 ++ target/hppa/mem_helper.c | 37 + target/hppa/translate.c | 40 3 files changed, 79 insertions

[Qemu-devel] [PATCH v3 03/45] target/hppa: Disable gateway page emulation for system mode

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/translate.c | 27 +-- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 31d9a2a31b..8e357cc60c 100644 --- a/target/hppa/translate.c +++ b/target/hppa/tran

[Qemu-devel] [PATCH v3 10/45] target/hppa: Adjust insn mask for mfctl, w

2018-01-24 Thread Richard Henderson
While the E bit is only used for pa2.0 mfctl,w from sar, the otherwise reserved bit does not appear to be decoded. Signed-off-by: Richard Henderson --- target/hppa/translate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/hppa/translate.c b/target/hppa/translate.c in

[Qemu-devel] [PATCH v3 18/45] target/hppa: Implement external interrupts

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 1 + target/hppa/helper.h | 2 ++ target/hppa/cpu.c| 6 + target/hppa/int_helper.c | 59 target/hppa/translate.c | 16 - 5 files changed, 83 insertions(

[Qemu-devel] [PATCH v3 16/45] target/hppa: Implement IASQ

2018-01-24 Thread Richard Henderson
Any one TB will have only one space value. If we change spaces, we change TBs. Thus BE and BEV must exit the TB immediately. Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 53 - target/hppa/cpu.c| 15 ++ target/hppa/helper.c | 3 +- targ

[Qemu-devel] [PATCH v3 04/45] target/hppa: Define hardware exception types

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 39 +++ linux-user/main.c| 26 ++--- target/hppa/helper.c | 61 ++-- target/hppa/mem_helper.c | 4 +++- target/hppa/op_helper.c |

[Qemu-devel] [PATCH v3 02/45] target/hppa: Define the rest of the PSW

2018-01-24 Thread Richard Henderson
We don't actually do anything with most of the bits yet, but at least they have names and we have somewhere to store them. Signed-off-by: Richard Henderson --- target/hppa/cpu.h| 47 ++ target/hppa/helper.c | 53

[Qemu-devel] [PATCH v3 13/45] target/hppa: Implement unaligned access trap

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.c | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/target/hppa/cpu.c b/target/hppa/cpu.c index ca619578dd..4d0b760baa 100644 --- a/target/hppa/cpu.c +++ b/target/hppa/cpu.c @@ -48,6 +48,23 @@ static void h

[Qemu-devel] [PATCH v3 11/45] target/hppa: Implement rfi

2018-01-24 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/hppa/cpu.h | 1 + target/hppa/helper.h| 2 ++ target/hppa/op_helper.c | 24 target/hppa/translate.c | 30 -- 4 files changed, 55 insertions(+), 2 deletions(-) diff --git a/target/hppa/cpu

[Qemu-devel] [PATCH v3 01/45] target/hppa: Skeleton support for hppa-softmmu

2018-01-24 Thread Richard Henderson
From: Helge Deller With the addition of default-configs/hppa-softmmu.mak, this will compile. It is not enabled with this patch, however. Signed-off-by: Helge Deller Signed-off-by: Richard Henderson --- include/sysemu/arch_init.h | 1 + target/hppa/cpu.h | 1 + arch_init.c

[Qemu-devel] [PATCH v3 00/45] hppa-softmmu

2018-01-24 Thread Richard Henderson
A third revision. Changes since last: * sh4 build failure fixed (needed clang to see it) * checkpatch whitespace errors fixed. * Still updates to IIR, IOR, ISR when !PSW[Q] * Fix fcnv instruction masks. * Implement probe insn. The middle three points progress in booting hpux-11. Bootin

[Qemu-devel] [Bug 902413] Re: qemu-i386-user on ARM host: wine hangs/spins when trying to run anything

2018-01-24 Thread Thomas Huth
There hasn't been an update within a year, so let's assume this bug has been fixed. ** Changed in: qemu Status: Incomplete => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/902413

Re: [Qemu-devel] [PULL v2 0/3] virtio: quick fix

2018-01-24 Thread Peter Maydell
On 24 January 2018 at 17:22, Michael S. Tsirkin wrote: > So this just reverts Gal's patches. I hope he'll be able to resubmit > shortly but it's causing too many issues to too many people to try to do > incremental fixups, and this way there's no timing pressure on anyone. > > The following change

Re: [Qemu-devel] [PATCH v9 03/13] block/dirty-bitmap: add _locked version of bdrv_reclaim_dirty_bitmap

2018-01-24 Thread John Snow
On 01/24/2018 05:16 AM, Paolo Bonzini wrote: > On 22/01/2018 13:14, Vladimir Sementsov-Ogievskiy wrote: >>> so, accessing the bitmap needs mutex lock? >>> >>> Then what do you mean under accessing the bitmap? Any touch of >>> BdrvDirtyBitmap fields? Then "reading the list" will require bitmap >>>

Re: [Qemu-devel] [PATCH v3 04/22] target/*/cpu.h: remove softfloat.h

2018-01-24 Thread David Gibson
On Wed, Jan 24, 2018 at 01:12:57PM +, Alex Bennée wrote: > As cpu.h is another typically widely included file which doesn't need > full access to the softfloat API we can remove the includes from here > as well. Where they do need types it's typically for float_status and > the rounding modes s

[Qemu-devel] [PATCH v3] xilinx_spips: Correct usage of an uninitialized local variable

2018-01-24 Thread Francisco Iglesias
Coverity found that the variable tx_rx in the function xilinx_spips_flush_txfifo was being used uninitialized (CID 1383841). This patch corrects this by always initializing tx_rx to zeros. Signed-off-by: Francisco Iglesias --- v3. Change to report errors on the num_busses property via the Error*

Re: [Qemu-devel] [PATCH v3 00/22] re-factor softfloat and add fp16 functions

2018-01-24 Thread Howard Spoelstra
Hi, I built qemu-system-ppc for OSX and Windows from https://github.com/stsquad/qemu/tree/softfloat-refactor-and-fp16-v3 and noticed a considerable drop in floating point performance on both hosts. Running Mac OS 9.2 in OSX, using MacBench 3.0, the score for the floating point performance dropped

Re: [Qemu-devel] [PATCH V4 0/7] CAN bus support for QEMU (SJA1000 PCI so far)

2018-01-24 Thread Philippe Mathieu-Daudé
Hi Pavel, On 01/24/2018 05:22 PM, Pavel Pisa wrote: > Hello everybody, > > On Tuesday 23 of January 2018 22:42:31 Pavel Pisa wrote: >> When Linux specific object file is linked in then some local >> function needs to be called before QOM instances population. >> I know how to do that GCC specific

[Qemu-devel] [PATCH V1 1/1] tests: Add migration test for aarch64

2018-01-24 Thread Wei Huang
This patch adds the migration test support for aarch64. The test code, which implements the same functionality as x86, is compiled into a binary and booted as a kernel in qemu. Here are the design ideas: * We choose this -kernel design because aarch64 QEMU doesn't provide a built-in fw like x8

Re: [Qemu-devel] [PATCH 0/2] linux-user: Fix race between threads in page_unprotect()

2018-01-24 Thread Laurent Vivier
Le 19/01/2018 à 15:51, Riku Voipio a écrit : > Hi Laurent, > > On Mon, Jan 15, 2018 at 01:52:32PM +0100, Laurent Vivier wrote: >> Le 15/01/2018 à 13:48, Peter Maydell a écrit : >>> On 28 November 2017 at 14:35, Peter Maydell >>> wrote: If multiple guest threads in user-mode emulation write

[Qemu-devel] [PATCH v4 3/4] linux-user, m68k: select CPU according to ELF header values

2018-01-24 Thread Laurent Vivier
M680x0 doesn't support the same set of instructions as ColdFire, so we can't use "any" CPU type to execute m68020 instructions. We select CPU type ("m68040" or "any" for ColdFire) according to the ELF header. If we can't, we use by default the value used until now: "any". Signed-off-by: Laurent Vi

[Qemu-devel] [PATCH v4 2/4] linux-user: introduce functions to detect CPU type

2018-01-24 Thread Laurent Vivier
From: YunQiang Su Add a function to return ELF e_flags and use it to select the CPU model. Signed-off-by: YunQiang Su [lv: split the patch and some cleanup in get_elf_eflags()] Signed-off-by: Laurent Vivier Reviewed-by: Richard Henderson --- linux-user/elfload.c | 35

[Qemu-devel] [PATCH v4 4/4] linux-user: MIPS set cpu to r6 CPU if binary is R6

2018-01-24 Thread Laurent Vivier
From: YunQiang Su So here we need to detect the version of binaries and set cpu_model for it. Signed-off-by: YunQiang Su [lv: original patch modified to move code into cpu_get_model()] Signed-off-by: Laurent Vivier Reviewed-by: Richard Henderson --- include/elf.h | 4 l

[Qemu-devel] [PATCH v4 1/4] linux-user: Move CPU type name selection to a function

2018-01-24 Thread Laurent Vivier
Instead of a sequence of "#if ... #endif" move the selection to a function in linux-user/*/target_elf.h We can't add them in linux-user/*/target_cpu.h because we will need to include "elf.h" to use ELF flags with eflags, and including "elf.h" in "target_cpu.h" introduces some conflicts in elfload.

[Qemu-devel] [PATCH v4 0/4] linux-user: select CPU type according ELF header values

2018-01-24 Thread Laurent Vivier
This idea has been suggested to me before by Philippe Mathieu-Daudé, and recently YunQiang Su has proposed a patch to manage the MIPS r6 case. Based on this, this series tries to clean-up the original patch, and introduces the use for m68k architecture and port the patch from YunQiang Su. v4: Add

Re: [Qemu-devel] [PATCH v2] kvm-all: Partially reverts 4fe6d78b2e to remove the cleanup call

2018-01-24 Thread Michael S. Tsirkin
On Wed, Jan 24, 2018 at 10:40:14AM +0100, Paolo Bonzini wrote: > On 23/01/2018 18:54, Jose Ricardo Ziviani wrote: > > This commit partially reverts the commit 4fe6d78b2e because of issues > > reported in the virtio. > > > > Examples: > > > > $ qemu-system-ppc64 -cpu POWER8 -nographic -vga none -m

Re: [Qemu-devel] [PULL 0/1] virtio: quick fix

2018-01-24 Thread Michael S. Tsirkin
On Wed, Jan 24, 2018 at 08:17:08PM +, Peter Maydell wrote: > On 23 January 2018 at 22:44, Michael S. Tsirkin wrote: > > This is just a quick bugfix so people can make progress. > > Will send a pull req with more patches queues later this week. > > > > The following changes since commit 52483b0

Re: [Qemu-devel] [PATCH v3 3/3] hostmem-file: add 'sync' option

2018-01-24 Thread Michael S. Tsirkin
On Wed, Jan 17, 2018 at 04:13:25PM +0800, Haozhong Zhang wrote: > This option controls whether QEMU mmap(2) the memory backend file with > MAP_SYNC flag, which can fully guarantee the guest write persistence > to the backend, if MAP_SYNC flag is supported by the host kernel > (Linux kernel 4.15 and

Re: [Qemu-devel] [PATCH v3 2/3] hostmem: add more information in error messages

2018-01-24 Thread Michael S. Tsirkin
On Wed, Jan 17, 2018 at 04:13:24PM +0800, Haozhong Zhang wrote: > When there are multiple memory backends in use, including the object type > name, ID and the property name in the error message can help users to > locate the error. > > Signed-off-by: Haozhong Zhang > Suggested-by: "Dr. David Alan

Re: [Qemu-devel] [PATCH V4 0/7] CAN bus support for QEMU (SJA1000 PCI so far)

2018-01-24 Thread Pavel Pisa
Hello everybody, On Tuesday 23 of January 2018 22:42:31 Pavel Pisa wrote: > When Linux specific object file is linked in then some local > function needs to be called before QOM instances population. > I know how to do that GCC specific/non-portable way > > static void __attribute__((constructor))

Re: [Qemu-devel] [PATCH v3 3/3] hostmem-file: add 'sync' option

2018-01-24 Thread Michael S. Tsirkin
On Wed, Jan 17, 2018 at 04:13:25PM +0800, Haozhong Zhang wrote: > This option controls whether QEMU mmap(2) the memory backend file with > MAP_SYNC flag, which can fully guarantee the guest write persistence > to the backend, if MAP_SYNC flag is supported by the host kernel > (Linux kernel 4.15 and

  1   2   3   >