Re: [Qemu-devel] [PATCH v13 00/14] Drop in_use from BlockDriverState and enable point-in-time snapshot exporting over NBD

2014-01-31 Thread Ian Main
On Wed, Jan 29, 2014 at 01:07:27PM +0800, Fam Zheng wrote: > This series adds for point-in-time snapshot NBD exporting based on > blockdev-backup (variant of drive-backup with existing device as target). > > We get a thin point-in-time snapshot by COW mechanism of drive-backup, and > export it thr

Re: [Qemu-devel] [PATCH 20/42] input: mouse: add graphic_rotate support

2014-01-31 Thread Paolo Bonzini
Il 28/01/2014 10:57, Gerd Hoffmann ha scritto: Transform absolute mouse events according to graphic_rotate. Legacy input code does it for both absolute and relative events, but the logic is broken for relative coordinates, so this is most likely not used anyway. Signed-off-by: Gerd Hoffmann --

[Qemu-devel] [Bug 1130095] Re: Windows Signed Drivers

2014-01-31 Thread David Lee Lambert
** Description changed: - Hello! + ReactOS has a general offer (subject to certain conditions, which may or + may not be reasonable for the qemu virtual-IO drivers) to sign Open + Source components with their certificate. + http://www.reactos.org/wiki/Driver_Signing - If it helps you :) - Free

Re: [Qemu-devel] osx bootloader

2014-01-31 Thread BALATON Zoltan
On Wed, 29 Jan 2014, Gabriel L. Somlo wrote: I managed to boot OVMF following their wiki; It seems to work with kvm enabled, but not with -M q35. My current command line is: I've tried with the version compiled from the edk2 HEAD and that also fails with -M q35. I've managed to get some debug

[Qemu-devel] [PATCH v6 2/2] target-ppc: spapr: e500: fix to use cpu_dt_id

2014-01-31 Thread Alexey Kardashevskiy
This makes use of @cpu_dt_id and related API in: 1. emulated XICS hypercall handlers as they receive fixed CPU indexes; 2. XICS-KVM to enable in-kernel XICS on right CPU; 3. device-tree renderer. This removes @cpu_index fixup as @cpu_dt_id is used instead so QEMU monitor can accept command-line CP

[Qemu-devel] [PATCH v6 0/2] target-ppc: CPU device tree id

2014-01-31 Thread Alexey Kardashevskiy
This is some cleanup. Please, comment. Thanks! Changes: v6: * removed kvmppc_fixup_cpu() v5: * cleanup * removed cpustate::kvm_cpu_id * split into 2 patches - new PPC API and the usage of the API Alexey Kardashevskiy (2): target-ppc: add PowerPCCPU::cpu_dt_id target-ppc: spapr: e500: fi

[Qemu-devel] [PATCH v6 1/2] target-ppc: add PowerPCCPU::cpu_dt_id

2014-01-31 Thread Alexey Kardashevskiy
Normally CPUState::cpu_index is used to pick the right CPU for various operations. However default consecutive numbering does not always work for POWERPC. These indexes are reflected in /proc/device-tree/cpus/PowerPC,POWER7@XX and used to call KVM VCPU's ioctls. In order to achieve this, kvmppc_fi

Re: [Qemu-devel] [PATCH V10 06/13] quorum: Add quorum mechanism.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Use gnutls's SHA-256 to compare versions. Signed-off-by: Benoit Canet --- block/Makefile.objs | 2 +- block/quorum.c| 333 +- configure | 36 +

[Qemu-devel] [PATCH] i386: Add missing include file for QEMU_PACKED

2014-01-31 Thread Stefan Weil
Instead of packing BiosLinkerLoaderEntry, an unused global variable called QEMU_PACKED was created (detected by smatch static code analysis). Including qemu-common.h gets the right definition and also includes some standard include files which now can be removed here. Cc: qemu-sta...@nongnu.org S

Re: [Qemu-devel] [PATCH V10 05/13] quorum: Add quorum_aio_readv.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Signed-off-by: Benoit Canet --- block/quorum.c | 40 +++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/block/quorum.c b/block/quorum.c index 85992ab..5bf37b3 100644 --- a/block/q

Re: [Qemu-devel] [PATCH V6 8/8] block: Use graph node name as reference in bdrv_file_open().

2014-01-31 Thread Benoît Canet
Le Friday 31 Jan 2014 à 21:32:34 (+0100), Max Reitz a écrit : > On 28.01.2014 01:04, Benoît Canet wrote: > >Le Monday 27 Jan 2014 à 20:11:59 (+0100), Max Reitz a écrit : > >>On 27.01.2014 15:36, Benoît Canet wrote: > >>>Le Friday 24 Jan 2014 à 15:54:39 (+0100), Max Reitz a écrit : > On 24.01.20

Re: [Qemu-devel] [PATCH V10 04/13] blkverify: Extract qemu_iovec_clone() and qemu_iovec_compare() from blkverify.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Signed-off-by: Benoit Canet --- block/blkverify.c | 108 +- include/qemu-common.h | 2 + util/iov.c| 103 +++ 3 files c

[Qemu-devel] [PULL 7/8] dataplane: Comment fix

2014-01-31 Thread Stefan Hajnoczi
From: Markus Armbruster Signed-off-by: Markus Armbruster Signed-off-by: Stefan Hajnoczi --- hw/block/dataplane/virtio-blk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/block/dataplane/virtio-blk.c b/hw/block/dataplane/virtio-blk.c index 456d437..2237edb 100644 --- a/

