[Qemu-devel] tap networking - how?

2014-02-12 Thread Alexey Kardashevskiy
Hi! I am debugging spapr-vlan and hit the following issue. When I run QEMU as below, the kernel's DHCP client does not continue till I hit any key in console. If I replace spapr-vlan with e1000/rtl8139/virtio-net, everything is just fine. If I use "user" network - everything is fine too. So the p

Re: [Qemu-devel] [PATCH V11 0/8] qcow2: rollback the modification on fail in snapshot creation

2014-02-12 Thread Wenchao Xia
Kevin, this series takes another *errp to detect error in rollback process, are you OK with it?

[Qemu-devel] [PATCH v2] trace backend: introduce multi tracing backend

2014-02-12 Thread Kazuya Saito
This patch implements "multi tracing backend" which enables several tracing backend simultaneously. QEMU has multiple trace backends, but one of them needs to be chosen at compile time. When investigating issues of QEMU, it'd be much more convenient if we can use multiple trace backends without r

Re: [Qemu-devel] [PATCH] block: mirror - insure that errp is not NULL

2014-02-12 Thread Fam Zheng
On Thu, 02/13 07:40, Markus Armbruster wrote: > Jeff Cody writes: > > > When starting a block job, commit_active_start() relies on whether *errp > > is set by mirror_start_job. This allows it to determine if the mirror > > job start failed, so that it can clean up any changes to open flags from

Re: [Qemu-devel] [PATCH] block: mirror - insure that errp is not NULL

2014-02-12 Thread Markus Armbruster
Eric Blake writes: > On 02/12/2014 12:46 PM, Jeff Cody wrote: >> When starting a block job, commit_active_start() relies on whether *errp >> is set by mirror_start_job. This allows it to determine if the mirror >> job start failed, so that it can clean up any changes to open flags from >> the bd

Re: [Qemu-devel] [PATCH] block: mirror - insure that errp is not NULL

2014-02-12 Thread Markus Armbruster
Jeff Cody writes: > When starting a block job, commit_active_start() relies on whether *errp > is set by mirror_start_job. This allows it to determine if the mirror > job start failed, so that it can clean up any changes to open flags from > the bdrv_reopen(). If errp is NULL, then it will not

Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn())

2014-02-12 Thread Chen Fan
On Tue, 2014-01-21 at 11:10 +0100, Andreas Färber wrote: > Am 21.01.2014 10:51, schrieb Chen Fan: > > On Tue, 2014-01-21 at 10:31 +0100, Igor Mammedov wrote: > >> On Tue, 21 Jan 2014 15:12:45 +0800 > >> Chen Fan wrote: > >>> On Mon, 2014-01-20 at 13:29 +0100, Igor Mammedov wrote: > On Fri, 17

[Qemu-devel] [PATCH] qom/cpu: Remove cpu->exit_request from reset state

2014-02-12 Thread edgar . iglesias
From: "Edgar E. Iglesias" cpu->exit_request is part of the execution environment and should not be cleared when a CPU resets. Otherwise, we might deadlock QEMU if a CPU resets while there is I/O going on. Signed-off-by: Edgar E. Iglesias --- qom/cpu.c | 1 - 1 file changed, 1 deletion(-) dif

[Qemu-devel] Use of watch_pipe in xs_handle structure

2014-02-12 Thread Chris Takemura
Hi, I'm trying to debug a problem that causes qemu-dm to lock up with Xen HVM domains. We're using the qemu version that came with Xen 3.4.2. I know it's old, but we're stuck with it for a little while yet. I think the hang is related to thread synchronization and the xenstore, but I'm not s

Re: [Qemu-devel] [PATCH] target-ppc: fix warn_unused_result build break with in-kernel HTAB support

