Re: [Qemu-devel] [PATCH 6/6] qapi: discriminate CpuInfo[Fast] on SysEmuTarget, not CpuInfoArch

2018-04-26 Thread Markus Armbruster
Laszlo Ersek writes: > On 04/26/18 17:51, Markus Armbruster wrote: >> Eric Blake writes: >> >>> On 04/26/2018 09:34 AM, Markus Armbruster wrote: > > Acerbic discovery of the day: @CpuInfoArch has "x86", while configure > produces: > > TARGET_NAME TARGET_BASE_ARCH >

Re: [Qemu-devel] [PATCH 08/10] intel-iommu: maintain per-device iova ranges

2018-04-26 Thread Peter Xu
On Fri, Apr 27, 2018 at 02:07:46PM +0800, Jason Wang wrote: > > > On 2018年04月25日 12:51, Peter Xu wrote: > > For each VTDAddressSpace, now we maintain what IOVA ranges we have > > mapped and what we have not. With that information, now we only send > > MAP or UNMAP when necessary. Say, we don't

Re: [Qemu-devel] [PATCH v3 03/35] ppc/xive: introduce the XiveFabric interface

2018-04-26 Thread David Gibson
On Thu, Apr 26, 2018 at 12:30:42PM +0200, Cédric Le Goater wrote: > On 04/26/2018 05:54 AM, David Gibson wrote: > > On Tue, Apr 24, 2018 at 11:33:11AM +0200, Cédric Le Goater wrote: > >> On 04/24/2018 08:46 AM, David Gibson wrote: > >>> On Mon, Apr 23, 2018 at 09:58:43AM +0200, Cédric Le Goater wro

Re: [Qemu-devel] [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none"

2018-04-26 Thread Markus Armbruster
Eduardo Habkost writes: > On Thu, Apr 26, 2018 at 05:20:25PM +0200, Thomas Huth wrote: >> On 26.04.2018 13:45, Markus Armbruster wrote: >> > Thomas Huth writes: >> [...] >> >> @@ -260,6 +263,26 @@ static void test_abstract_interfaces(void) >> >> qtest_end(); >> >> } >> >> >> >> +static v

Re: [Qemu-devel] qom-test

2018-04-26 Thread Markus Armbruster
Thomas Huth writes: > On 26.04.2018 13:54, Markus Armbruster wrote: > [...] >> Actually, a worse offender in the "waste everybody's time via redunancy" >> department could be qom-test. > > Shall we change qom-test to also only test with the "none" machine in > the normal "make check" mode and onl

Re: [Qemu-devel] [Qemu-block] [RFC PATCH v2 3/7] qcow2: Implement copy offloading