[Qemu-devel] [PULL 2/8] block: remove QED .bdrv_make_empty implementation

2014-01-31 Thread Stefan Hajnoczi
From: Jeff Cody The QED .bdrv_make_empty() implementation does nothing but return -ENOTSUP, which causes problems in bdrv_commit(). Since the function stub exists for QED, it is called, which then always returns an error. The proper way to not support an optional driver function stub is to just

[Qemu-devel] [PULL 6/8] block/vhdx: Error checking fixes

2014-01-31 Thread Stefan Hajnoczi
From: Markus Armbruster Errors are inadvertently ignored in a few places. Has always been broken. Spotted by Coverity. Signed-off-by: Markus Armbruster Reviewed-by: Jeff Cody Signed-off-by: Stefan Hajnoczi --- block/vhdx-log.c | 4 ++-- block/vhdx.c | 8 2 files changed, 6 ins

[Qemu-devel] [PULL 5/8] qemu-iotests: Drop assert_no_active_commit in case 040

2014-01-31 Thread Stefan Hajnoczi
From: Fam Zheng It is exactly assert_no_active_block_jobs in iotests.py Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- tests/qemu-iotests/040 | 28 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/tests/qemu-iotests/040 b/tests/qemu-iot

[Qemu-devel] [PULL 4/8] block/vmdk: add basic .bdrv_check support

2014-01-31 Thread Stefan Hajnoczi
From: Peter Lieven this adds a basic vmdk corruption check. it should detect severe table corruptions and file truncation. Signed-off-by: Peter Lieven Reviewed-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- block/vmdk.c | 48 1 file changed,

[Qemu-devel] [PULL 8/8] qemu-iotests: only run 071 on qcow2

2014-01-31 Thread Stefan Hajnoczi
The 071 test is designed for IMGFMT=qcow2 because it uses the l2_load blkdebug event. Its output filtering also assumes that IMGFMT is not raw since 071.out contains "format=raw" but IMGFMT=raw would filter the output to "format=IMGFMT". Perhaps the test case can be rewritten to be more generic,

[Qemu-devel] [PULL 1/8] Describe flaws in qcow/qcow2 encryption in the docs

2014-01-31 Thread Stefan Hajnoczi
From: "Daniel P. Berrange" The qemu-img.texi / qemu-doc.texi files currently describe the qcow2/qcow2 encryption thus "Encryption uses the AES format which is very secure (128 bit keys). Use a long password (16 characters) to get maximum protection." While AES is indeed a strong encrypt

[Qemu-devel] [PULL 3/8] block: remove qcow2 .bdrv_make_empty implementation

2014-01-31 Thread Stefan Hajnoczi
From: Jeff Cody The QCOW2 .bdrv_make_empty implementation always returns 0 for success, but does not actually do anything. The proper way to not support an optional driver function stub is to just not implement it, so let's remove the stub. Signed-off-by: Jeff Cody Reviewed-by: Benoit Canet S

[Qemu-devel] [PULL 0/8] Block patches

2014-01-31 Thread Stefan Hajnoczi
The following changes since commit 89e4a51ca9546a7bbe1998c4e3d4a3ac3a0c19be: Merge remote-tracking branch 'stefanha/tags/tracing-pull-request' into staging (2014-01-31 11:13:08 +) are available in the git repository at: git://github.com/stefanha/qemu.git tags/block-pull-request for yo

Re: [Qemu-devel] [PATCH V10 03/13] quorum: Add quorum_aio_writev and its dependencies.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Signed-off-by: Benoit Canet --- block/quorum.c | 123 + 1 file changed, 123 insertions(+) Reviewed-by: Max Reitz

Re: [Qemu-devel] [PATCH V10 02/13] quorum: Create BDRVQuorumState and BlkDriver and do init.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Signed-off-by: Benoit Canet --- block/quorum.c | 25 + 1 file changed, 25 insertions(+) Reviewed-by: Max Reitz

Re: [Qemu-devel] [PATCH V10 01/13] quorum: Create quorum.c, add QuorumSingleAIOCB and QuorumAIOCB.

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: From: Benoît Canet Signed-off-by: Benoit Canet --- block/Makefile.objs | 1 + block/quorum.c | 54 + 2 files changed, 55 insertions(+) create mode 100644 block/quorum.c Reviewed-by: Max R

Re: [Qemu-devel] [PATCHv8 0/5] block: add native support for NFS

2014-01-31 Thread Max Reitz
On 31.01.2014 21:41, Stefan Hajnoczi wrote: On Fri, Jan 31, 2014 at 6:32 PM, Peter Lieven wrote: Am 31.01.2014 um 17:07 schrieb Stefan Hajnoczi : On Fri, Jan 31, 2014 at 12:38:48PM +0100, Peter Lieven wrote: This adds v6 of the NFS protocol driver + qemu-iotest adjustments. v7->v8: - bump l

Re: [Qemu-devel] [PATCHv8 0/5] block: add native support for NFS

2014-01-31 Thread Stefan Hajnoczi
On Fri, Jan 31, 2014 at 6:32 PM, Peter Lieven wrote: > > Am 31.01.2014 um 17:07 schrieb Stefan Hajnoczi : > >> On Fri, Jan 31, 2014 at 12:38:48PM +0100, Peter Lieven wrote: >>> This adds v6 of the NFS protocol driver + qemu-iotest adjustments. >>> >>> v7->v8: >>> - bump libnfs requirement to 1.9.2