2014-02-12 Thread Aneesh Kumar K.V
Greg Kurz writes: > The 7029677e4 commit introduced the following build break: > > target-ppc/kvm.c: In function ‘kvmppc_hash64_write_pte’: > target-ppc/kvm.c:2017:10: error: ignoring return value of ‘write’, declared > with attribute warn_unused_result [-Werror=unused-result] > write(htab_f

Re: [Qemu-devel] [PATCH] target-ppc: fix 32 bit build break in the page table lookup code

2014-02-12 Thread Aneesh Kumar K.V
Greg Kurz writes: > The 396bb9874 commit reworked page table lookup to support kvm. > Unfortunately this breaks 32 bit build: > > target-ppc/mmu-hash64.h: In function ‘ppc_hash64_load_hpte0’: > target-ppc/mmu-hash64.h:90:23: error: cast to pointer from integer of > different size > > target-ppc/m

[Qemu-devel] [PATCH V10] target-ppc: Fix htab_mask calculation

2014-02-12 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Correctly update the htab_mask using the return value of KVM_PPC_ALLOCATE_HTAB ioctl. Also we don't update sdr1 on GET_SREGS for HV. We check for external htab and if found true, we don't need to update sdr1 Signed-off-by: Aneesh Kumar K.V --- Changes from V9: * Fix TCG

Re: [Qemu-devel] [PATCH v2] RFC: Add blockdev-del QMP command

2014-02-12 Thread Fam Zheng
On Wed, 02/12 09:36, Ian Main wrote: > This is the sister command to blockdev-add. In Fam's example he uses > the drive_del HMP command to clean up but it would be much nicer to > have a way to do this via QMP. > > Signed-off-by: Ian Main Thank you for doing this! > --- > > v2: > - s/blockdev

Re: [Qemu-devel] [PATCH v10 13/13] dump: add 'query-dump-guest-memory-capability' command

2014-02-12 Thread Luiz Capitulino
On Thu, 13 Feb 2014 09:48:33 +0800 Qiao Nuohan wrote: > On 02/12/2014 10:49 PM, Luiz Capitulino wrote: > > On Wed, 12 Feb 2014 14:34:19 +0800 > > Qiao Nuohan wrote: > > > >> 'query-dump-guest-memory-capability' is used to query the available > >> formats for > >> 'dump-guest-memory'. The output

Re: [Qemu-devel] [PATCH v10 13/13] dump: add 'query-dump-guest-memory-capability' command

2014-02-12 Thread Qiao Nuohan
On 02/12/2014 10:49 PM, Luiz Capitulino wrote: On Wed, 12 Feb 2014 14:34:19 +0800 Qiao Nuohan wrote: 'query-dump-guest-memory-capability' is used to query the available formats for 'dump-guest-memory'. The output of the command will be like: -> { "execute": "query-dump-guest-memory-capabilit

Re: [Qemu-devel] PC value translation from guest VA to host VA.

2014-02-12 Thread Hu Tao
On Wed, Feb 12, 2014 at 05:42:00PM +0530, Gaurav Sharma wrote: > To elaborate a bit more ... > If the target is arm, in disas_arm_insn function we fetch the opcode as per > the > pc value : > insn = arm_ldl_code(env, s->pc, s->bswap_code) > > This PC value i could trace back and see actually come

[Qemu-devel] [PATCH] qemu-iotests: Don't run 005 on vmdk split formats

2014-02-12 Thread Fam Zheng
There would be too many extents that VMDK driver can't open all of them: 005 0s ... - output mismatch (see 005.out.bad) --- 005.out 2013-12-24 09:27:27.608181030 +0800 +++ 005.out.bad 2014-02-13 10:00:15.282184557 +0800 @@ -4,10 +4,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt

Re: [Qemu-devel] [PATCH] block: Don't throw away errno via error_setg

2014-02-12 Thread Fam Zheng
On Wed, 02/12 14:46, Jeff Cody wrote: > There are a handful of places in the block layer where a failure path > has a valid -errno value, yet error_setg() is used. Those instances > should instead use error_setg_errno(), to preserve as much error > information as possible. > > This patch replaces

[Qemu-devel] [FIX V2] block: Fix device snapshots broken by the block filter snapshots patchset.

2014-02-12 Thread Benoît Canet
Signed-off-by: Benoit Canet --- block.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/block.c b/block.c index 70d7f35..d9553ba 100644 --- a/block.c +++ b/block.c @@ -5419,11 +5419,7 @@ bool bdrv_is_first_non_filter(BlockDriverState *candidate) QTAILQ_FOREACH(bs, &

[Qemu-devel] [FIX V2] repair snapshots

2014-02-12 Thread Benoît Canet
This patch fix the snapshoting code. When initially testing block filter snapshots patches and quorum I used a wrong quorum command line which containned an extra top level "file." As a result quorum was encapsulated in a top level bs. This caused me to write and test against the wrong configura

Re: [Qemu-devel] [PATCH v3] QMP: Allow dot separated dict path arguments in qmp-shell

2014-02-12 Thread Fam Zheng
On Wed, 02/12 11:14, Eric Blake wrote: > On 02/11/2014 08:05 PM, Fam Zheng wrote: > > As another convinience to allow using commands that expect a dict as > > You missed this, even though I pointed it out in v2: > > s/convinience/convenience/ Oops, I'm sorry for that. Luiz, would you fix this wh

Re: [Qemu-devel] [FIX V2] block: Fix device snapshots broken by the block filter snapshots patchset.

2014-02-12 Thread Benoît Canet
The Wednesday 12 Feb 2014 à 22:43:15 (+0100), Benoît Canet wrote : > The Wednesday 12 Feb 2014 à 20:49:18 (+0100), Benoît Canet wrote : > > The Tuesday 11 Feb 2014 à 16:12:17 (+0800), Fam Zheng wrote : > > > On Mon, 02/10 22:49, Benoît Canet wrote: > > > > Take into account the fact that a block fi

[Qemu-devel] [PATCH] xics-kvm: fix reset function

2014-02-12 Thread Alexey Kardashevskiy
Currently interrupt priorities are set to 0 (highest) at the very beginning of the guest execution which is not correct and makes the guest produce random interrupt error messages such as: "Interrupt 0x1001 (real) is invalid, disabling it". This also prevents interrupt states from correct migration

Re: [Qemu-devel] [PATCH v20 25/26] cleanup QEMUOptionParameter

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Now all places using QEMUOptionParameter could use QemuOpts too, remove > QEMUOptionParameter related code. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > +++ b/include/qemu/option.h > @@ -38,18 +38,6 @@ enum QEMUOptionParType {

Re: [Qemu-devel] [PATCH v20 26/26] change back to original name from bdrv_create2 to bdrv_create

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Rename the new driver callback bdrv_create2 to the old name bdrv_create. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block.c |4 ++-- > block/cow.c |2 +- > block/gluster.c |

Re: [Qemu-devel] [PATCH v20 11/26] qcow2.c: replace QEMUOptionParameter with QemuOpts in create

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > qcow2.c: replace QEMUOptionParameter with QemuOpts in 'qemu-img create'. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block/qcow2.c | 176 > 1 files changed, 88 inserti

Re: [Qemu-devel] [PATCH v20 10/26] qcow.c: replace QEMUOptionParameter with QemuOpts

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > qcow.c: replace QEMUOptionParamter with QemuOpts > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block/qcow.c | 61 - > 1 files changed, 30 insertions(+), 31 deletions(-)

Re: [Qemu-devel] [PATCH v20 09/26] iscsi.c: replace QEMUOptionParameter with QemuOpts

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > iscsi.c: replace QEMUOptionParamter with QemuOpts > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block/iscsi.c | 31 +++ > 1 files changed, 15 insertions(+), 16 deletions(-) > Reviewed-by: Eric Bl

Re: [Qemu-devel] [PATCH v20 08/26] gluster.c: replace QEMUOptionParameter with QemuOpts

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > gluster.c: replace QEMUOptionParameter with QemuOpts > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block/gluster.c | 80 -- > 1 files changed, 41 insertions(+), 39 deletions

Re: [Qemu-devel] [PATCH v20 07/26] cow.c: replace QEMUOptionParameter with QemuOpts

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > cow.c: replace QEMUOptionParameter with QemuOpts > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > block/cow.c | 46 ++ > 1 files changed, 22 insertions(+), 24 deletions(-) > > +stati

Re: [Qemu-devel] [PATCH v20 06/26] change block layer to support both QemuOpts and QEMUOptionParameter

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Change block layer to support both QemuOpts and QEMUOptionParameter. > After this patch, it will change backend drivers one by one. At the end, > QEMUOptionParameter will be removed and only QemuOpts is kept. > > Signed-off-by: Dong Xu Wang > Signed-of

Re: [Qemu-devel] Guest IOMMU and Cisco usnic

2014-02-12 Thread Alex Williamson
On Wed, 2014-02-12 at 23:51 +0100, Benoît Canet wrote: > The Wednesday 12 Feb 2014 à 12:34:25 (-0700), Alex Williamson wrote : > > On Wed, 2014-02-12 at 19:10 +0100, Benoît Canet wrote: > > > Hi Alex, > > > > > > After the IRC conversation we had a few days ago I understood that guest > > > IOMMU

Re: [Qemu-devel] [PATCH v20 05/26] remove assertion of qemu_opt_get functions

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > In qemu_opt_set functions, if desc doen't exist but opts_accepts_any is true, > it s/doen't/doesn't/ > won't report error, but can still alloc an opt for the option and save it. > However, after that, when doing qemu_opt_get, this option could be foun

Re: [Qemu-devel] [PATCH v20 01/26] add def_value_str to QemuOptDesc

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Add def_value_str (default value) to QemuOptDesc, to replace function of the > default value in QEMUOptionParameter. And improved related functions. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > include/qemu/option.h |3 +-

[Qemu-devel] [PATCH] set virtio-net/virtio-mmio host features to improve, performance

2014-02-12 Thread Mario Smarduch
This patch sets the 'virtio-net/virtio-mmio' VirtIOMMIOProxy host_features to all possible virtio-net features supported. Currently most host_features are turned off including performance related ones, this impacts virtio network performance. Host features update should be done earlier but at the

Re: [Qemu-devel] [PATCH v20 04/26] add some QemuOpts functions for replace work

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Add some qemu_opt functions to replace the same functionality of > QEMUOptionParameter handling. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > include/qemu/option.h |9 +++ > util/qemu-option.c| 134 >

[Qemu-devel] [PATCH microblaze/ppc v2 7/8] xilinx: Inline usages of xilinx_axi*_init()

2014-02-12 Thread Peter Crosthwaite
Inline the only usage of each of xilinx_axiethernet_init and xilinx_axidma_init. Converts this init to at least a semi-recent QOM styling. Signed-off-by: Peter Crosthwaite --- hw/microblaze/petalogix_ml605_mmu.c | 24 +++- include/hw/xilinx.h | 33 ---

[Qemu-devel] [PATCH microblaze/ppc v2 8/8] xilinx: Delete hw/include/xilinx.h

2014-02-12 Thread Peter Crosthwaite
This is now obsolete - remove the header and all its inclusions. Signed-off-by: Peter Crosthwaite --- hw/microblaze/petalogix_ml605_mmu.c | 1 - hw/microblaze/petalogix_s3adsp1800_mmu.c | 1 - hw/ppc/virtex_ml507.c| 2 +- include/hw/xilinx.h | 10

[Qemu-devel] [PATCH microblaze/ppc v2 6/8] xilinx: Inline usage of xilinx_ethlite_create()

2014-02-12 Thread Peter Crosthwaite
Inline the only usage. Converts this init to at least a semi-recent QOM styling. Signed-off-by: Peter Crosthwaite --- hw/microblaze/petalogix_s3adsp1800_mmu.c | 9 - include/hw/xilinx.h | 19 --- 2 files changed, 8 insertions(+), 20 deletions(-) di

[Qemu-devel] [PATCH microblaze/ppc v2 5/8] xilinx: Inline usages of xilinx_timer_create()

2014-02-12 Thread Peter Crosthwaite
Inline these usages. Converts these init to at least a semi-recent QOM styling. Signed-off-by: Peter Crosthwaite --- hw/microblaze/petalogix_ml605_mmu.c | 7 ++- hw/microblaze/petalogix_s3adsp1800_mmu.c | 9 - hw/ppc/virtex_ml507.c| 7 ++- include/hw/

[Qemu-devel] [PATCH microblaze/ppc v2 4/8] xilinx: Inline usages of xilinx_intc_create()

2014-02-12 Thread Peter Crosthwaite
Inline these usages. Converts these init to at least a semi-recent QOM styling. Signed-off-by: Peter Crosthwaite --- hw/microblaze/petalogix_ml605_mmu.c | 8 ++-- hw/microblaze/petalogix_s3adsp1800_mmu.c | 9 +++-- hw/ppc/virtex_ml507.c| 6 +- include/hw/

[Qemu-devel] [PATCH microblaze/ppc v2 1/8] microblaze/s3adsp_1800: Define macros for irq map

2014-02-12 Thread Peter Crosthwaite
Define macros for the interrupt map for the sake of self documentation. Signed-off-by: Peter Crosthwaite --- I haven't converted the xilinx_foo_create usages because they will be deleted in following patches hw/microblaze/petalogix_s3adsp1800_mmu.c | 7 ++- 1 file changed, 6 insertions(+),

[Qemu-devel] [PATCH microblaze/ppc v2 2/8] ppc/virtex_ml507: Define macros for irq/memory maps

2014-02-12 Thread Peter Crosthwaite
Define macros for the interrupt and memory maps for the sake of self documentation. Signed-off-by: Peter Crosthwaite --- I haven't converted the xilinx_foo_create usages because they will be deleted in following patches hw/ppc/virtex_ml507.c | 14 +++--- 1 file changed, 11 insertions(+)

[Qemu-devel] [PATCH microblaze/ppc v2 0/8] Remove include/hw/xilinx.h

2014-02-12 Thread Peter Crosthwaite
Hi Edgar, This file is written for a very old qdev style of machine description. Remove by inlining all usages of its functions (which is consistent with the modern preference that qdev_initery should be inline and not in cross-board helper functions). To avoid movement of magic numbers, Define m

Re: [Qemu-devel] [PATCH v20 03/26] improve some functions in qemu-option.c

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Improve opt_get and opt_set group of functions. For opt_get, check and handle > NUlL input; for opt_set, when set to an existing option, rewrite the option s/NUlL/NULL/ > with new value. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu >

Re: [Qemu-devel] [PATCH v20 02/26] qapi: output def_value_str when query command line options

2014-02-12 Thread Eric Blake
On 02/11/2014 11:33 PM, Chunyan Liu wrote: > Change qapi interfaces to output the newly added def_value_str when query s/query/querying/ > command line options. > > Signed-off-by: Dong Xu Wang > Signed-off-by: Chunyan Liu > --- > +++ b/qapi-schema.json > @@ -3930,12 +3930,16 @@ > # > # @hel

Re: [Qemu-devel] [PATCH target-arm v5 1/1] target-arm: Implements the ARM PMCCNTR register

2014-02-12 Thread Peter Crosthwaite
On Thu, Feb 13, 2014 at 5:32 AM, Peter Maydell wrote: > On 31 January 2014 04:44, Alistair Francis > wrote: >> This patch implements the ARM PMCCNTR register including >> the disable and reset components of the PMCR register. >> >> Signed-off-by: Alistair Francis > > I'm afraid you'll need to r

[Qemu-devel] [PATCH 21/28] target-ppc: Altivec 2.07: vbpermq Instruction

2014-02-12 Thread Tom Musta
This patch adds the Vector Bit Permute Quadword (vbpermq) instruction introduced in Power ISA Version 2.07. Signed-off-by: Tom Musta --- target-ppc/helper.h |1 + target-ppc/int_helper.c | 31 +++ target-ppc/translate.c |2 ++ 3 files changed, 34 insert

Re: [Qemu-devel] Guest IOMMU and Cisco usnic

2014-02-12 Thread Benoît Canet
The Wednesday 12 Feb 2014 à 12:34:25 (-0700), Alex Williamson wrote : > On Wed, 2014-02-12 at 19:10 +0100, Benoît Canet wrote: > > Hi Alex, > > > > After the IRC conversation we had a few days ago I understood that guest > > IOMMU > > was not implemented. > > > > I have a real use case for it: >

[Qemu-devel] [PATCH 03/28] target-ppc: Altivec 2.07: Add GEN_VXFORM3

2014-02-12 Thread Tom Musta
This patch adds generator macro for Altivec instructions that have 3 source AVR operands. The macro is similar to the 2 operand form. Signed-off-by: Tom Musta --- target-ppc/translate.c | 19 +++ 1 files changed, 19 insertions(+), 0 deletions(-) diff --git a/target-ppc/transl

Re: [Qemu-devel] [PATCH v4] implementing victim TLB for QEMU system emulated TLB

2014-02-12 Thread Peter Maydell
On 3 February 2014 15:18, Xin Tong wrote: > This patch adds a victim TLB to the QEMU system mode TLB. > @@ -264,8 +286,15 @@ void tlb_set_page(CPUArchState *env, target_ulong vaddr, > prot, &address); > > index = (vaddr >> TARGET_PAGE_BITS) & (CPU

Re: [Qemu-devel] Guest IOMMU and Cisco usnic

2014-02-12 Thread Benoît Canet
The Wednesday 12 Feb 2014 à 12:34:25 (-0700), Alex Williamson wrote : > On Wed, 2014-02-12 at 19:10 +0100, Benoît Canet wrote: > > Hi Alex, > > > > After the IRC conversation we had a few days ago I understood that guest > > IOMMU > > was not implemented. > > > > I have a real use case for it: >

[Qemu-devel] [PATCH 23/28] target-ppc: Altivec 2.07: Vector Gather Bits by Bytes

2014-02-12 Thread Tom Musta
This patch adds the Vector Gather Bits by Bytes Doubleword (vgbbd) instruction which is introduced in Power ISA Version 2.07. Signed-off-by: Tom Musta --- target-ppc/helper.h |1 + target-ppc/int_helper.c | 276 +++ target-ppc/translate.c |

[Qemu-devel] [PATCH 13/28] target-ppc: Altivec 2.07: Vector Population Count Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector Population Count instructions introduced in Power ISA Version 2.07: vpopcntb, vpopcnth, vpopcntw and vpopcntd. Signed-off-by: Tom Musta --- target-ppc/helper.h |4 target-ppc/int_helper.c | 14 ++ target-ppc/translate.c | 22 ++

[Qemu-devel] [PATCH 10/28] target-ppc: Altivec 2.07: Multiply Even/Odd Word Instructions

2014-02-12 Thread Tom Musta
This patch adds the Multilpy Even/Odd Word instructions that are introduced in Power ISA Version 2.07: - Vector Multiply Even Unsigned Word (vmuleuw) - Vector Multiply Even Signed Word (vmulesw) - Vector Multiply Odd Unsigned Word (vmulouw) - Vector Multiply Odd Signed Word (vmulosw) Sign

[Qemu-devel] [PATCH 19/28] target-ppc: Altivec 2.07: Vector Doubleword Rotate and Shift Instructions

2014-02-12 Thread Tom Musta
This patch adds the vector doublword rotate and shift instructions introduced in Power ISA Version 2.07: - Vector Rotate Left Doubleword instruction (vrld) - Vector Shift Left Doubleword (vsld) - Vector Shift Right Doubleword (vsrd) - Vector Shift Right Algegbraic Doubleword (vsrad) Signe

[Qemu-devel] [PATCH 20/28] target-ppc: Altivec 2.07: Quadword Addition and Subtracation

2014-02-12 Thread Tom Musta
This patch adds the Vector Quadword Addition and Subtraction instructions introduced in Power ISA Version 2.07: - Vector Add Unsigned Quadword Modulo (vadduqm) - Vector Add & Write Carry Unsigned Quadword (vaddcuq) - Vector Add Extended Unsigned Quadword (vaddeuqm) - Vector Add Extended &

[Qemu-devel] [PATCH V17 00/12] quorum block filter

2014-02-12 Thread Benoît Canet
I post this for review in prevision of 2.0 feature freeze. Even if the series look correct please wait before merging because: The QMP events in the "Add quorum mechanism" definitively needs to be reviewed by Eric as they where changed. I did not found any bugs while testing this version but I am

[Qemu-devel] [PATCH V17 09/12] quorum: Add quorum_co_flush().

2014-02-12 Thread Benoît Canet
From: Benoît Canet Makes a vote to select error if any. Signed-off-by: Benoit Canet --- block/quorum.c | 28 1 file changed, 28 insertions(+) diff --git a/block/quorum.c b/block/quorum.c index 5f8f626..818c72c 100644 --- a/block/quorum.c +++ b/block/quorum.c @@ -6

[Qemu-devel] [PATCH V17 11/12] quorum: Add quorum_open() and quorum_close().

2014-02-12 Thread Benoît Canet
From: Benoît Canet Example of command line: -drive if=virtio,file.driver=quorum,\ file.children.0.file.filename=1.raw,\ file.children.0.node-name=1.raw,\ file.children.0.driver=raw,\ file.children.1.file.filename=2.raw,\ file.children.1.node-name=2.raw,\ file.children.1.driver=raw,\ file.children

[Qemu-devel] [PATCH V17 12/12] quorum: Add unit test.

2014-02-12 Thread Benoît Canet
Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- tests/qemu-iotests/081 | 95 ++ tests/qemu-iotests/081.out | 34 + tests/qemu-iotests/group | 1 + 3 files changed, 130 insertions(+) create mode 100755 tests/qemu-iotests/0

[Qemu-devel] [PATCH V17 10/12] quorum: Implement recursive .bdrv_recurse_is_first_non_filter in quorum.

2014-02-12 Thread Benoît Canet
From: Benoît Canet This is used to activate quorum snapshot. Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/quorum.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/block/quorum.c b/block/quorum.c index 818c72c..8e033ef 100644 --- a/block/quorum.c +++ b/

[Qemu-devel] [PATCH 08/28] target-ppc: Altivec 2.07: Add/Subtract Unsigned Doubleword Modulo

2014-02-12 Thread Tom Musta
This patch adds two Altivec unsigned doublword modulo instructions that are introduced in Power ISA Version V2.07: - vaddudm : Vector Add Unsigned Doubleword Modulo - vsubudm : Vector Subtrace Unsigned Doubleword Modulo Signed-off-by: Tom Musta --- target-ppc/helper.h |2 ++ target-

[Qemu-devel] [PATCH V17 05/12] quorum: Add quorum_aio_readv.

2014-02-12 Thread Benoît Canet
From: Benoît Canet Add code to do num_children reads in parallel and cleanup the structures afterward. Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/quorum.c | 39 ++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/block/quorum

[Qemu-devel] [PATCH V17 04/12] blkverify: Extract qemu_iovec_clone() and qemu_iovec_compare() from blkverify.

2014-02-12 Thread Benoît Canet
From: Benoît Canet qemu_iovec_compare() will be used to compare IOs vectors in quorum blkverify mode. The patch extract these functions in order to factorize the code. Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/blkverify.c | 108 +-

[Qemu-devel] [PATCH V17 01/12] quorum: Create quorum.c, add QuorumChildRequest and QuorumAIOCB.

2014-02-12 Thread Benoît Canet
From: Benoît Canet Quorum is a block filter mirroring writes to num_children children. For reads quorum reads each children and does a vote. If more than vote_threshold versions are identicals the quorum is reached and this winning version is returned to the guest. So quorum prevents bit corrupt

[Qemu-devel] [PATCH V17 08/12] quorum: Add quorum_invalidate_cache().

2014-02-12 Thread Benoît Canet
From: Benoît Canet We really want that live migration works with quorum so implement quorum_invalidate_cache(). Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/quorum.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/block/quorum.c b/block/quorum.c index 2e54921.

[Qemu-devel] [PATCH V17 03/12] quorum: Add quorum_aio_writev and its dependencies.

2014-02-12 Thread Benoît Canet
From: Benoît Canet Writes are mirrored num_children times on num_children devices. Signed-off-by: Benoit Canet --- block/quorum.c | 103 + 1 file changed, 103 insertions(+) diff --git a/block/quorum.c b/block/quorum.c index 36c5bb8..197c

[Qemu-devel] [PATCH V17 07/12] quorum: Add quorum_getlength().

2014-02-12 Thread Benoît Canet
From: Benoît Canet Check that every bs file returns the same length. Otherwise, return -EIO to disable the quorum and avoid length discrepancy. Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/quorum.c | 26 ++ 1 file changed, 26 insertions(+) diff --git a

[Qemu-devel] [PATCH V17 06/12] quorum: Add quorum mechanism.

2014-02-12 Thread Benoît Canet
From: Benoît Canet This patchset enable the core of the quorum mechanism. The num_children reads are compared to get the majority version and if this version exist more than threshold time the guest won't see the error at all. QMP events are used to report individual driver errors or whole quorum

[Qemu-devel] [PATCH 09/28] target-ppc: Altivec 2.07: Change VMUL_DO to Support 64-bit Integers

2014-02-12 Thread Tom Musta
This VMUL_DO macro provides support for the various vmule* and vmulo* instructions. These instructions multiply vector elements, producing products that are one size larger; e.g. vmuleub multiplies unsigned 8-bit elements and produces a 16 bit unsigned element. The existing macro works correctly

[Qemu-devel] [PATCH V17 02/12] quorum: Create BDRVQuorumState and BlkDriver and do init.

2014-02-12 Thread Benoît Canet
From: Benoît Canet Create the structure holding the quorum settings and write the minimal block driver instanciation boilerplate. Signed-off-by: Benoit Canet Reviewed-by: Max Reitz --- block/quorum.c | 31 +++ 1 file changed, 31 insertions(+) diff --git a/block/qu

[Qemu-devel] [PATCH 16/28] target-ppc: Altivec 2.07: Unpack Signed Word Instructions

2014-02-12 Thread Tom Musta
This patch adds the Unpack Signed Word instructions introduced in Power ISA Version 2.07: - Vector Unpack High Signed Word (vupkusw) - Vector Unpack Low Signed Word (vupklsw) Signed-off-by: Tom Musta --- target-ppc/helper.h |2 ++ target-ppc/int_helper.c |2 ++ target-ppc/transl

[Qemu-devel] [PATCH 28/28] target-ppc: Altivec 2.07: Vector Permute and Exclusive OR

2014-02-12 Thread Tom Musta
This patch adds the Vector Permuate and Exclusive OR (vpermxor) instruction introduced in Power ISA Version 2.07. Signed-off-by: Tom Musta --- target-ppc/helper.h |1 + target-ppc/int_helper.c | 14 ++ target-ppc/translate.c |7 ++- 3 files changed, 21 insertions(+

[Qemu-devel] [PATCH 12/28] target-ppc: Altivec 2.07: Add Vector Count Leading Zeroes

2014-02-12 Thread Tom Musta
This patch adds the Vector Count Leading Zeroes instructions introduced in Power ISA Version 2.07 - vclzb, vclzh, vclzw and vclzd. Signed-off-by: Tom Musta --- target-ppc/helper.h |5 + target-ppc/int_helper.c | 29 + target-ppc/translate.c |9 +

[Qemu-devel] [PATCH] virtio-net: Do not filter VLANs without F_CTRL_VLAN

2014-02-12 Thread Stefan Fritsch
If VIRTIO_NET_F_CTRL_VLAN is not negotiated, do not filter out all VLAN-tagged packets but send them to the guest. Signed-off-by: Stefan Fritsch --- This time CCing the maintainers. This fixes VLANs with OpenBSD guests (and probably NetBSD, too, because the OpenBSD driver started as a port from

Re: [Qemu-devel] [FIX V2] block: Fix device snapshots broken by the block filter snapshots patchset.

2014-02-12 Thread Benoît Canet
The Wednesday 12 Feb 2014 à 20:49:18 (+0100), Benoît Canet wrote : > The Tuesday 11 Feb 2014 à 16:12:17 (+0800), Fam Zheng wrote : > > On Mon, 02/10 22:49, Benoît Canet wrote: > > > Take into account the fact that a block filter like quorum will be in > > > bs->file > > > while a regular block dri

[Qemu-devel] [PATCH 2/2] block: qemu-iotests - add vhdx log replay tests for qemu-img

2014-02-12 Thread Jeff Cody
VHDX logs can now be replayed via 'qemu-img check -r all'. Add tests to verify that the log replay is successful when using qemu-img. Signed-off-by: Jeff Cody --- tests/qemu-iotests/070 | 10 ++ tests/qemu-iotests/070.out | 11 +++ 2 files changed, 21 insertions(+) diff --g

[Qemu-devel] [PATCH 26/28] target-ppc: Altivec 2.07: AES Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector AES instructions introduced in Power ISA Version 2.07: - Vector AES Cipher (vcipher) - Vector AES Cipher Last (vcipherlast) - Vector AES Inverse Cipher (vncipher) - Vector AES Inverse Cipher Last (vncipherlast) - Vector AES SubBytes (vsbox) Note that the

[Qemu-devel] [PATCH 25/28] target-ppc: Altivec 2.07: Binary Coded Decimal Instructions

2014-02-12 Thread Tom Musta
This patch add the Binary Coded Decimal instructions bcdadd. and bcdsub. Signed-off-by: Tom Musta --- target-ppc/helper.h |3 + target-ppc/int_helper.c | 201 +++ target-ppc/translate.c | 45 ++- 3 files changed, 245 insertions(+),

[Qemu-devel] [PATCH 1/2] block: qemu-iotests - fix test 070 (vhdx)

2014-02-12 Thread Jeff Cody
VHDX test 070 failed, due to different output from qemu-io / qemu when opening an image read-only that contains a log file. Filter the output, and update the expected results to match the correct output. Signed-off-by: Jeff Cody --- tests/qemu-iotests/070 | 3 ++- tests/qemu-iotests/070.out

[Qemu-devel] [PATCH 24/28] target-ppc: Altivec 2.07: Vector Polynomial Multiply Sum

2014-02-12 Thread Tom Musta
This patch adds the Vectory Polynomial Multiply Sum instructions introduced in Power ISA Version 2.07: - Vectory Polynomial Multiply Sum Byte (vpmsumb) - Vectory Polynomial Multiply Sum Halfword (vpmsumh) - Vectory Polynomial Multiply Sum Word (vpmsumw) - Vectory Polynomial Multiply Sum Do

[Qemu-devel] [PATCH 0/2] qemu-iotest fixes and updates for 070

2014-02-12 Thread Jeff Cody
This fixes a bug with test 070 (incorrect output expectation), and adds additional test for log replay. Jeff Cody (2): block: qemu-iotests - fix test 070 (vhdx) block: qemu-iotests - add vhdx log replay tests for qemu-img tests/qemu-iotests/070 | 13 - tests/qemu-iotests/070

[Qemu-devel] [PATCH 22/28] target-ppc: Altivec 2.07: Doubleword Compares

2014-02-12 Thread Tom Musta
This patch adds the Vector Compare Doubleword instructions introduced by Power ISA Version 2.07: - Vector Compare Equal to Unsigned Doubleword (vcmpequd) - Vector Compare Greater Than Signed Doubleword (vcmpgtsd) - Vector Compare Greater Than Unsigned Doubleword (vcmpgtud) These instruction

[Qemu-devel] [PATCH 06/28] target-ppc: Altivec 2.07: Add Support for R-Form Dual Instructions

2014-02-12 Thread Tom Musta
Some Alitvec instructions introduced in Power ISA Version 2.07 use bit 31 (aka the "Rc" bit) as an opcode but also use bit 21 as an actual Rc bit. QEMU for PowerPC typically uses bits 0-5 and 21-30 for opcodes. This patch introduces a generator macro that injects an auxiliary handler which decode

[Qemu-devel] [PATCH 15/28] target-ppc: Altivec 2.07: Pack Doubleword Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector Pack Doubleword instructions introduced in Power ISA Version 2.07: - Vector Pack Signed Doubleword Signed Saturate (vpksdss) - Vector Pack Signed Doubleword Unsigned Saturate (vpksdus) - Vector Pack Unsigned Doubleword Unsigned Modulo (vpkudum) - Vector Pack Unsigned

[Qemu-devel] [PATCH 27/28] target-ppc: Altivec 2.07: Vector SHA Sigma Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector SHA Sigma instructions introduced in Power ISA Version 2.07: - Vector SHA-512 Sigma Doubleword (vshasigmad) - Vector SHA-256 Sigma Word (vshasigmaw) Signed-off-by: Tom Musta --- target-ppc/helper.h |2 + target-ppc/int_helper.c | 82 +

[Qemu-devel] [PATCH 18/28] target-ppc: Altivec 2.07: Change Bit Masks to Support 64-bit Rotates and Shifts

2014-02-12 Thread Tom Musta
Existing code in the VROTATE, VSL and VSR macros for the Altivec rotate and shift helpers uses a formula to compute a bit mask used to extract the rotate/shift amount from the VRB register. What is desired is: mask = (1 << (3 + log2(sizeof(element - 1 but what is implemented is: ma

[Qemu-devel] [PATCH 14/28] target-ppc: Altivec 2.07: Vector Min/Max Doubleword Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector Minimum and Maximum Doubleword instructions that are introduced in Power ISA Version 2.07. Signed-off-by: Tom Musta --- target-ppc/helper.h |4 target-ppc/int_helper.c |2 ++ target-ppc/translate.c |8 3 files changed, 14 insertions(+), 0

[Qemu-devel] [PATCH 17/28] target-ppc: Altivec 2.07: Vector Merge Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector Merge Even Word (vmrgew) and Vector Merge Odd Word (vmrgow) instructions introduced in Power ISA Version 2.07. Signed-off-by: Tom Musta --- target-ppc/translate.c | 37 + 1 files changed, 37 insertions(+), 0 deletions(-) diff --gi

[Qemu-devel] [PATCH 11/28] target-ppc: Altivec 2.07: vmuluw Instruction

2014-02-12 Thread Tom Musta
This patch adds the Vector Multiply Unsigned Word Modulo (vmuluwm) instruction. The existing VARITH_DO macro is re-used to (trivially) instantiate the helper code. Since bits 21-31 of any vmuluwm instruction is 137, the instruction is coded as a dual to vmulouw (bits 21-31 = 136). Signed-off-by:

[Qemu-devel] [PATCH 07/28] target-ppc: Altivec 2.07: Vector Logical Instructions

2014-02-12 Thread Tom Musta
This patch adds the Vector Logical Instructions that are introduced in Power ISA Version 2.07: veqv, vnand and vorc. Signed-off-by: Tom Musta --- target-ppc/translate.c | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/target-ppc/translate.c b/target-ppc/transla

[Qemu-devel] [PATCH 05/28] target-ppc: Altivec 2.07: Add Opcode Macro for VX Form Instructions

2014-02-12 Thread Tom Musta
This patch adds a macro to insert an entry into the opcode table for Altivec Power ISA Version 2.07 instructions. The macro is similar to the GEN_VXFORM macro except that it tags the entry with the PPC2_ALTIVEC_207 flag rather than PPC_ALTIVEC. Signed-off-by: Tom Musta --- target-ppc/translate

[Qemu-devel] [PATCH 04/28] target-ppc: Altivec 2.07: Add Support for Dual Altivec Instructions

2014-02-12 Thread Tom Musta
Some Alitvec instructions introduced in Power ISA Version 2.07 use bit 31 (aka the "Rc" bit) as an opcode bit. However, QEMU for PowerPC uses bits 0-5 and 21-30 for opcodes and not bit 31. This patch introduces macros that will handle this situation by injecting an auxiliary handler which decodes

[Qemu-devel] [PATCH 02/28] target-ppc: Altivec 2.07: Update AVR Structure

2014-02-12 Thread Tom Musta
This patch updates the ppc_avr_t data structure to include elements for signed 64-bit integers and (conditionally) unsigned 128 bit integers. These elements will be in instructions models later on in this patch series. Signed-off-by: Tom Musta --- target-ppc/cpu.h |4 1 files changed, 4

[Qemu-devel] [PATCH 01/28] target-ppc: Altivec 2.07: Add Instruction Flag

2014-02-12 Thread Tom Musta
This patch adds a flag that will be used to tag the Altivec instructions introduced in Power ISA Version 2.07. The flag is added to Power8 model since P8 supports these instructions. Signed-off-by: Tom Musta --- target-ppc/cpu.h|5 - target-ppc/translate_init.c |2 +- 2

[Qemu-devel] [PATCH 00/28] target-ppc: Altivec 2.07

2014-02-12 Thread Tom Musta
This patch series implements the changes to Altivec introduced by Power ISA Version 2.07. Tom Musta (28): target-ppc: Altivec 2.07: Add Instruction Flag target-ppc: Altivec 2.07: Update AVR Structure target-ppc: Altivec 2.07: Add GEN_VXFORM3 target-ppc: Altivec 2.07: Add Support for Dual A

Re: [Qemu-devel] [PATCH 5/5] query-command-line-options: return help message for legacy options

2014-02-12 Thread Eric Blake
On 01/27/2014 08:53 PM, Amos Kong wrote: > Some legacy options that have arguments weren't added to > vm_config_groups[], so query-command-line-options returns a > NULL parameters infolist. This patch try to return help message > for this kind of legacy options. > > Example: > { > "helpmsg":

[Qemu-devel] [Bug 1279500] Re: system_powerdown causes SMP OpenBSD guest to freeze

2014-02-12 Thread Robert Urban
(qemu-kvm-0.12.5) - Fedora 20: qemu-system-x86-1.6.1 (from Fedora repository) qemu-1.7.0 (latest release version) qemu-1.7.50 (latest development snapshot, "git cloned" today, 20140212) all of the above hosts are running x86_64 linux. The first OpenBSD vers

Re: [Qemu-devel] [PATCH 5/5] query-command-line-options: return help message for legacy options

2014-02-12 Thread Eric Blake
On 02/11/2014 05:19 AM, Markus Armbruster wrote: > [Note cc: Eric] > > Amos Kong writes: > >> Some legacy options that have arguments weren't added to >> vm_config_groups[], so query-command-line-options returns a >> NULL parameters infolist. This patch try to return help message >> for this kin

  1   2   >