2018-04-26 Thread Fam Zheng
On Thu, 04/26 16:34, Stefan Hajnoczi wrote: > On Wed, Apr 18, 2018 at 11:04:20AM +0800, Fam Zheng wrote: > > +static int qcow2_co_copy_range_to(BlockDriverState *bs, > > + BdrvChild *src, uint64_t src_offset, > > + BdrvChild *dst, ui

Re: [Qemu-devel] [PATCH 07/10] util: implement simple interval tree logic

2018-04-26 Thread Peter Xu
On Fri, Apr 27, 2018 at 01:53:35PM +0800, Jason Wang wrote: [...] > > +/* Merge right adjacent range */ > > +overlap = it_tree_find_value(tree, end + 1); > > +if (overlap) { > > +range->end = overlap->end; > > +g_tree_remove(gtree, overlap); > > +} > > + > > +/

Re: [Qemu-devel] [PATCH 03/10] intel-iommu: add iommu lock

2018-04-26 Thread Peter Xu
On Fri, Apr 27, 2018 at 01:13:02PM +0800, Jason Wang wrote: > > > On 2018年04月25日 12:51, Peter Xu wrote: > > Add a per-iommu big lock to protect IOMMU status. Currently the only > > thing to be protected is the IOTLB cache, since that can be accessed > > even without BQL, e.g., in IO dataplane. >

Re: [Qemu-devel] [PATCH 3/3] iotests: Add creation test to 153

2018-04-26 Thread Fam Zheng
On Sat, 04/21 00:09, Max Reitz wrote: > This patch adds a test case to 153 which tries to overwrite an image > (using qemu-img create) while it is in use. Without the original user > explicitly sharing the necessary permissions (writing and truncation), > this should not be allowed. > > Signed-of

Re: [Qemu-devel] [PATCH 1/3] block/file-posix: Pass FD to locking helpers

2018-04-26 Thread Fam Zheng
On Sat, 04/21 00:09, Max Reitz wrote: > raw_apply_lock_bytes() and raw_check_lock_bytes() currently take a > BDRVRawState *, but they only use the lock_fd field. During image > creation, we do not have a BDRVRawState, but we do have an FD; so if we > want to reuse the functions there, we should mo

Re: [Qemu-devel] [PATCH 2/3] block/file-posix: File locking during creation

2018-04-26 Thread Fam Zheng
On Sat, 04/21 00:09, Max Reitz wrote: > When creating a file, we should take the WRITE and RESIZE permissions. > We do not need either for the creation itself, but we do need them for > clearing and resizing it. So we can take the proper permissions by > replacing O_TRUNC with an explicit truncati

Re: [Qemu-devel] [PATCH] allocate pci id for mdpy

2018-04-26 Thread Gerd Hoffmann
On Thu, Apr 26, 2018 at 06:40:40PM +0300, Michael S. Tsirkin wrote: > On Thu, Apr 26, 2018 at 05:31:48PM +0200, Gerd Hoffmann wrote: > > On Thu, Apr 26, 2018 at 06:10:48PM +0300, Michael S. Tsirkin wrote: > > > On Tue, Apr 24, 2018 at 08:38:57AM +0200, Gerd Hoffmann wrote: > > > > mdpy is a sample

Re: [Qemu-devel] [PATCH 08/10] intel-iommu: maintain per-device iova ranges

2018-04-26 Thread Jason Wang
On 2018年04月25日 12:51, Peter Xu wrote: For each VTDAddressSpace, now we maintain what IOVA ranges we have mapped and what we have not. With that information, now we only send MAP or UNMAP when necessary. Say, we don't send MAP notifies if we know we have already mapped the range, meanwhile we

[Qemu-devel] qom-test (was: [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none")

2018-04-26 Thread Thomas Huth
On 26.04.2018 13:54, Markus Armbruster wrote: [...] > Actually, a worse offender in the "waste everybody's time via redunancy" > department could be qom-test. Shall we change qom-test to also only test with the "none" machine in the normal "make check" mode and only do the full test with all machi

Re: [Qemu-devel] [PATCH 07/10] util: implement simple interval tree logic

2018-04-26 Thread Jason Wang
On 2018年04月25日 12:51, Peter Xu wrote: Introduce a simplest interval tree implementation based on GTree. Current implementation is mostly tailored to maintain and trace device mapped IOVA ranges, but still it might be useful to other modules in the future. It is naive in that it even does not a

Re: [Qemu-devel] [Qemu-block] [RFC PATCH v2 1/7] block: Introduce API for copy offloading

2018-04-26 Thread Fam Zheng
On Thu, 04/26 15:57, Stefan Hajnoczi wrote: > On Wed, Apr 18, 2018 at 11:04:18AM +0800, Fam Zheng wrote: > > diff --git a/block/io.c b/block/io.c > > index bd9a19a9c4..d274e9525f 100644 > > --- a/block/io.c > > +++ b/block/io.c > > @@ -2826,3 +2826,94 @@ void bdrv_unregister_buf(BlockDriverState *b

Re: [Qemu-devel] [PATCH v8 11/35] RISC-V: Mark ROM read-only after copying in code

2018-04-26 Thread Michael Clark
On Fri, Apr 27, 2018 at 5:22 PM, Michael Clark wrote: > > > On Fri, Apr 27, 2018 at 4:48 AM, Alistair Francis > wrote: > >> On Wed, Apr 25, 2018 at 5:03 PM Michael Clark wrote: >> >> > The sifive_u machine already marks its ROM readonly. This fixes >> > the remaining boards. This commit also ma

Re: [Qemu-devel] [PATCH v8 11/35] RISC-V: Mark ROM read-only after copying in code

2018-04-26 Thread Michael Clark
On Fri, Apr 27, 2018 at 4:48 AM, Alistair Francis wrote: > On Wed, Apr 25, 2018 at 5:03 PM Michael Clark wrote: > > > The sifive_u machine already marks its ROM readonly. This fixes > > the remaining boards. This commit also makes all boards use > > mask_rom as the variable name for the ROM. Thi

Re: [Qemu-devel] [PATCH 03/10] intel-iommu: add iommu lock

2018-04-26 Thread Jason Wang
On 2018年04月25日 12:51, Peter Xu wrote: Add a per-iommu big lock to protect IOMMU status. Currently the only thing to be protected is the IOTLB cache, since that can be accessed even without BQL, e.g., in IO dataplane. Note that device page tables should not need any protection. The safety of

Re: [Qemu-devel] [PATCH v8 00/35] QEMU 2.13 Privileged ISA emulation updates

2018-04-26 Thread Michael Clark
On Fri, Apr 27, 2018 at 12:35 PM, Richard Henderson < richard.hender...@linaro.org> wrote: > On 04/26/2018 08:22 AM, Alistair Francis wrote: > > On Wed, Apr 25, 2018 at 7:01 PM Michael Clark wrote: > >> We can make a PR for the first 9 patches as they are already reviewed, > >> however, the with

Re: [Qemu-devel] [RFC][BROKEN] rbd: Allow configuration of authentication scheme

2018-04-26 Thread Jeff Cody
On Wed, Apr 25, 2018 at 09:50:19AM +0200, Kevin Wolf wrote: > Am 24.04.2018 um 20:26 hat Jeff Cody geschrieben: > > On Fri, Apr 20, 2018 at 04:39:02PM +0200, Markus Armbruster wrote: > > > >> Ways to avoid the troublesome auth-cephx: {}: > > > >> > > > >> (A) Make auth-cephx a bool, rely on the ot

[Qemu-devel] [Bug 1767200] Re: Kernel Panic Unable to mount root fs on unknown-block(31, 3)

2018-04-26 Thread Thomas Huth
Did it work with a previous version of QEMU? If yes, which version? And since you're using -kernel ... don't you maybe have to use -initrd here, too? ** Changed in: qemu Status: New => Incomplete -- You received this bug notification because you are a member of qemu- devel-ml, which is su

Re: [Qemu-devel] Who is running QEMU automated tests, and when?

2018-04-26 Thread Thomas Huth
On 26.04.2018 16:24, Daniel P. Berrangé wrote: > On Thu, Apr 26, 2018 at 11:22:36AM -0300, Eduardo Habkost wrote: >> On Thu, Apr 26, 2018 at 03:14:00PM +0100, Daniel P. Berrangé wrote: >>> On Thu, Apr 26, 2018 at 04:09:55PM +0200, Thomas Huth wrote: On 26.04.2018 15:57, Eduardo Habkost wrote:

Re: [Qemu-devel] [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none"

2018-04-26 Thread Thomas Huth
On 27.04.2018 02:32, Eduardo Habkost wrote: > On Thu, Apr 26, 2018 at 05:20:25PM +0200, Thomas Huth wrote: >> On 26.04.2018 13:45, Markus Armbruster wrote: >>> Thomas Huth writes: >> [...] @@ -260,6 +263,26 @@ static void test_abstract_interfaces(void) qtest_end(); } >>

Re: [Qemu-devel] [PATCH v2 3/5] migration: remove unnecessary variables len in QIOChannelRDMA

2018-04-26 Thread 858585 jemmy
On Fri, Apr 27, 2018 at 12:40 AM, Dr. David Alan Gilbert wrote: > * Lidong Chen (jemmy858...@gmail.com) wrote: >> Because qio_channel_rdma_writev and qio_channel_rdma_readv maybe invoked >> by different threads concurrently, this patch removes unnecessary variables >> len in QIOChannelRDMA and use

Re: [Qemu-devel] [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none"

2018-04-26 Thread Thomas Huth
On 27.04.2018 02:34, Eduardo Habkost wrote: > On Thu, Apr 26, 2018 at 01:54:43PM +0200, Markus Armbruster wrote: >> Thomas Huth writes: >> >>> On 17.04.2018 14:12, Markus Armbruster wrote: Thomas Huth writes: > Many device introspection crashes only happen if you are using a > c

[Qemu-devel] [PULL 1/4] intel-iommu: send PSI always when notify_unmap set

2018-04-26 Thread Michael S. Tsirkin
From: Peter Xu During IOVA page table walk, there is a special case when: - notify_unmap is set, meanwhile - entry is invalid In the past, we skip the entry always. This is not correct. We should send UNMAP notification to registered notifiers in this case. Otherwise some stall pages will st

Re: [Qemu-devel] Cannot launch QEMU with -accel whpx

2018-04-26 Thread Wang Wenchao
Hi, Justin, That hits the issue. QEMU can be launched with WHPX enabling. Great thanks for your reply. Best Regards, Wenchao On 4/27/2018 2:06, Justin Terry (VM) wrote: Hey Wenchao, It looks like your specs should fully support running this. Did you by chance forget to enable the Windows

[Qemu-devel] [PULL 0/4] pc, pci, virtio: fixes, features

2018-04-26 Thread Michael S. Tsirkin
The following changes since commit 4743c23509a51bd4ee85cc272287a41917d1be35: Update version for v2.12.0 release (2018-04-24 16:44:55 +0100) are available in the git repository at: git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_upstream for you to fetch changes up to fb6fd86f712

[Qemu-devel] [PULL 4/4] virtio-balloon: add hugetlb page allocation counts

2018-04-26 Thread Michael S. Tsirkin
From: Jonathan Helman qemu should read and report hugetlb page allocation counts exported in the following kernel patch: commit 4c3ca37c4a4394978fd0f005625f6064ed2b9a64 Author: Jonathan Helman Date: Mon Mar 19 11:00:35 2018 -0700 virtio_balloon: export hugetlb page allocation

[Qemu-devel] [PULL 2/4] hw/pci-host/q35: Replace hardcoded value with macro

2018-04-26 Thread Michael S. Tsirkin
From: Zihan Yang During smram region initialization some addresses are hardcoded, replace them with macro to be more clear to readers. Previous patch forgets about one value and exceeds the line limit of 90 characters. The v2 breaks a few long lines Signed-off-by: Zihan Yang Reviewed-by: Micha

[Qemu-devel] [PULL 3/4] allocate pci id for mdpy

2018-04-26 Thread Michael S. Tsirkin
From: Gerd Hoffmann mdpy is a sample pci device for vfio-mdev. Not (yet) merged upstream, patch available here: https://www.kraxel.org/cgit/linux/commit/?h=vfio-sample-display&id=6fd86cff3d7df38ab89625b16fdd6434b1c18749 Cc: Alex Williamson Signed-off-by: Gerd Hoffmann Reviewed-by: Michael S.

Re: [Qemu-devel] [PATCH] migration: introduce decompress-error-check

2018-04-26 Thread Xiao Guangrong
On 04/26/2018 10:01 PM, Eric Blake wrote: On 04/26/2018 04:15 AM, guangrong.x...@gmail.com wrote: From: Xiao Guangrong QEMU 2.13 enables strict check for compression & decompression to make the migration more robuster, that depends on the source to fix s/robuster/robust/ Will fix, thank

Re: [Qemu-devel] Who is running QEMU automated tests, and when?

2018-04-26 Thread Fam Zheng
On Thu, 04/26 10:57, Eduardo Habkost wrote: > So, for anybody that runs automated QEMU tests once in a while, > can we know: > > * What test cases are you running? Where can we get more > information about the tests you run? These currently run on patchew: * checkpatch * ./configure && make

Re: [Qemu-devel] [PATCH v3 02/35] ppc/xive: add support for the LSI interrupt sources

2018-04-26 Thread David Gibson
On Thu, Apr 26, 2018 at 02:16:06PM +0200, Cédric Le Goater wrote: > On 04/26/2018 05:28 AM, David Gibson wrote: > > On Tue, Apr 24, 2018 at 10:11:27AM +0200, Cédric Le Goater wrote: > >> On 04/24/2018 08:41 AM, David Gibson wrote: > >>> On Mon, Apr 23, 2018 at 09:31:24AM +0200, Cédric Le Goater wro

Re: [Qemu-devel] Migration without memory page transfer

2018-04-26 Thread Peter Xu
On Thu, Apr 26, 2018 at 11:33:53PM +, Eric Wheeler wrote: > Hello all, Hi, Eric, > > This is my first time inside of the qemu code, so your help is greatly > appreciated! > > I have been experimenting with stop/start of VMs to/from a migration > stream that excludes RAM pages and let the

Re: [Qemu-devel] [RFC for-2.13 0/7] spapr: Clean up pagesize handling

2018-04-26 Thread David Gibson
On Thu, Apr 26, 2018 at 10:45:40AM +0200, Andrea Bolognani wrote: > On Thu, 2018-04-26 at 10:55 +1000, David Gibson wrote: > > On Wed, Apr 25, 2018 at 06:09:26PM +0200, Andrea Bolognani wrote: > > > The new parameter would make it possible to make sure you will > > > actually be able to use the pag

Re: [Qemu-devel] [PATCH 0/9] target/arm: Implement v8.1-Atomics

2018-04-26 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180427002651.28356-1-richard.hender...@linaro.org Subject: [Qemu-devel] [PATCH 0/9] target/arm: Implement v8.1-Atomics === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1

[Qemu-devel] [PATCH 4/9] tcg: Introduce atomic helpers for integer min/max

2018-04-26 Thread Richard Henderson
Given that this atomic operation will be used by both risc-v and aarch64, let's not duplicate code across the two targets. Signed-off-by: Richard Henderson --- accel/tcg/atomic_template.h | 71 + accel/tcg/tcg-runtime.h | 8 + tcg/tcg-op.h

[Qemu-devel] [PATCH 3/9] target/xtensa: Use new min/max expanders

2018-04-26 Thread Richard Henderson
The generic expanders replace nearly identical code in the translator. Cc: Max Filippov Signed-off-by: Richard Henderson --- target/xtensa/translate.c | 50 +++ 1 file changed, 33 insertions(+), 17 deletions(-) diff --git a/target/xtensa/translate.c

[Qemu-devel] [PATCH 2/9] target/arm: Use new min/max expanders

2018-04-26 Thread Richard Henderson
The generic expanders replace nearly identical code in the translator. Signed-off-by: Richard Henderson --- target/arm/translate-a64.c | 46 ++ 1 file changed, 14 insertions(+), 32 deletions(-) diff --git a/target/arm/translate-a64.c b/target/arm/tran

Re: [Qemu-devel] [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none"

2018-04-26 Thread Eduardo Habkost
On Thu, Apr 26, 2018 at 01:54:43PM +0200, Markus Armbruster wrote: > Thomas Huth writes: > > > On 17.04.2018 14:12, Markus Armbruster wrote: > >> Thomas Huth writes: > >> > >>> Many device introspection crashes only happen if you are using a > >>> certain machine, e.g.: > >>> > >>> $ ppc-softmm

Re: [Qemu-devel] [PATCH v8 00/35] QEMU 2.13 Privileged ISA emulation updates

2018-04-26 Thread Richard Henderson
On 04/26/2018 08:22 AM, Alistair Francis wrote: > On Wed, Apr 25, 2018 at 7:01 PM Michael Clark wrote: >> We can make a PR for the first 9 patches as they are already reviewed, >> however, the with this series is to gather review for the new baseline we >> have in the riscv repo. > > I think it i

[Qemu-devel] [PATCH 9/9] target/arm: Enable ARM_FEATURE_V8_ATOMICS for user-only

2018-04-26 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/arm/cpu64.c | 1 + 1 file changed, 1 insertion(+) diff --git a/target/arm/cpu64.c b/target/arm/cpu64.c index 991d764674..c50dcd4077 100644 --- a/target/arm/cpu64.c +++ b/target/arm/cpu64.c @@ -248,6 +248,7 @@ static void aarch64_max_initfn(Object *obj)

Re: [Qemu-devel] [PATCH v8 00/35] QEMU 2.13 Privileged ISA emulation updates

2018-04-26 Thread Michael Clark
On Fri, Apr 27, 2018 at 6:22 AM, Alistair Francis wrote: > On Wed, Apr 25, 2018 at 7:01 PM Michael Clark wrote: > > > One last quick note. > > > We are tracking RISC-V QEMU issues in the riscv.org repo: > > > - https://github.com/riscv/riscv-qemu/issues > > > We have tagged issues that are resol

[Qemu-devel] [PATCH 7/9] target/arm: Fill in disas_ldst_atomic

2018-04-26 Thread Richard Henderson
This implements all of the v8.1-Atomics instructions except for compare-and-swap, which is decoded elsewhere. Signed-off-by: Richard Henderson --- target/arm/translate-a64.c | 38 -- 1 file changed, 36 insertions(+), 2 deletions(-) diff --git a/target/arm/tra

Re: [Qemu-devel] [RFC PATCH] tests/device-introspect: Test devices with all machines, not only with "none"

2018-04-26 Thread Eduardo Habkost
On Thu, Apr 26, 2018 at 05:20:25PM +0200, Thomas Huth wrote: > On 26.04.2018 13:45, Markus Armbruster wrote: > > Thomas Huth writes: > [...] > >> @@ -260,6 +263,26 @@ static void test_abstract_interfaces(void) > >> qtest_end(); > >> } > >> > >> +static void add_machine_test_case(const char

[Qemu-devel] [PATCH 5/9] target/riscv: Use new atomic min/max expanders

2018-04-26 Thread Richard Henderson
Cc: Michael Clark Cc: Palmer Dabbelt Cc: Sagar Karandikar Cc: Bastian Koppelmann Signed-off-by: Richard Henderson --- target/riscv/translate.c | 72 ++-- 1 file changed, 20 insertions(+), 52 deletions(-) diff --git a/target/riscv/translate.c b/targ

[Qemu-devel] [PATCH 8/9] target/arm: Implement CAS and CASP

2018-04-26 Thread Richard Henderson
Signed-off-by: Richard Henderson --- target/arm/helper-a64.h| 2 + target/arm/helper-a64.c| 43 target/arm/translate-a64.c | 119 +++-- 3 files changed, 161 insertions(+), 3 deletions(-) diff --git a/target/arm/helper-a64.h b/ta

[Qemu-devel] [PATCH 1/9] tcg: Introduce helpers for integer min/max

2018-04-26 Thread Richard Henderson
These operations are re-invented by several targets so far. Several supported hosts have insns for these, so place the expanders out-of-line for a future introduction of tcg opcodes. Signed-off-by: Richard Henderson --- tcg/tcg-op.h | 16 tcg/tcg-op.c | 40 ++

[Qemu-devel] [PATCH 0/9] target/arm: Implement v8.1-Atomics

2018-04-26 Thread Richard Henderson
This implements the Atomics extension, which is mandatory for v8.1. While testing the v8.2-SVE extension, I've run into issues with the GCC testsuite expecting this to exist. Missing is the wiring up of the system registers to indicate that the extension exists, but we have no system CPU model tha

[Qemu-devel] [PATCH 6/9] target/arm: Introduce ARM_FEATURE_V8_ATOMICS and initial decode

2018-04-26 Thread Richard Henderson
The insns in the ARMv8.1-Atomics are added to the existing load/store exclusive and load/store reg opcode spaces. Rearrange the top-level decoders for these to accomodate. The Atomics insns themselves still generate Unallocated. Signed-off-by: Richard Henderson --- target/arm/cpu.h |

Re: [Qemu-devel] [RFC PATCH] hw/s390x: Allow to configure the consoles with the "-serial" parameter

2018-04-26 Thread Eduardo Habkost
On Tue, Apr 24, 2018 at 06:19:35PM +0200, Paolo Bonzini wrote: > On 24/04/2018 16:22, Thomas Huth wrote: > > $ diff -u sclp-qom-tree-before.txt sclp-qom-tree-after.txt > > --- sclp-qom-tree-before.txt2018-04-24 16:17:48.462849585 +0200 > > +++ sclp-qom-tree-after.txt 2018-04-24 16:18:02.222

Re: [Qemu-devel] [PATCH v8 22/35] RISC-V: Use atomic_cmpxchg to update PLIC bitmaps

2018-04-26 Thread Richard Henderson
On 04/25/2018 01:45 PM, Michael Clark wrote: > +uint32_t old, new; > +do { > +old = atomic_read(&plic->pending[word]); > +new = (old & ~(1 << (irq & 31))) | (-!!pending & (1 << (irq & 31))); > +} while (atomic_cmpxchg(&plic->pending[word], old, new) != old); I prefer

[Qemu-devel] Migration without memory page transfer

2018-04-26 Thread Eric Wheeler
Hello all, This is my first time inside of the qemu code, so your help is greatly appreciated! I have been experimenting with stop/start of VMs to/from a migration stream that excludes RAM pages and let the RAM pages come from memory file provided by the memory-backend-file called '/dev/shm/me

Re: [Qemu-devel] [PULL 15/19] hw/arm/highbank: don't make sysram 'nomigrate'

2018-04-26 Thread Michael Clark
On Thu, Apr 26, 2018 at 10:47 PM, Peter Maydell wrote: > Currently we use memory_region_init_ram_nomigrate() to create > the "highbank.sysram" memory region, and we don't manually > register it with vmstate_register_ram(). This currently > means that its contents are migrated but as a ram block >

Re: [Qemu-devel] Who is running QEMU automated tests, and when?

2018-04-26 Thread Michael Clark
On Fri, Apr 27, 2018 at 2:04 AM, Peter Maydell wrote: > On 26 April 2018 at 14:57, Eduardo Habkost wrote: > > Peter, do you have additional tests you run before merging a pull > > request? Additional test sets run before tagging a release? > > I run make && make check, on a variety of hosts, be

[Qemu-devel] [Bug 1767200] [NEW] Kernel Panic Unable to mount root fs on unknown-block(31, 3)

2018-04-26 Thread nada
Public bug reported: Using the latest qemu: qemu-system-arm.exe -kernel C:\Users\a\Downloads\kernel-qemu-4.4.34-jessie -cpu arm1176 -m 256 -machine versatilepb -cdrom C:\Users\a\Downloads\picore-9.0.3.img Gives error: Kernel Panic Unable to mount root fs on unknown-block(31,3) I have tried diff

Re: [Qemu-devel] [RFC PATCH] softfloat: re-factor float to float conversions

2018-04-26 Thread Richard Henderson
On 04/26/2018 05:40 AM, Alex Bennée wrote: > +bool arm_hp = !ieee && (src_sz == 16); Surely you should be testing the destination format. The float16_unpack_canonical step should be handling the (non-)special cases to get into FloatParts. It would probably be better to invert the parameter to

Re: [Qemu-devel] [PATCH v3 43/46] tests/tcg/Makefile: update to be called from Makefile.target

2018-04-26 Thread Richard Henderson
On 04/25/2018 11:30 PM, Alex Bennée wrote: > > Richard Henderson writes: > >> On 04/24/2018 05:24 AM, Alex Bennée wrote: >>> +run-%: % >>> + $(call quiet-command, $(QEMU) $< > $<.out, "TEST", "$< on >>> $(TARGET_NAME)") >> >> I've just had an x86_64 guest test run for 70 minutes. We need to

Re: [Qemu-devel] [PATCH v7 0/9] i386: Enable TOPOEXT to support hyperthreading on AMD CPU

2018-04-26 Thread geoff--- via Qemu-devel
Works well for me, thanks! Tested-by: Geoffrey McRae On 2018-04-27 02:26, Babu Moger wrote: This series enables the TOPOEXT feature for AMD CPUs. This is required to support hyperthreading on kvm guests. This addresses the issues reported in these bugs: https://bugzilla.redhat.com/show_bug.c

Re: [Qemu-devel] [PATCH v8 21/35] RISC-V: Add mcycle/minstret support for -icount auto

2018-04-26 Thread Alistair Francis
On Wed, Apr 25, 2018 at 4:59 PM Michael Clark wrote: > Previously the mycycle/minstret CSRs and rdcycle/rdinstret > psuedo instructions would return the time as a proxy for an > increasing instruction counter in the absence of having a > precise instruction count. If QEMU is invoked with -icount,

Re: [Qemu-devel] [PATCH v8 19/35] RISC-V: Allow S-mode mxr access when priv ISA >= v1.10

2018-04-26 Thread Alistair Francis
On Wed, Apr 25, 2018 at 5:10 PM Michael Clark wrote: > The mstatus.MXR alias in sstatus should only be writable > by S-mode if the privileged ISA version >= v1.10. Also MXR > was masked in sstatus CSR read but not sstatus CSR writes. > Now we correctly mask sstatus.mxr in both read and write. >

Re: [Qemu-devel] Large patch set advice

2018-04-26 Thread Kamil Rytarowski
On 26.04.2018 21:53, Warner Losh wrote: > On Thu, Apr 26, 2018 at 5:22 AM, Kamil Rytarowski wrote: > >> On 26.04.2018 10:11, Peter Maydell wrote: >>> On 25 April 2018 at 20:57, Warner Losh wrote: I’ve foolishly volunteered to rebase all the changes that the bad-user mode folks have don

Re: [Qemu-devel] Large patch set advice

2018-04-26 Thread Warner Losh
On Thu, Apr 26, 2018 at 5:22 AM, Kamil Rytarowski wrote: > On 26.04.2018 10:11, Peter Maydell wrote: > > On 25 April 2018 at 20:57, Warner Losh wrote: > >> I’ve foolishly volunteered to rebase all the changes that the bad-user > >> mode folks have done to a recent master rev to get these changes

Re: [Qemu-devel] Large patch set advice

2018-04-26 Thread Warner Losh
On Thu, Apr 26, 2018 at 2:11 AM, Peter Maydell wrote: > On 25 April 2018 at 20:57, Warner Losh wrote: > > I’ve foolishly volunteered to rebase all the changes that the bad-user > > mode folks have done to a recent master rev to get these changes > upstreamed. > > A number of people have been wor

Re: [Qemu-devel] [PATCH v2 4/4] qapi: discriminate CpuInfoFast on SysEmuTarget, not CpuInfoArch

2018-04-26 Thread Eric Blake
On 04/26/2018 02:41 PM, Eric Blake wrote: > I also like that this approach is introspectible via 'query-qmp-schema' > - if 'query-cpus-fast' has the "target" member, then you know that it is > fixed (you can ignore "arch" in that case, even though you know it > works); if it lacks "target", you kn

Re: [Qemu-devel] [PATCH v2 4/4] qapi: discriminate CpuInfoFast on SysEmuTarget, not CpuInfoArch

2018-04-26 Thread Eric Blake
On 04/26/2018 01:34 PM, Laszlo Ersek wrote: > Add a new field @target (of type @SysEmuTarget) to the output of the > @query-cpus-fast command, which provides more information about the > emulation target than the field @arch (of type @CpuInfoArch). Make @target > the new discriminator for the @CpuI

Re: [Qemu-devel] [RFC v2] qemu: Add virtio pmem device

2018-04-26 Thread no-reply
Hi, This series failed docker-build@min-glib build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 20180425112415.12327-4-pagu...@redhat.com Subject: [Qemu-devel] [RFC v2] qemu: Add virti

Re: [Qemu-devel] [PATCH v2 3/4] qapi: change the type of TargetInfo.arch from string to enum SysEmuTarget

2018-04-26 Thread Eric Blake
On 04/26/2018 01:34 PM, Laszlo Ersek wrote: > Now that we have @SysEmuTarget, it makes sense to restrict > @TargetInfo.@arch to valid sysemu targets at the schema level. > > Cc: "Daniel P. Berrange" > Cc: Eric Blake > Cc: Markus Armbruster > Signed-off-by: Laszlo Ersek > Reviewed-by: Markus Ar

Re: [Qemu-devel] [PATCH v2 2/4] qapi: add SysEmuTarget to "common.json"

2018-04-26 Thread Eric Blake
On 04/26/2018 01:34 PM, Laszlo Ersek wrote: > We'll soon need an enumeration type that lists all the softmmu targets > that QEMU (the project) supports. Introduce @SysEmuTarget to > "common.json". > > The enum constant @x86_64 is not spelled @x86-64 because the corresponding > emulator is called q

Re: [Qemu-devel] [PATCH V5] migration: add capability to bypass the shared memory

2018-04-26 Thread Dr. David Alan Gilbert
* Lai Jiangshan (jiangshan...@gmail.com) wrote: > On Fri, Apr 20, 2018 at 12:38 AM, Dr. David Alan Gilbert > wrote: > > >> -static void ram_list_init_bitmaps(void) > >> +static void ram_list_init_bitmaps(RAMState *rs) > >> { > >> RAMBlock *block; > >> unsigned long pages; > >> @@ -2151

Re: [Qemu-devel] [PATCH] qobject: Use qobject_to() instead of type cast

2018-04-26 Thread Marc-André Lureau
On Thu, Apr 26, 2018 at 5:28 PM, Markus Armbruster wrote: > The proper way to convert from (abstract) QObject to a (concrete) > subtype is qobject_to(). Look for offenders that type cast instead: > > $ git-grep '(Q[A-Z][a-z]* \*)' > hmp.c:qmp_device_add((QDict *)qdict, NULL, &err); >

Re: [Qemu-devel] [PATCH] vhost: add trace for IOTLB miss

2018-04-26 Thread Michael S. Tsirkin
On Wed, Mar 21, 2018 at 11:21:24AM +0800, Peter Xu wrote: > Add some trace points for IOTLB translation for vhost. After vhost-user > is setup, the only IO path that QEMU will participate should be the > IOMMU translation, so it'll be good we can track this with explicit > timestamps when needed to

Re: [Qemu-devel] [RFC PATCH] hw/core: expand description of null-machine

2018-04-26 Thread Max Filippov
On Thu, Apr 26, 2018 at 11:18 AM, Thomas Huth wrote: > On 26.04.2018 18:09, Alex Bennée wrote: >> Thomas Huth writes: >>> Actually, with certain CPUs, you can really use the "none" machine as a >>> pure instruction set testing system. For example, on m68k, there used to >>> be an explicit "dummy"

Re: [Qemu-devel] [RFC PATCH] hw/core: expand description of null-machine

2018-04-26 Thread Thomas Huth
On 26.04.2018 20:44, Alex Bennée wrote: > > Thomas Huth writes: > >> On 26.04.2018 18:09, Alex Bennée wrote: >>> >>> Thomas Huth writes: >>> On 25.04.2018 17:33, Alex Bennée wrote: > People following old instructions for QEMU get the message "No machine > specified, and there is no

Re: [Qemu-devel] [RFC PATCH] hw/core: expand description of null-machine

2018-04-26 Thread Alex Bennée
Thomas Huth writes: > On 26.04.2018 18:09, Alex Bennée wrote: >> >> Thomas Huth writes: >> >>> On 25.04.2018 17:33, Alex Bennée wrote: People following old instructions for QEMU get the message "No machine specified, and there is no default" and run -machine help to pick a new ma

[Qemu-devel] [Bug 1767176] [NEW] GTK build fails with qemu 2.12.0

2018-04-26 Thread Dominyk Tiller
n 'qemu_input_map_usb_to_qcode'? return qemu_input_map_osx_to_qcode;    ^~~    qemu_input_map_usb_to_qcode /private/tmp/qemu-20180426-60786-1av6pq8/qemu-2.12.0/include/ui/input.h:99:22: note: 'qemu_input_map_usb

Re: [Qemu-devel] [PATCH] allocate pci id for mdpy

2018-04-26 Thread Michael S. Tsirkin
On Thu, Apr 26, 2018 at 11:00:28AM -0600, Alex Williamson wrote: > On Thu, 26 Apr 2018 18:40:40 +0300 > "Michael S. Tsirkin" wrote: > > > On Thu, Apr 26, 2018 at 05:31:48PM +0200, Gerd Hoffmann wrote: > > > On Thu, Apr 26, 2018 at 06:10:48PM +0300, Michael S. Tsirkin wrote: > > > > On Tue, Apr

[Qemu-devel] [PATCH v2 3/4] qapi: change the type of TargetInfo.arch from string to enum SysEmuTarget

2018-04-26 Thread Laszlo Ersek
Now that we have @SysEmuTarget, it makes sense to restrict @TargetInfo.@arch to valid sysemu targets at the schema level. Cc: "Daniel P. Berrange" Cc: Eric Blake Cc: Markus Armbruster Signed-off-by: Laszlo Ersek Reviewed-by: Markus Armbruster --- Notes: PATCHv2: - drop naive cod

[Qemu-devel] [PATCH v2 1/4] qapi: fill in CpuInfoFast.arch in query-cpus-fast

2018-04-26 Thread Laszlo Ersek
* Commit ca230ff33f89 added the @arch field to @CpuInfoFast, but it failed to set the new field in qmp_query_cpus_fast(), when TARGET_S390X was not defined. The updated @query-cpus-fast example in "qapi-schema.json" showed "arch":"x86" only because qmp_query_cpus_fast() calls g_malloc0() to

[Qemu-devel] [PATCH v2 0/4] qapi: introduce the SysEmuTarget enumeration

2018-04-26 Thread Laszlo Ersek
This is version 2 of the set posted earlier at 20180424214550.32549-1-lersek@redhat.com">http://mid.mail-archive.com/20180424214550.32549-1-lersek@redhat.com This version seeks to address the v1 feedback. Changes are noted per patch. The following firmware schema / interop docs patch remains d

[Qemu-devel] [PATCH v2 4/4] qapi: discriminate CpuInfoFast on SysEmuTarget, not CpuInfoArch

2018-04-26 Thread Laszlo Ersek
Add a new field @target (of type @SysEmuTarget) to the output of the @query-cpus-fast command, which provides more information about the emulation target than the field @arch (of type @CpuInfoArch). Make @target the new discriminator for the @CpuInfoFast return structure. Keep @arch for compatibili

[Qemu-devel] [PATCH v2 2/4] qapi: add SysEmuTarget to "common.json"

2018-04-26 Thread Laszlo Ersek
We'll soon need an enumeration type that lists all the softmmu targets that QEMU (the project) supports. Introduce @SysEmuTarget to "common.json". The enum constant @x86_64 is not spelled @x86-64 because the corresponding emulator is called qemu-system-x86_64. Like other enum types, @SysEmuTarget

Re: [Qemu-devel] [PATCH 00/17] iotests: don't choke on disabled drivers

2018-04-26 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180426161958.2872-1-rka...@virtuozzo.com Subject: [Qemu-devel] [PATCH 00/17] iotests: don't choke on disabled drivers === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 t

Re: [Qemu-devel] [RFC PATCH] hw/core: expand description of null-machine

2018-04-26 Thread Peter Maydell
On 26 April 2018 at 19:18, Thomas Huth wrote: > I don't think it makes sense to instantiate e.g. an interrupt controller > with the "none" machine automatically ... so the raw cortex-m3 core > should either be usable without that, too The interrupt controller in an M-profile core is an integral p

Re: [Qemu-devel] [RFC PATCH 1/7] error reporting: Introduce errnoval parameter to vreport

2018-04-26 Thread Ian Jackson
Eric Blake writes ("Re: [RFC PATCH 1/7] error reporting: Introduce errnoval parameter to vreport"): > On 04/26/2018 12:32 PM, Ian Jackson wrote: > > But, 0 might be fed to strerror. This is not normally deliberate, but > > it does occor. It is not unusual for people to write code which can > > f

Re: [Qemu-devel] [PATCH v8 00/35] QEMU 2.13 Privileged ISA emulation updates

2018-04-26 Thread Alistair Francis
On Wed, Apr 25, 2018 at 7:01 PM Michael Clark wrote: > One last quick note. > We are tracking RISC-V QEMU issues in the riscv.org repo: > - https://github.com/riscv/riscv-qemu/issues > We have tagged issues that are resolved in the 'qemu-2.13-for-upstream' > branch (this branch can be rebased

Re: [Qemu-devel] [RFC PATCH] hw/core: expand description of null-machine

2018-04-26 Thread Thomas Huth
On 26.04.2018 18:09, Alex Bennée wrote: > > Thomas Huth writes: > >> On 25.04.2018 17:33, Alex Bennée wrote: >>> People following old instructions for QEMU get the message "No machine >>> specified, and there is no default" and run -machine help to pick a >>> new machine. Lay people might consid

[Qemu-devel] [RESEND PULL v9 00/16] xen: xen-domid-restrict improvements

2018-04-26 Thread Ian Jackson
The following changes since commit b8846a4d6352b2a1d2012f8b3b9115640524aeda: vl.c: new function serial_max_hds() (2018-04-26 13:58:29 +0100) are available in the git repository at: https://xenbits.xen.org/git-http/people/iwj/qemu.git tags/for-upstream.depriv-2 for you to fetch changes up t

Re: [Qemu-devel] [PATCH 01/17] block: iterate_format with account of whitelisting

2018-04-26 Thread Eric Blake
On 04/26/2018 11:19 AM, Roman Kagan wrote: > bdrv_iterate_format (which is currently only used for printing out the > formats supported by the block layer) doesn't take format whitelisting > into account. > > As a result, QEMU lies when asked for the list of block drivers it > supports with "-driv

Re: [Qemu-devel] [PULL v9 00/16] xen: xen-domid-restrict improvements

2018-04-26 Thread Ian Jackson
Peter Maydell writes ("Re: [PULL v9 00/16] xen: xen-domid-restrict improvements"): > On 26 April 2018 at 18:36, Ian Jackson wrote: > > I can do that. Alternatively you could manually verify the signature > > on my email and observe that it mentions the correct commit hash. > > I could, but I ho

Re: [Qemu-devel] [RFC PATCH 1/7] error reporting: Introduce errnoval parameter to vreport

2018-04-26 Thread Eric Blake
On 04/26/2018 12:24 PM, Eric Blake wrote: >> @@ -222,6 +224,11 @@ static void vreport(report_type type, const char *fmt, >> va_list ap) >> } >> >> error_vprintf(fmt, ap); >> + >> +if (errnoval >= 0) { >> +error_printf(": %s", strerror(errnoval)); > > Off-by-one. You do N

Re: [Qemu-devel] [RFC PATCH 3/7] error reporting: Use error_report_errno in obvious places

2018-04-26 Thread Eric Blake
On 04/26/2018 12:43 PM, Ian Jackson wrote: > Eric Blake writes ("Re: [RFC PATCH 3/7] error reporting: Use > error_report_errno in obvious places"): >> Misses a lot of two-line instances, such as: >> $ git grep -A1 error_report | grep -C1 strerror.errno >> ... > ... >> If we're going to clean up th

Re: [Qemu-devel] Cannot launch QEMU with -accel whpx

2018-04-26 Thread Justin Terry (VM) via Qemu-devel
Hey Wenchao, It looks like your specs should fully support running this. Did you by chance forget to enable the Windows optional feature? Having the lib/dll’s from the SDK isn’t all you need. Try: (admin) PS> Enable-WindowsOptionalFeature -Online -FeatureName HypervisorPlatform (reboot the mac

Re: [Qemu-devel] [PATCH v2 5/5] migration: Stop rdma yielding during incoming postcopy

2018-04-26 Thread Dr. David Alan Gilbert
* Lidong Chen (jemmy858...@gmail.com) wrote: > During incoming postcopy, the destination qemu will invoke > qemu_rdma_wait_comp_channel in a seprate thread. So does not use rdma > yield, and poll the completion channel fd instead. > > Signed-off-by: Lidong Chen OK, I think so; it's a bit delicat

Re: [Qemu-devel] [RFC PATCH 7/7] error reporting: HACKING: Say to use error_report_errno

2018-04-26 Thread Eric Blake
On 04/26/2018 11:53 AM, Ian Jackson wrote: > Signed-off-by: Ian Jackson > --- > HACKING | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/HACKING b/HACKING > index 4125c97..95563a3 100644 > --- a/HACKING > +++ b/HACKING > @@ -189,6 +189,7 @@ error_report() or error_vreport() from error-re

Re: [Qemu-devel] [RFC PATCH 1/7] error reporting: Introduce errnoval parameter to vreport

2018-04-26 Thread Eric Blake
On 04/26/2018 12:32 PM, Ian Jackson wrote: >>> * Print a message to current monitor if we have one, else to stderr. >>> * @report_type is the type of message: error, warning or informational. >>> + * If @errnoval is nonnegative it is fed to strerror and printed too. >> >> That implies 0 is fed

Re: [Qemu-devel] [PATCH v8 25/35] RISC-V: Move non-ops from op_helper to cpu_helper

2018-04-26 Thread Alistair Francis
On Wed, Apr 25, 2018 at 5:13 PM Michael Clark wrote: > This patch makes op_helper.c contain only instruction > operation helpers used by translate.c and moves any > unrelated cpu helpers into cpu_helper.c. No logic is > changed by this patch. > Cc: Sagar Karandikar > Cc: Bastian Koppelmann > C

Re: [Qemu-devel] [RFC PATCH 5/7] error reporting: Provide error_report_errnoval (and error_vreport_errnoval)

2018-04-26 Thread Ian Jackson
Eric Blake writes ("Re: [RFC PATCH 5/7] error reporting: Provide error_report_errnoval (and error_vreport_errnoval)"): > On 04/26/2018 11:53 AM, Ian Jackson wrote: > > I have chosen to provide all of > >error_report_errno error_vreport_errno > >error_report_errnovalerror_vreport_

  1   2   3   4   >