Re: [Qemu-devel] [PATCH V10 00/13] Quorum block driver

2014-01-31 Thread Max Reitz
On 28.01.2014 17:52, Benoît Canet wrote: Here is the new version of the QUORUM block driver. It now use bdrv_image_open for using QMP references and support snapshotting via the bs node-name infrastructure. I think the series is feature complete. It applies on top of Max bdrv_openv2 branch. W

Re: [Qemu-devel] [PATCH V6 8/8] block: Use graph node name as reference in bdrv_file_open().

2014-01-31 Thread Max Reitz
On 28.01.2014 01:04, Benoît Canet wrote: Le Monday 27 Jan 2014 à 20:11:59 (+0100), Max Reitz a écrit : On 27.01.2014 15:36, Benoît Canet wrote: Le Friday 24 Jan 2014 à 15:54:39 (+0100), Max Reitz a écrit : On 24.01.2014 15:48, Kevin Wolf wrote: Am 24.01.2014 um 14:37 hat Max Reitz geschrieben

Re: [Qemu-devel] [PATCH 08/10] block: Reuse bs->options setting from bdrv_open()

2014-01-31 Thread Max Reitz
On 29.01.2014 14:45, Kevin Wolf wrote: Am 26.01.2014 um 20:02 hat Max Reitz geschrieben: Setting bs->options in bdrv_file_open() is not necessary if it is already done in bdrv_open(). Signed-off-by: Max Reitz Perhaps squash this into patch 7? Because now the reference is created by bdrv_open(

Re: [Qemu-devel] [PATCH 03/10] block: Make bdrv_file_open() static

2014-01-31 Thread Max Reitz
On 29.01.2014 14:26, Kevin Wolf wrote: Am 26.01.2014 um 20:02 hat Max Reitz geschrieben: Add the bdrv_open() option BDRV_O_PROTOCOL which results in passing the call to bdrv_file_open(). Additionally, make bdrv_file_open() static and therefore bdrv_open() the only way to call it. Consequently,

Re: [Qemu-devel] [PATCH 06/10] block: Remove bdrv_new() from bdrv_file_open()

2014-01-31 Thread Max Reitz
On 29.01.2014 14:35, Kevin Wolf wrote: Am 26.01.2014 um 20:02 hat Max Reitz geschrieben: Change bdrv_file_open() to take a simple pointer to an already existing BDS instead of an indirect one. The BDS will be created in bdrv_open() if necessary. Signed-off-by: Max Reitz --- block.c | 29

Re: [Qemu-devel] [PATCH 01/10] block: Change BDS parameter of bdrv_open() to **

2014-01-31 Thread Max Reitz
On 29.01.2014 12:50, Kevin Wolf wrote: Am 26.01.2014 um 20:02 hat Max Reitz geschrieben: Make bdrv_open() take a pointer to a BDS pointer, similarly to bdrv_file_open(). If a pointer to a NULL pointer is given, bdrv_open() will create a new BDS with an empty name; if the BDS pointer is not NULL,

Re: [Qemu-devel] [RFC PATCH v2] Add option to switch off FDC

2014-01-31 Thread Eric Blake
On 01/31/2014 12:03 PM, Gabriel L. Somlo wrote: > Allow guests to omit the configuration of a floppy disk controller. > > Signed-off-by: Gabriel Somlo > --- > > New in this version: > > - "int have_fdc = 1;" instead of "int no_fdc = 0;" > > - use 8bit field for FDC0's _STA method > > >

[Qemu-devel] [V2 PATCH 9/9] target-ppc: Add Store Quadword Conditional

2014-01-31 Thread Tom Musta
This patch adds the Store Quadword Conditionl (stqcx.) instruction which is introduced in Power ISA 2.07. Signed-off-by: Tom Musta --- V2: Updated linux-user/main.c to use the newly added reserve_val2. linux-user/main.c | 18 +- target-ppc/translate.c | 21 +

[Qemu-devel] [V2 PATCH 7/9] target-ppc: Store Quadword

2014-01-31 Thread Tom Musta
This patch adds support for the Store Quadword instruction in user mode. Prior to Power ISA 2.07, stq was legal only in privileged mode. Support for Little Endian mode is also new in ISA 2.07. Signed-off-by: Tom Musta --- V2: Refactored user-mode and Little Endian checks per Alex Graf's review.

[Qemu-devel] [V2 PATCH 6/9] target-ppc: Load Quadword

2014-01-31 Thread Tom Musta
This patch adds the Book I (user space) Load Quadword (lq) instruction. This instruction was introduced into Book I in Power ISA V2.07. Previous versions of the architecture supported this as a privileged instruction. Previous versions of the architecture also did not support Little Endian mode.

[Qemu-devel] [V2 PATCH 8/9] target-ppc: Add Load Quadword and Reserve

2014-01-31 Thread Tom Musta
This patch adds the Load Quadword and Reserve (lqarx) instruction, which is new in Power ISA 2.07. Signed-off-by: Tom Musta --- V2: Additional changes for handling reserve_val2. target-ppc/cpu.h |1 + target-ppc/translate.c | 35 +++ 2 files changed,

[Qemu-devel] [V2 PATCH 2/9] target-ppc: Add Target Address SPR (TAR) to Power8

2014-01-31 Thread Tom Musta
This patch adds support for the Target Address Register (TAR) to the Power8 model. Because supported SPRs are typically identified in an init_proc_*() function and because the Power8 model is currently just using the init_proc_POWER7() function, a new init_proc_POWER8() function is added and plugg

[Qemu-devel] [V2 PATCH 3/9] target-ppc: Add bctar Instruction

2014-01-31 Thread Tom Musta
This patch adds the Branch Conditional to Address Register (bctar) instruction. Signed-off-by: Tom Musta --- target-ppc/translate.c | 11 ++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/target-ppc/translate.c b/target-ppc/translate.c index d9abcca..b89b4ba 100644 --

[Qemu-devel] [V2 PATCH 5/9] target-ppc: Add is_user_mode Utility Routine

2014-01-31 Thread Tom Musta
This patch adds a boolean function is_user_mode that can be re-used in translation code that is sensitive to the MSR[PR] (user-mode) state. Signed-off-by: Tom Musta --- target-ppc/translate.c | 14 ++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/target-ppc/transl

[Qemu-devel] [V2 PATCH 4/9] target-ppc: Add Flag for ISA 2.07 Load/Store Quadword Instructions

2014-01-31 Thread Tom Musta
This patch adds a flag to identify the load/store quadword instructions that are introduced with Power ISA 2.07. The flag is added to the Power8 model since P8 supports these instructions. Signed-off-by: Tom Musta --- target-ppc/cpu.h|4 +++- target-ppc/translate_init.c |3 +

[Qemu-devel] [V2 PATCH 0/9] target-ppc: Base ISA V2.07 for Power8

2014-01-31 Thread Tom Musta
This patch series adds the branch and integer instructions that were introduced in Power ISA 2.07. Specifically, - There is a new conditional Branch to Address Register (bctar) instruction. - The load/store quadword instructions are now supported in user mode (Book I). - Quadword atomic i

[Qemu-devel] [V2 PATCH 1/9] target-ppc: Add Flag for bctar

2014-01-31 Thread Tom Musta
This patch adds a flag for the bctar instruction. This instruction is being introduced via Power ISA 2.07. Also, the flag is added to the Power8 machine model since the P8 processor supports this instruction. Signed-off-by: Tom Musta --- target-ppc/cpu.h|6 -- target-ppc/tr

Re: [Qemu-devel] [libvirt] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Eduardo Habkost
On Fri, Jan 31, 2014 at 08:18:39PM +0100, Igor Mammedov wrote: > On Fri, 31 Jan 2014 11:56:18 -0700 > Eric Blake wrote: > > > On 01/31/2014 11:51 AM, Eduardo Habkost wrote: > > > > >> Allowing -device may be okay, since in the (very?) long term -device > > >> can be replaced by -object. But -ob

Re: [Qemu-devel] [libvirt] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Igor Mammedov
On Fri, 31 Jan 2014 11:56:18 -0700 Eric Blake wrote: > On 01/31/2014 11:51 AM, Eduardo Habkost wrote: > > >> Allowing -device may be okay, since in the (very?) long term -device > >> can be replaced by -object. But -object is definitive. > > > > OK, one additional reason to try device_add firs

Re: [Qemu-devel] [PATCH 2/2] Use g_new() & friends where that makes obvious sense

2014-01-31 Thread Richard Henderson
On 01/31/2014 11:10 AM, Eric Blake wrote: > >> > @@ -658,7 +658,7 @@ int qcow2_snapshot_list(BlockDriverState *bs, >> > QEMUSnapshotInfo **psn_tab) >> > return s->nb_snapshots; >> > } >> > >> > -sn_tab = g_malloc0(s->nb_snapshots * sizeof(QEMUSnapshotInfo)); >> > +sn_tab =

Re: [Qemu-devel] [PATCH v2 01/35] target-arm: Fix raw read and write functions on AArch64 registers

2014-01-31 Thread Rob Herring
On 31 January 2014 09:45, Peter Maydell wrote: > The raw read and write functions were using the ARM_CP_64BIT flag in > ri->type to determine whether to treat the register's state field as > uint32_t or uint64_t; however AArch64 register info structs don't use > that flag. Abstract out the "how bi

Re: [Qemu-devel] [libvirt] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Eduardo Habkost
On Fri, Jan 31, 2014 at 11:56:18AM -0700, Eric Blake wrote: > On 01/31/2014 11:51 AM, Eduardo Habkost wrote: > > >> Allowing -device may be okay, since in the (very?) long term -device > >> can be replaced by -object. But -object is definitive. > > > > OK, one additional reason to try device_add

[Qemu-devel] [RFC PATCH v2] Add option to switch off FDC

2014-01-31 Thread Gabriel L. Somlo
Allow guests to omit the configuration of a floppy disk controller. Signed-off-by: Gabriel Somlo --- New in this version: - "int have_fdc = 1;" instead of "int no_fdc = 0;" - use 8bit field for FDC0's _STA method On Thu, Jan 09, 2014 at 11:24:42AM +0100, Paolo Bonzini wrote: > Il 09/01/20

Re: [Qemu-devel] [libvirt] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Eric Blake
On 01/31/2014 11:51 AM, Eduardo Habkost wrote: >> Allowing -device may be okay, since in the (very?) long term -device >> can be replaced by -object. But -object is definitive. > > OK, one additional reason to try device_add first. > > But then we have one additional problem: > > * We want to

Re: [Qemu-devel] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Eduardo Habkost
On Fri, Jan 31, 2014 at 05:52:57PM +0100, Paolo Bonzini wrote: > Il 31/01/2014 17:42, Eduardo Habkost ha scritto: > >>> It looks like only -device would be able to create actual CPU models, > >>> but for -device to work we need as minimum this series and conversion > >>> of CPU features to properti

Re: [Qemu-devel] [PATCH v5 4/8] hw: arm_gic: Keep track of SGI sources

2014-01-31 Thread Peter Maydell
On 28 January 2014 20:32, Christoffer Dall wrote: > Right now the arm gic emulation doesn't keep track of the source of an > SGI (which apparently Linux guests don't use, or they're fine with > assuming CPU 0 always). > > Add the necessary matrix on the GICState structure and maintain the data > w

[Qemu-devel] [uq/master PATCH 7/7 v8] target-i386: CPU model subclasses

2014-01-31 Thread Eduardo Habkost
Register separate QOM classes for each x86 CPU model. This will allow management code to more easily probe what each CPU model provides, by simply creating objects using the appropriate class name, without having to restart QEMU. This also allows us to eliminate the qdev_prop_set_globals_for_type

Re: [Qemu-devel] [PATCH v2] qga: Don't require 'time' argument in guest-set-time command

2014-01-31 Thread Eric Blake
On 01/31/2014 03:29 AM, Michal Privoznik wrote: > As the description to the guest-set-time states, the command is > there to ease time synchronization after resume. If guest was > suspended for longer period of time, its system time can go off > so badly, that even NTP refuses to set it. That's why

Re: [Qemu-devel] [PATCH v5 3/8] arm_gic: Fix GIC pending behavior

2014-01-31 Thread Peter Maydell
On 28 January 2014 20:32, Christoffer Dall wrote: > The existing implementation of the pending behavior in gic_set_irq, > gic_acknowledge_irq, gic_complete_irq, and the distributor pending > set/clear registers does not follow the semantics of the GICv2.0 specs, > but may implement the 11MPCore su

[Qemu-devel] [PATCH v7 01/13] Convert -mem-path to QemuOpts and add prealloc and share properties

2014-01-31 Thread Antonios Motakis
Extend -mem-path with additional properties: - prealloc=on|off - default off, same as -mem-prealloc - share=on|off - default off, memory is mmapped with MAP_SHARED flag Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- exec.c | 30 +++

[Qemu-devel] [PATCH v7 02/13] Add chardev API qemu_chr_fe_read_all

2014-01-31 Thread Antonios Motakis
This function will attempt to read data from the chardev trying to fill the buffer up to the given length. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- include/sysemu/char.h | 14 +++ qemu-char.c | 65 +++

[Qemu-devel] [PATCH v7 08/13] Add vhost_ops to the vhost_dev struct and replace all relevant ioctls

2014-01-31 Thread Antonios Motakis
Decouple vhost from the Linux kernel by introducing vhost_ops. The intention is to provide different backends - 'kernel' backend based on the ioctl interface, and 'user' backend based on a unix domain socket and shared memory. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev ---

[Qemu-devel] [PATCH v7 06/13] Refactor virtio-net to use a generic get_vhost_net

2014-01-31 Thread Antonios Motakis
This decouples virtio-net from the TAP netdev backend and allows support for other backends to be implemented. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- hw/net/vhost_net.c | 30 +++--- hw/net/virtio-net.c | 39 ++

[Qemu-devel] [PATCH v7 12/13] Add the vhost-user netdev backend to command line

2014-01-31 Thread Antonios Motakis
The supplied chardev id will be inspected for supported options. Only a socket backend, with a set path (i.e. a unix socket) and optionally the server parameter set, will be allowed. Other options (nowait, telnet) will make the chardev unusable and the netdev will not be initialised. Signed-off-by

[Qemu-devel] [PATCH v7 00/13] Vhost and vhost-net support for userspace based backends

2014-01-31 Thread Antonios Motakis
In this patch series we would like to introduce our approach for putting a virtio-net backend in an external userspace process. Our eventual target is to run the network backend in the Snabbswitch ethernet switch, while receiving traffic from a guest inside QEMU/KVM which runs an unmodified virtio-

[Qemu-devel] [PATCH v7 13/13] Add vhost-user protocol documentation

2014-01-31 Thread Antonios Motakis
This document describes the basic message format used by vhost-user for communication over a unix domain socket. The protocol is based on the existing ioctl interface used for the kernel version of vhost. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- docs/specs/vhost-user.

[Qemu-devel] [PATCH v7 05/13] vhost_net should call the poll callback only when it is set

2014-01-31 Thread Antonios Motakis
The poll callback needs to be called when bringing up or down the vhost_net instance. As it is not mandatory for an NetClient to implement it, invoke it only when it is set. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- hw/net/vhost_net.c | 13 ++--- 1 file changed

[Qemu-devel] [PATCH v7 03/13] Add chardev API qemu_chr_fe_set_msgfds

2014-01-31 Thread Antonios Motakis
This will set an array of file descriptors to the internal structures. The next time a message is send the array will be send as ancillary data. This feature works on unix domain socket backend only. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- include/sysemu/char.h | 14

[Qemu-devel] [PATCH v7 09/13] Add vhost-backend and VhostBackendType

2014-01-31 Thread Antonios Motakis
Use vhost_set_backend_type to initialise a proper vhost_ops structure. In vhost_net_init and vhost_net_start_one call conditionally TAP related initialisation depending on the vhost backend type. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- hw/net/vhost_net.c

[Qemu-devel] [PATCH v7 07/13] vhost_net_init will use VhostNetOptions to get all its arguments

2014-01-31 Thread Antonios Motakis
vhost_dev_init will replace devfd and devpath with a single opaque argument. This is initialised with a file descriptor. When TAP is used (through vhost_net), open /dev/vhost-net and pass the fd as an opaque parameter in VhostNetOptions. The same applies to vhost-scsi - open /dev/vhost-scsi and pas

[Qemu-devel] [PATCH v7 04/13] Add G_IO_HUP handler for socket chardev

2014-01-31 Thread Antonios Motakis
Close the chardev on receiving this event. Signed-off-by: Antonios Motakis Signed-off-by: Nikolay Nikolaev --- qemu-char.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/qemu-char.c b/qemu-char.c index c2e599e..1c34b2b 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -2643,6

[Qemu-devel] [PATCH v7 11/13] Add new vhost-user netdev backend

2014-01-31 Thread Antonios Motakis
Add a new QEMU netdev backend that is intended to invoke vhost_net with the vhost-user backend. At runtime the netdev will detect if the vhost backend is up or down. Upon disconnection it will set link_down accordingly and notify virtio-net. The virtio-net interface goes down. Signed-off-by: Anto

[Qemu-devel] [PATCH v7 10/13] Add vhost-user as a vhost backend.

2014-01-31 Thread Antonios Motakis
The initialization takes a chardev backed by a unix domain socket. It should implement qemu_fe_set_msgfds in order to be able to pass file descriptors to the remote process. Each ioctl request of vhost-kernel has a vhost-user message equivalent, which is sent over the control socket. The general

Re: [Qemu-devel] [PATCH 1/2] qga: Fix memory allocation pasto

2014-01-31 Thread Eric Blake
On 01/31/2014 08:53 AM, Markus Armbruster wrote: > qmp_guest_file_seek() allocates memory for a GuestFileRead object > instead of the GuestFileSeek object it actually uses. Harmless, > because the GuestFileRead is slightly larger. > > Signed-off-by: Markus Armbruster > --- > qga/commands-posix.

Re: [Qemu-devel] [PATCHv8 0/5] block: add native support for NFS

2014-01-31 Thread Peter Lieven
Am 31.01.2014 um 17:07 schrieb Stefan Hajnoczi : > On Fri, Jan 31, 2014 at 12:38:48PM +0100, Peter Lieven wrote: >> This adds v6 of the NFS protocol driver + qemu-iotest adjustments. >> >> v7->v8: >> - bump libnfs requirement to 1.9.2 >> - renamed NFSRPC->status to NFSRPC->ret [Benoit] >> - avoi

[Qemu-devel] [PATCH v2 34/35] target-arm: Implement AArch64 dummy breakpoint and watchpoint registers

2014-01-31 Thread Peter Maydell
In AArch64 the breakpoint and watchpoint registers are mandatory, so the kernel always accesses them on bootup. Implement dummy versions, which read as written but have no actual effect. Signed-off-by: Peter Maydell --- target-arm/cpu.h| 4 target-arm/helper.c | 32

[Qemu-devel] [PATCH 06/12] trace: [tcg] Declare TCG tracing helper routines

2014-01-31 Thread Lluís Vilanova
Generate header "trace/generated-helpers.h" with the necessary TCG helper declarations for tracing events in guest code: * gen_helper_trace_${event}_tcg Routine to transform mixed native and TCG argument types to TCG types and call TCG helper 'gen_helper_trace_${event}_tcg_proxy'. * helper_t

Re: [Qemu-devel] [uq/master PATCH 7/7] target-i386: CPU model subclasses

2014-01-31 Thread Eduardo Habkost
On Thu, Jan 30, 2014 at 05:48:59PM -0200, Eduardo Habkost wrote: > Register separate QOM classes for each x86 CPU model. > > This will allow management code to more easily probe what each CPU model > provides, by simply creating objects using the appropriate class name, > without having to restart

Re: [Qemu-devel] [PATCH v2] qmp: expose list of supported character device backends

2014-01-31 Thread Eric Blake
On 01/31/2014 09:49 AM, Martin Kletzander wrote: > Introduce 'query-chardev-backends' QMP command which lists all > supported character device backends. > > Signed-off-by: Martin Kletzander > --- > v2: > - Version changed from "1.8.0" to "2.0" > > qapi-schema.json | 22 ++ >

Re: [Qemu-devel] How to mount, install and/or otherwise use an ARM Zer o Client image wi th Qemu in Windows

2014-01-31 Thread Peter Maydell
On 29 January 2014 19:30, xan...@juno.com wrote: > Hi Peter and thanks for the quick response, it's very much appreciated! > > Sorry I forgot to include more details. To make sure I was giving you the > best data possible I just asked our Engineers exactly what they have and are > trying to emula

Re: [Qemu-devel] [PATCH v3 0/1] Detect arch for dump compressed header.

2014-01-31 Thread Laszlo Ersek
On 01/31/14 16:04, Ekaterina Tumanova wrote: > True! Fixed. Tested. > > Can you please put it into push-queue? > > Thanks, > Kate. > > Ekaterina Tumanova (1): > Define the architecture for compressed dump format. > > dump.c | 7 +-- > target-i386/cpu.h | 2 ++ > target-s390x

[Qemu-devel] [PATCH 04/12] trace: [tracetool, tcg] Provide TCG-related type transformation rules

2014-01-31 Thread Lluís Vilanova
Signed-off-by: Lluís Vilanova --- scripts/tracetool/transform.py | 157 1 file changed, 157 insertions(+) create mode 100644 scripts/tracetool/transform.py diff --git a/scripts/tracetool/transform.py b/scripts/tracetool/transform.py new file mode 100644

Re: [Qemu-devel] [PATCH v2 01/35] target-arm: Fix raw read and write functions on AArch64 registers

2014-01-31 Thread Peter Maydell
On 31 January 2014 15:56, Rob Herring wrote: > On 31 January 2014 09:45, Peter Maydell wrote: >> The raw read and write functions were using the ARM_CP_64BIT flag in >> ri->type to determine whether to treat the register's state field as >> uint32_t or uint64_t; however AArch64 register info stru

Re: [Qemu-devel] [PATCH 2/2] Use g_new() & friends where that makes obvious sense

2014-01-31 Thread Eric Blake
On 01/31/2014 08:53 AM, Markus Armbruster wrote: > g_new(T, n) is safer than g_malloc(sizeof(T) * n) for two reasons. > One, it catches multiplication overflowing size_t. Two, it returns > T * rather than void *, which lets the compiler catch more type > errors. > > Patch created with the followi

[Qemu-devel] [PATCH v2 08/35] target-arm: A64: Implement store-exclusive for system mode

2014-01-31 Thread Peter Maydell
System mode store-exclusive use a different code path to usermode ones; implement this missing code, in a similar way to the 32 bit version. Signed-off-by: Peter Maydell --- target-arm/translate-a64.c | 68 ++ 1 file changed, 62 insertions(+), 6 deleti

[Qemu-devel] [PATCH v2 17/35] target-arm: Remove failure status return from read/write_raw_cp_reg

2014-01-31 Thread Peter Maydell
The read_raw_cp_reg and write_raw_cp_reg functions can now never fail (in fact they should never have failed previously unless there was a bug in a reginfo that meant no raw accessor was provided for a might-trap register). This allows us to clean up their prototypes so the write function returns v

Re: [Qemu-devel] [PATCHv8 0/5] block: add native support for NFS

2014-01-31 Thread Stefan Hajnoczi
On Fri, Jan 31, 2014 at 12:38:48PM +0100, Peter Lieven wrote: > This adds v6 of the NFS protocol driver + qemu-iotest adjustments. > > v7->v8: > - bump libnfs requirement to 1.9.2 > - renamed NFSRPC->status to NFSRPC->ret [Benoit] > - avoid double invocation of nfs_client_close in nfs_file_crea

[Qemu-devel] [PATCH 10/12] trace: [trivial] Include event definitions in "trace.h"

2014-01-31 Thread Lluís Vilanova
Otherwise the user has to explicitly include an auto-generated header. Signed-off-by: Lluís Vilanova --- include/trace.h |1 + 1 file changed, 1 insertion(+) diff --git a/include/trace.h b/include/trace.h index c15f498..44a1f1f 100644 --- a/include/trace.h +++ b/include/trace.h @@ -2,5 +2,6

[Qemu-devel] [PATCH v2 19/35] target-arm: A64: Make cache ID registers visible to AArch64

2014-01-31 Thread Peter Maydell
Make the cache ID system registers (CLIDR, CCSELR, CCSIDR, CTR) visible to AArch64. These are mostly simple 64-bit extensions of the existing 32 bit system registers and so can share reginfo definitions. CTR needs to have a split definition, but we can clean up the temporary user-mode implementatio

Re: [Qemu-devel] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Paolo Bonzini
Il 31/01/2014 17:42, Eduardo Habkost ha scritto: > It looks like only -device would be able to create actual CPU models, > but for -device to work we need as minimum this series and conversion > of CPU features to properties in tree. Then I guess we can override > cannot_instantiate_with_device_a

[Qemu-devel] [PATCH v2] qmp: expose list of supported character device backends

2014-01-31 Thread Martin Kletzander
Introduce 'query-chardev-backends' QMP command which lists all supported character device backends. Signed-off-by: Martin Kletzander --- v2: - Version changed from "1.8.0" to "2.0" qapi-schema.json | 22 ++ qemu-char.c | 19 +++ qmp-commands.hx | 41 ++

Re: [Qemu-devel] [PATCH v2 01/35] target-arm: Fix raw read and write functions on AArch64 registers

2014-01-31 Thread Peter Maydell
On 31 January 2014 16:06, Peter Maydell wrote: > On 31 January 2014 15:56, Rob Herring wrote: >> On 31 January 2014 09:45, Peter Maydell wrote: >>> +/* Return true if this reginfo struct's field in the cpu state struct >>> + * is 64 bits wide. >>> + */ >>> +static inline bool cpreg_field_is_64bi

[Qemu-devel] [PATCH v2 31/35] target-arm: Implement AArch64 MPIDR

2014-01-31 Thread Peter Maydell
Implement the AArch64 MPIDR system register. Signed-off-by: Peter Maydell Reviewed-by: Peter Crosthwaite --- target-arm/helper.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/target-arm/helper.c b/target-arm/helper.c index a23b40d..d943963 100644 --- a/target-arm/hel

Re: [Qemu-devel] [uq/master PATCH 0/7] x86 CPU subclasses, take 7

2014-01-31 Thread Eduardo Habkost
On Fri, Jan 31, 2014 at 05:06:21PM +0100, Igor Mammedov wrote: > On Fri, 31 Jan 2014 13:17:53 -0200 > Eduardo Habkost wrote: > > > On Fri, Jan 31, 2014 at 03:50:23PM +0100, Paolo Bonzini wrote: > > > Il 31/01/2014 15:48, Igor Mammedov ha scritto: > > > >that's abusing of object-add interface and

[Qemu-devel] [PATCH 00/12] trace: [tcg] Allow tracing guest events in TCG-generated code

2014-01-31 Thread Lluís Vilanova
Adds the base ability to specify which events in the "trace-events" file may be used to trace guest activity in the TCG code (using the "tcg" event propery). Such events generate an extra set of tracing functions that can be called during TCG code generation and will automatically redirect a call

[Qemu-devel] [PATCH v2 30/35] target-arm: Implement AArch64 TTBR*

2014-01-31 Thread Peter Maydell
Implement the AArch64 TTBR* registers. For v7 these were already 64 bits to handle LPAE, but implemented as two separate uint32_t fields. Combine them into a single uint64_t which can be used for all purposes. Since this requires touching every use, take the opportunity to rename the field to the a

[Qemu-devel] [PATCH v2 04/35] target-arm: Restrict check_ap() use of S and R bits to v6 and earlier

2014-01-31 Thread Peter Maydell
The SCTLR bits S and R (8 and 9) only exist in ARMv6 and earlier. In ARMv7 these bits RAZ, and in ARMv8 they are reassigned. Guard the use of them in check_ap() so that we don't get incorrect results for ARMv8 CPUs. Signed-off-by: Peter Maydell Reviewed-by: Peter Crosthwaite --- target-arm/help

Re: [Qemu-devel] [PATCH 0/2] Use g_new() & friends where that makes obvious sense

2014-01-31 Thread Peter Maydell
On 31 January 2014 15:53, Markus Armbruster wrote: > PATCH 1/2 fixes a bug found by compiling the original PATCH 2/2. > Evidence for my claim that PATCH 2/2 lets the compiler catch more type > errors :) > > Markus Armbruster (2): > qga: Fix memory allocation pasto > Use g_new() & friends where

[Qemu-devel] QEMU & KVM at devconf.cz 7-9 February in Brno, Czech Republic

2014-01-31 Thread Stefan Hajnoczi
Several QEMU and KVM community members will be at devconf.cz 7-9 February in Brno, Czech Republic. See the schedule for details on KVM and virtualization talks: http://devconf.cz/schedule Thin provisioning in the KVM virtualization stack - how we got there - Paolo Bonzini KVM and CPU feature ena

[Qemu-devel] [PATCH 11/12] trace: [tcg] Include TCG-tracing header on all targets

2014-01-31 Thread Lluís Vilanova
Signed-off-by: Lluís Vilanova --- target-alpha/translate.c |3 +++ target-arm/translate.c|3 +++ target-cris/translate.c |3 +++ target-i386/translate.c |3 +++ target-lm32/translate.c |3 +++ target-m68k/translate.c |3 +++ target-micr

[Qemu-devel] [PATCH 07/12] trace: [tcg] Define TCG tracing helper routines

2014-01-31 Thread Lluís Vilanova
Generate file "trace/generated-helpers.c" with the necessary TCG helper routines for tracing events in guest code: * helper_trace_${event}_tcg_proxy TCG helper implementation to cast TCG-compatible argument types to native types and call tracing routine 'trace_${event}'. Signed-off-by: Lluí

[Qemu-devel] [PATCH 03/12] trace: [tracetool] Add method 'Event.api' to get the name of public routines

2014-01-31 Thread Lluís Vilanova
This ensures proper naming across tracing backends, even when someone overrides the value without backends knowing it. Signed-off-by: Lluís Vilanova --- scripts/tracetool/__init__.py | 10 +- scripts/tracetool/backend/dtrace.py |6 +++--- scripts/tracetool/backend/simple.py |

[Qemu-devel] [PATCH 02/12] trace: [tracetool, tcg] Allow TCG types in trace event declarations

2014-01-31 Thread Lluís Vilanova
When found, TCG types are translated into the host native types when declaring and defining the tracing routines not used during TCG code translation (e.g., "trace.h"). Signed-off-by: Lluís Vilanova --- scripts/tracetool/__init__.py |8 +++- 1 file changed, 7 insertions(+), 1 deletion(-

[Qemu-devel] [PATCH 01/12] trace: [tcg] Add documentation

2014-01-31 Thread Lluís Vilanova
Signed-off-by: Lluís Vilanova --- docs/tracing.txt | 36 1 file changed, 36 insertions(+) diff --git a/docs/tracing.txt b/docs/tracing.txt index bfc261b..9bf7073 100644 --- a/docs/tracing.txt +++ b/docs/tracing.txt @@ -271,3 +271,39 @@ guard such computatio

  1   2   3   >