Re: [Qemu-devel] [network performance question] only ~2Gbpsthroughputbetweentwo linux guests which are running on the same host vianetperf-tTCP_STREAM -m 1400, but xen can ac

2014-06-06 Thread Zhang Haoyu
After updating the qemu from 1.4 to 2.0, the inter-vm throughput can achieve ~5Gbps via netper -t TCP_STREAM -m 1400, the performance gap(~2Gbps) between kvm and xen still exist. Thanks, Zhang Haoyu -- Zhang Haoyu 2014-06-07 -Original Message--

[Qemu-devel] [PATCH] qdev: Move global validation to a single function

2014-06-06 Thread Eduardo Habkost
This simplifies the global validation code so all its logic is contained in a single function, and fixes the following: $ qemu-system-x86_64 -global container.xxx=y hw/core/qdev-properties-system.c:450:qdev_add_one_global: Object 0x7f8d72a03d70 is not an instance of type device Aborted (cor

[Qemu-devel] [PATCH] qdev: Don't abort() in case globals can't be set

2014-06-06 Thread Eduardo Habkost
It would be much better if we didn't terminate QEMU inside device_post_init(), but at least exiting cleanly is better than aborting and dumping core. Signed-off-by: Eduardo Habkost --- hw/core/qdev.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hw/core/qdev.c b/hw/c

Re: [Qemu-devel] [network performance question] only ~2Gbpsthroughputbetweentwo linux guests which are running on the same host vianetperf-tTCP_STREAM -m 1400, but xen can ac

2014-06-06 Thread Zhang Haoyu
> Doesn't that answer your original question about performance gap! Sorry, do you mean it's the offloadings cause the performance gap? But even OFF the checksum-offload, tso, gro, .etc, the performance gap still exist, if I understand correctly, kvm should have better performance than xen from the

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Eduardo Habkost
On Sat, Jun 07, 2014 at 12:45:26AM +0100, Peter Maydell wrote: > On 7 June 2014 00:22, Igor Mammedov wrote: > > Eduardo Habkost wrote: > >> On Fri, Jun 06, 2014 at 11:38:58PM +0200, Igor Mammedov wrote: > >> > Eduardo Habkost wrote: > >> > > $ ./install/bin/qemu-system-x86_64 -global cpu.fooba

[Qemu-devel] [PATCH 1/2] nbd: Handle fixed new-style clients.

2014-06-06 Thread Hani Benhabiles
When this flag is set, the server tells the client that it can send another option if the server received a request with an option that it doesn't understand instead of directly closing the connection. Also add link to the most up-to-date documentation. Signed-off-by: Hani Benhabiles --- includ

[Qemu-devel] [PATCH 0/2] nbd: Add exports listing support

2014-06-06 Thread Hani Benhabiles
Compared to v2: * 1/2: Handle options in loop. Handle NBD_OPT_ABORT. Add link to documentation. Improve commit message. * 2/2: Fix return value in NBD_OPT_LIST case. Rename nbd_send_list() function to nbd_handle_list(). * Remove patch 3/3 from v2. Applied separately by Paolo. Hani Benhabiles (

[Qemu-devel] [PATCH 2/2] nbd: Handle NBD_OPT_LIST option.

2014-06-06 Thread Hani Benhabiles
Signed-off-by: Hani Benhabiles --- include/block/nbd.h | 2 ++ nbd.c | 61 + 2 files changed, 63 insertions(+) diff --git a/include/block/nbd.h b/include/block/nbd.h index 561b70c..fd7e057 100644 --- a/include/block/nbd.h +++ b/i

Re: [Qemu-devel] [PATCH] KVM: Fix GSI number space limit

2014-06-06 Thread Alexander Graf
On 06.06.14 18:31, Paolo Bonzini wrote: Il 06/06/2014 14:46, Alexander Graf ha scritto: KVM tells us the number of GSIs it can handle inside the kernel. That value is basically KVM_MAX_IRQ_ROUTES. However when we try to set the GSI mapping table, it checks for r = -EINVAL; if (routin

Re: [Qemu-devel] [PATCH memory v4 00/10] Memory Region QOMification

2014-06-06 Thread Peter Crosthwaite
On Sat, Jun 7, 2014 at 12:52 AM, Paolo Bonzini wrote: > Il 06/06/2014 15:36, Peter Crosthwaite ha scritto: > >>> However, I'd rather have the concept bake for a bit by starting with >>> read-only properties. >> >> >> The just a matter of pulling our the setters? > > > Yes. You can leave in all th

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Peter Maydell
On 7 June 2014 00:22, Igor Mammedov wrote: > Eduardo Habkost wrote: >> On Fri, Jun 06, 2014 at 11:38:58PM +0200, Igor Mammedov wrote: >> > Eduardo Habkost wrote: >> > > $ ./install/bin/qemu-system-x86_64 -global cpu.foobar=5 >> > > qemu-system-x86_64: Property '.foobar' not found >> > > Ab

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Igor Mammedov
On Fri, 6 Jun 2014 19:21:36 -0300 Eduardo Habkost wrote: > On Fri, Jun 06, 2014 at 11:38:58PM +0200, Igor Mammedov wrote: > > On Fri, 6 Jun 2014 17:14:29 -0300 > > Eduardo Habkost wrote: > > > > > This avoids QEMU from aborting on cases like this: > > > > > > $ ./install/bin/qemu-system-x86_

Re: [Qemu-devel] [PATCH v8 2/4] vfio: Add vfio_container_ioctl()

2014-06-06 Thread Alex Williamson
On Sat, 2014-06-07 at 08:50 +1000, Alexey Kardashevskiy wrote: > On 06/07/2014 03:35 AM, Alex Williamson wrote: > > On Sat, 2014-06-07 at 02:54 +1000, Alexey Kardashevskiy wrote: > >> On 06/07/2014 02:48 AM, Alex Williamson wrote: > >>> On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote:

Re: [Qemu-devel] [PATCH v8 2/4] vfio: Add vfio_container_ioctl()

2014-06-06 Thread Alexey Kardashevskiy
On 06/07/2014 03:35 AM, Alex Williamson wrote: > On Sat, 2014-06-07 at 02:54 +1000, Alexey Kardashevskiy wrote: >> On 06/07/2014 02:48 AM, Alex Williamson wrote: >>> On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: While most operations with VFIO IOMMU driver are generic and used

Re: [Qemu-devel] [PATCH v8 4/4] vfio: Enable for SPAPR

2014-06-06 Thread Alexey Kardashevskiy
On 06/07/2014 02:57 AM, Alex Williamson wrote: > On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: >> This turns the sPAPR support on and enables VFIO container use >> in the kernel. >> >> This extends vfio_connect_container to support VFIO_SPAPR_TCE_IOMMU type >> in the host kernel. >

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Eduardo Habkost
On Fri, Jun 06, 2014 at 11:38:58PM +0200, Igor Mammedov wrote: > On Fri, 6 Jun 2014 17:14:29 -0300 > Eduardo Habkost wrote: > > > This avoids QEMU from aborting on cases like this: > > > > $ ./install/bin/qemu-system-x86_64 -global cpu.foobar=5 > > qemu-system-x86_64: Property '.foobar' not

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Igor Mammedov
On Fri, 6 Jun 2014 17:14:29 -0300 Eduardo Habkost wrote: > This avoids QEMU from aborting on cases like this: > > $ ./install/bin/qemu-system-x86_64 -global cpu.foobar=5 > qemu-system-x86_64: Property '.foobar' not found > Aborted (core dumped) That is expected behavior. > > The code set

Re: [Qemu-devel] [PATCH 2/1] libcacard: Clean up dead stores before g_free()

2014-06-06 Thread Eric Blake
On 06/06/2014 01:30 PM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > libcacard/vcard.c | 4 > libcacard/vreader.c | 2 -- > 2 files changed, 6 deletions(-) Reviewed-by: Eric Blake -- Eric Blake eblake redhat com+1-919-301-3266 Libvirt virtualization library

Re: [Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Don Slutz
On 06/06/14 16:14, Eduardo Habkost wrote: This avoids QEMU from aborting on cases like this: $ ./install/bin/qemu-system-x86_64 -global cpu.foobar=5 qemu-system-x86_64: Property '.foobar' not found Aborted (core dumped) The code sets dev->not_used if the property is not found as an eff

[Qemu-devel] [PATCH] qdev: Skip non-existing properties when setting globals

2014-06-06 Thread Eduardo Habkost
This avoids QEMU from aborting on cases like this: $ ./install/bin/qemu-system-x86_64 -global cpu.foobar=5 qemu-system-x86_64: Property '.foobar' not found Aborted (core dumped) The code sets dev->not_used if the property is not found as an effort to to allow errors to be reported even if t

[Qemu-devel] [PATCH 2/1] libcacard: Clean up dead stores before g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- libcacard/vcard.c | 4 libcacard/vreader.c | 2 -- 2 files changed, 6 deletions(-) diff --git a/libcacard/vcard.c b/libcacard/vcard.c index bf342aa..87ad516 100644 --- a/libcacard/vcard.c +++ b/libcacard/vcard.c @@ -117,10 +117,8 @@ vcard_delete_applet

Re: [Qemu-devel] Should not abort on -global

2014-06-06 Thread Eduardo Habkost
On Fri, Jun 06, 2014 at 10:01:34AM +0200, Paolo Bonzini wrote: > Il 06/06/2014 09:09, Markus Armbruster ha scritto: > >Looks like this regressed in Eduardo's commit 99a0b03 qdev: Set globals > >in instance_post_init function. > > > >Before, we exited cleanly on this error, in device_initfn(): > > >

Re: [Qemu-devel] [RFC 0/2] GET_EMULATED_CPUID support with "allow-emulation" option

2014-06-06 Thread Eduardo Habkost
On Fri, Jun 06, 2014 at 01:16:00PM +0200, Alexander Graf wrote: > > On 06.06.14 04:37, Eduardo Habkost wrote: > >On Fri, Jun 06, 2014 at 03:21:04AM +0200, Borislav Petkov wrote: > >>On Fri, Jun 06, 2014 at 12:24:26AM +0200, Alexander Graf wrote: > >>>But can we drop the EMULATED name somehow? Can

Re: [Qemu-devel] [PATCH v2 RESEND] vl.c: Unify MAX_CPUMASK_BITS and machine->max_cpus checks

2014-06-06 Thread Eduardo Habkost
On Mon, Jun 02, 2014 at 12:51:53PM -0300, Eduardo Habkost wrote: [...] > > -smp -1 > > assert() is triggered, that's a bug. Thanks for finding it. > > (And that was the whole point of adding the assertions: to detect bugs.) This is fixed by: [PATCH] vl.c: Check -smp option ranges before settin

Re: [Qemu-devel] [PATCH] vl.c: Check -smp option ranges before setting int globals

2014-06-06 Thread Eduardo Habkost
On Fri, Jun 06, 2014 at 08:06:52AM +0200, Markus Armbruster wrote: > Eduardo Habkost writes: > > > When parsing the -smp option, check if the values (that can be anywhere > > in the [0, UINT64_MAX] range) are in the int range before setting the > > int globals smp_cpus, max_cpus, smp_cores, smp_t

Re: [Qemu-devel] [PATCH v3.1 25/31] hostmem: add properties for NUMA memory policy

2014-06-06 Thread Eduardo Habkost
On Fri, Jun 06, 2014 at 11:37:26AM +0800, Hu Tao wrote: > On Mon, May 19, 2014 at 08:34:54PM -0300, Eduardo Habkost wrote: > > On Tue, May 06, 2014 at 05:27:46PM +0800, Hu Tao wrote: > > [...] > > > @@ -203,6 +296,20 @@ host_memory_backend_memory_init(UserCreatable *uc, > > > Error **errp) > > >

[Qemu-devel] [PATCH v5 0/3] Add max-ram-below-4g (was Add pci_hole_min_size machine option)

2014-06-06 Thread Don Slutz
Changes v4 to v5: Re-work based on: https://github.com/imammedo/qemu/commits/memory-hotplug-v11 And so it now depends on this patch set. Stefano Stabellini: #3 "xen-hvm: Pass is_default to xen_hvm_init" Acked-by Minor change of pmc to pcms. Changes v3 to v4: Split out

[Qemu-devel] [PATCH v5 1/3] xen-hvm: Fix xen_hvm_init() to adjust pc memory layout

2014-06-06 Thread Don Slutz
This is just below_4g_mem_size and above_4g_mem_size which is used later in QEMU. Acked-by: Stefano Stabellini Signed-off-by: Don Slutz --- v5: No change v4: Switch Acked-by & Signed-off-by rebase on master v3: Add Acked-by: Stefano Stabellini v2: No change hw/i386/pc_pii

[Qemu-devel] [PATCH v5 2/3] pc & q35: Add new machine opt max-ram-below-4g

2014-06-06 Thread Don Slutz
This is a pc & q35 only machine opt. One use is to allow for more ram in a 32bit guest for example: -machine pc,max-ram-below-4g=3.75G If you add enough PCI devices then all mmio for them will not fit below 4G which may not be the layout the user wanted. This allows you to increase the below 4G

[Qemu-devel] [PATCH v5 3/3] xen-hvm: Pass is_default to xen_hvm_init

2014-06-06 Thread Don Slutz
This is the xen part of "pc & q35: Add new machine opt max-ram-below-4g" Acked-by: Stefano Stabellini Signed-off-by: Don Slutz --- v5: Added Acked-by: Stefano Stabellini Minor change of pmc to pcms. hw/i386/pc_piix.c| 1 + hw/i386/pc_q35.c | 1 + include/hw/xen/xen.h | 2 +- xe

[Qemu-devel] [PULL 11/42] nbd: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_aio_set_fd_handler() calls to aio_set_fd_handler(). The .bdrv_detach/attach_aio_context() interfaces also need to be implemented to move the socket fd handler from the old to the new AioContext. Acked-by: Paolo Bonzini Signe

[Qemu-devel] [PULL 17/42] block/raw-win32: create one QEMUWin32AIOState per BDRVRawState

2014-06-06 Thread Stefan Hajnoczi
Each QEMUWin32AIOState event notifier is associated with an AioContext. Since BlockDriverState instances can use different AioContexts we cannot continue to use a global QEMUWin32AIOState. Let each BDRVRawState have its own QEMUWin32AIOState and free it when BDRVRawState is closed. Reviewed-by: P

[Qemu-devel] [PULL 20/42] sheepdog: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_aio_set_fd_handler() to aio_set_fd_handler() and qemu_aio_wait() to aio_poll(). The .bdrv_detach/attach_aio_context() interfaces also need to be implemented to move the socket fd handler from the old to the new AioContext. Cc

[Qemu-devel] [PULL 38/42] sheepdog: reload only header in a case of live snapshot

2014-06-06 Thread Stefan Hajnoczi
From: Hitoshi Mitake sheepdog driver doesn't need to read data_vdi_id[] when a live snapshot is created. Cc: Kevin Wolf Cc: Stefan Hajnoczi Cc: Liu Yuan Cc: MORITA Kazutaka Signed-off-by: Hitoshi Mitake Signed-off-by: Stefan Hajnoczi --- block/sheepdog.c | 9 ++--- 1 file changed, 6 i

[Qemu-devel] [PULL 37/42] sheepdog: fix vdi object update after live snapshot

2014-06-06 Thread Stefan Hajnoczi
From: Hitoshi Mitake sheepdog driver should decide a write request is COW or not based on inode object which is active when the write request is issued. Example of wrong inode update path in the previous driver: 1. drier issues an ordinal write request to an existing object 2. user creates a sna

Re: [Qemu-devel] [PATCH v8 2/4] vfio: Add vfio_container_ioctl()

2014-06-06 Thread Alex Williamson
On Sat, 2014-06-07 at 02:54 +1000, Alexey Kardashevskiy wrote: > On 06/07/2014 02:48 AM, Alex Williamson wrote: > > On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: > >> While most operations with VFIO IOMMU driver are generic and used inside > >> vfio.c, there are still some operatio

[Qemu-devel] [PULL 27/42] block: Move declaration of bdrv_get_aio_context to block.h

2014-06-06 Thread Stefan Hajnoczi
From: Fam Zheng block_int.h is for block layer and block drivers, other code shouldn't include it. But similar to bdrv_set_aio_context, bdrv_get_aio_context should also be accessible from outside of block layer. Move it. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- include/blo

[Qemu-devel] [PULL 06/42] blkdebug: use BlockDriverState's AioContext

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_bh_new() to aio_bh_new() so we use the BlockDriverState's AioContext. The .bdrv_detach_aio_context() and .bdrv_attach_aio_context() interfaces are not needed since no fd handlers, timers, or BHs stay registered when requests h

Re: [Qemu-devel] [PATCH v4.1 5/33 FIXED] add memdev backend infrastructure

2014-06-06 Thread Don Slutz
Tested that "make check" no longer fails with this version. -Don Slutz On 06/06/14 11:54, Igor Mammedov wrote: Provides framework for splitting host RAM allocation/ policies into a separate backend that could be used by devices. Initially only legacy RAM backend is provided, which uses memo

Re: [Qemu-devel] [PATCH] libcacard: Drop superfluous conditionals around g_free()

2014-06-06 Thread Paolo Bonzini
Il 06/06/2014 18:59, Markus Armbruster ha scritto: Paolo Bonzini writes: Il 06/06/2014 18:32, Markus Armbruster ha scritto: Signed-off-by: Markus Armbruster --- libcacard/cac.c| 14 -- libcacard/card_7816.c | 12 +++- libcacard/vcard.c | 10 +++-

Re: [Qemu-devel] [Qemu-ppc] qemu does not support PAPR

2014-06-06 Thread sonia verma
Thanks stuart for the help you have provided me. The libguestfs is directly related with qemu. Could you help me regarding qemu with latest version having freescale patches. I think that will solve my problem. Thanks

[Qemu-devel] [PATCH v2 1/2] vnc: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- ui/vnc-tls.c | 6 ++ ui/vnc.c | 12 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/ui/vnc-tls.c b/ui/vnc-tls.c index 50275de..6392326 100644 --- a/ui/vnc-tls.c +++ b/ui/vnc-tls.c @@ -443,10 +443,8 @@ static int vnc_set_x5

Re: [Qemu-devel] [PATCH] migration: Increase default max_downtime from 30ms to 300ms

2014-06-06 Thread Alexey Kardashevskiy
On 06/06/2014 10:50 PM, Amit Shah wrote: > On (Thu) 27 Mar 2014 [14:57:26], Alexey Kardashevskiy wrote: >> The existing timeout is 30ms which on 100MB/s (1Gbit) gives us >> 3MB/s rate maximum. If we put some load on the guest, it is easy to >> get page dirtying rate too big so live migration will n

Re: [Qemu-devel] [PATCH v2 1/2] vnc: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Eric Blake writes: > On 06/06/2014 10:47 AM, Markus Armbruster wrote: >> Signed-off-by: Markus Armbruster >> --- >> ui/vnc-tls.c | 6 ++ >> ui/vnc.c | 12 >> 2 files changed, 6 insertions(+), 12 deletions(-) >> >> diff --git a/ui/vnc-tls.c b/ui/vnc-tls.c >> index 50275de.

[Qemu-devel] [PULL 23/42] dataplane: use the QEMU block layer for I/O

2014-06-06 Thread Stefan Hajnoczi
Stop using a custom Linux AIO request queue from ioq.h and instead use the QEMU block layer for I/O. This patch adjusts the VirtIOBlockRequest struct with fields needed for bdrv_aio_readv()/bdrv_aio_writev(). ioq.h used struct iovec and struct iocb, which we don't need directly anymore. Modify d

Re: [Qemu-devel] [PATCH v2 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Eric Blake
On 06/06/2014 10:47 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > ui/vnc.c | 5 + > 1 file changed, 1 insertion(+), 4 deletions(-) Reviewed-by: Eric Blake -- Eric Blake eblake redhat com+1-919-301-3266 Libvirt virtualization library http://libvirt.org si

[Qemu-devel] [PULL 02/42] block: use BlockDriverState AioContext

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_aio_wait() to aio_poll() and qemu_bh_new() to aio_bh_new() so the BlockDriverState AioContext is used. Note there is still one qemu_aio_wait() left in bdrv_create() but we do not have a BlockDriverState there and only main loo

Re: [Qemu-devel] [PATCH v2 1/2] vnc: Drop superfluous conditionals around g_free()

2014-06-06 Thread Eric Blake
On 06/06/2014 10:47 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > ui/vnc-tls.c | 6 ++ > ui/vnc.c | 12 > 2 files changed, 6 insertions(+), 12 deletions(-) > > diff --git a/ui/vnc-tls.c b/ui/vnc-tls.c > index 50275de..6392326 100644 > --- a/ui/vnc-

[Qemu-devel] [PULL 07/42] blkverify: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_bh_new() to aio_bh_new() and qemu_aio_wait() to aio_poll() so we use the BlockDriverState's AioContext. Implement .bdrv_detach/attach_aio_context() interfaces to propagate detach/attach to BDRVBlkverifyState->test_file. The b

Re: [Qemu-devel] [PATCH] libcacard: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Paolo Bonzini writes: > Il 06/06/2014 18:32, Markus Armbruster ha scritto: >> Signed-off-by: Markus Armbruster >> --- >> libcacard/cac.c| 14 -- >> libcacard/card_7816.c | 12 +++- >> libcacard/vcard.c | 10 +++--- >> libcacard/vcard_emul_nss.c

Re: [Qemu-devel] [PATCH v8 4/4] vfio: Enable for SPAPR

2014-06-06 Thread Alex Williamson
On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: > This turns the sPAPR support on and enables VFIO container use > in the kernel. > > This extends vfio_connect_container to support VFIO_SPAPR_TCE_IOMMU type > in the host kernel. > > This registers a memory listener which sPAPR IOMM

[Qemu-devel] [PULL 01/42] aio: fix qemu_bh_schedule() bh->ctx race condition

2014-06-06 Thread Stefan Hajnoczi
qemu_bh_schedule() is supposed to be thread-safe at least the first time it is called. Unfortunately this is not quite true: bh->scheduled = 1; aio_notify(bh->ctx); Since another thread may run the BH callback once it has been scheduled, there is a race condition if the callback frees the BH

Re: [Qemu-devel] [PATCH 0/2] virtio: Drop some superfluous conditionals

2014-06-06 Thread Eric Blake
On 06/06/2014 10:43 AM, Markus Armbruster wrote: > Markus Armbruster (2): > virtio: Drop superfluous conditionals around g_free() > virtio: Drop superfluous conditionals around g_strdup() > > hw/9pfs/virtio-9p.c | 4 +--- > hw/net/virtio-net.c | 27 +++ > hw/virtio/vh

Re: [Qemu-devel] [PATCH] audio: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Eric Blake writes: > On 06/06/2014 10:35 AM, Markus Armbruster wrote: >> Signed-off-by: Markus Armbruster >> --- >> audio/alsaaudio.c | 12 >> audio/audio_template.h | 15 --- >> audio/ossaudio.c | 6 ++ >> hw/audio/adlib.c | 4 +--- >> 4 files ch

Re: [Qemu-devel] [PATCH v8 2/4] vfio: Add vfio_container_ioctl()

2014-06-06 Thread Alexey Kardashevskiy
On 06/07/2014 02:48 AM, Alex Williamson wrote: > On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: >> While most operations with VFIO IOMMU driver are generic and used inside >> vfio.c, there are still some operations which only specific VFIO IOMMU >> drivers implement. The first examp

Re: [Qemu-devel] [Bug 1326986] [NEW] e1000 - no link detected by VXWorks based guest

2014-06-06 Thread Paul Janzen
Matthew Gamble writes: > Public bug reported: > > I'm trying to get a VXWorks image running inside a qemu guest. I have > the machine running, however, the vxworks image only has support for the > 82544EI device so I had to change the device ID in e1000.c to get the > device even recognized so I

Re: [Qemu-devel] [PATCH 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Markus Armbruster
Paolo Bonzini writes: > Il 06/06/2014 18:36, Markus Armbruster ha scritto: >> Signed-off-by: Markus Armbruster >> --- >> ui/vnc.c | 4 +--- >> 1 file changed, 1 insertion(+), 3 deletions(-) >> >> diff --git a/ui/vnc.c b/ui/vnc.c >> index d771a2c..0853ded 100644 >> --- a/ui/vnc.c >> +++ b/ui/vnc

Re: [Qemu-devel] [PATCH v8 2/4] vfio: Add vfio_container_ioctl()

2014-06-06 Thread Alex Williamson
On Fri, 2014-06-06 at 13:34 +1000, Alexey Kardashevskiy wrote: > While most operations with VFIO IOMMU driver are generic and used inside > vfio.c, there are still some operations which only specific VFIO IOMMU > drivers implement. The first example of it will be reading a DMA window > start from t

Re: [Qemu-devel] [PATCH 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Markus Armbruster
Wrong patch; v2 sent.

[Qemu-devel] [PATCH v2 0/2] vnc: Drop some superfluous conditionals

2014-06-06 Thread Markus Armbruster
Markus Armbruster (2): vnc: Drop superfluous conditionals around g_free() vnc: Drop superfluous conditionals around g_strdup() ui/vnc-tls.c | 6 ++ ui/vnc.c | 15 --- 2 files changed, 6 insertions(+), 15 deletions(-) -- 1.9.3

[Qemu-devel] [PATCH v2 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- ui/vnc.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ui/vnc.c b/ui/vnc.c index d771a2c..6c9d4f3 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -3009,10 +3009,7 @@ int vnc_display_password(DisplayState *ds, const char *password) }

[Qemu-devel] [PULL 42/42] qapi: Extract qapi/block.json definitions

2014-06-06 Thread Stefan Hajnoczi
From: Benoît Canet Signed-off-by: Benoit Canet Reviewed-by: Eric Blake Signed-off-by: Stefan Hajnoczi --- qapi-schema.json | 159 --- qapi/block.json | 159 +++ 2 files changed, 159 insert

Re: [Qemu-devel] [PATCH 1/2] vnc: Drop superfluous conditionals around g_free()

2014-06-06 Thread Eric Blake
On 06/06/2014 10:36 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > ui/vnc-tls.c | 6 ++ > ui/vnc.c | 12 > 2 files changed, 6 insertions(+), 12 deletions(-) > > diff --git a/ui/vnc-tls.c b/ui/vnc-tls.c > index 50275de..6392326 100644 > --- a/ui/vnc-

[Qemu-devel] [PATCH 1/2] virtio: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- hw/9pfs/virtio-9p.c | 4 +--- hw/net/virtio-net.c | 24 hw/virtio/vhost.c | 8 ++-- hw/virtio/virtio.c | 12 4 files changed, 15 insertions(+), 33 deletions(-) diff --git a/hw/9pfs/virtio-9p.c b/hw/9pfs/virtio-9p

Re: [Qemu-devel] [PATCH] audio: Drop superfluous conditionals around g_free()

2014-06-06 Thread Eric Blake
On 06/06/2014 10:35 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > audio/alsaaudio.c | 12 > audio/audio_template.h | 15 --- > audio/ossaudio.c | 6 ++ > hw/audio/adlib.c | 4 +--- > 4 files changed, 11 insertions(+), 26 de

[Qemu-devel] [PATCH 2/2] virtio: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- hw/net/virtio-net.c | 7 +-- hw/virtio/virtio.c | 6 +- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index dd28a5a..0a34a8b 100644 --- a/hw/net/virtio-net.c +++ b/hw/net/virtio-net.c @@ -151

[Qemu-devel] [PATCH 0/2] virtio: Drop some superfluous conditionals

2014-06-06 Thread Markus Armbruster
Markus Armbruster (2): virtio: Drop superfluous conditionals around g_free() virtio: Drop superfluous conditionals around g_strdup() hw/9pfs/virtio-9p.c | 4 +--- hw/net/virtio-net.c | 27 +++ hw/virtio/vhost.c | 8 ++-- hw/virtio/virtio.c | 16 ---

[Qemu-devel] [PULL 25/42] dataplane: implement async flush

2014-06-06 Thread Stefan Hajnoczi
Stop using the raw-posix file descriptor for synchronous qemu_fdatasync(). Use bdrv_aio_flush() instead and drop the VirtIOBlockDataPlane->fd field. Signed-off-by: Stefan Hajnoczi --- hw/block/dataplane/virtio-blk.c | 43 ++--- 1 file changed, 27 insertions(+

Re: [Qemu-devel] [PATCH] block: Drop superfluous conditionals around g_free()

2014-06-06 Thread Eric Blake
On 06/06/2014 10:25 AM, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > block/curl.c | 9 +++-- > block/iscsi.c | 4 +--- > hw/block/onenand.c | 4 +--- > 3 files changed, 5 insertions(+), 12 deletions(-) Reviewed-by: Eric Blake -- Eric Blake eblake redhat

[Qemu-devel] [PULL 04/42] block: acquire AioContext in bdrv_drain_all()

2014-06-06 Thread Stefan Hajnoczi
Modify bdrv_drain_all() to take into account that BlockDriverState instances may be running in different AioContexts. This patch changes the implementation of bdrv_drain_all() while preserving the semantics. Previously kicking throttled requests and checking for pending requests were done across

Re: [Qemu-devel] [PATCH] libcacard: Drop superfluous conditionals around g_free()

2014-06-06 Thread Paolo Bonzini
Il 06/06/2014 18:32, Markus Armbruster ha scritto: Signed-off-by: Markus Armbruster --- libcacard/cac.c| 14 -- libcacard/card_7816.c | 12 +++- libcacard/vcard.c | 10 +++--- libcacard/vcard_emul_nss.c | 4 +--- libcacard/vreader.c| 4

Re: [Qemu-devel] [PATCH 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Paolo Bonzini
Il 06/06/2014 18:36, Markus Armbruster ha scritto: Signed-off-by: Markus Armbruster --- ui/vnc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ui/vnc.c b/ui/vnc.c index d771a2c..0853ded 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -3010,9 +3010,7 @@ int vnc_display_password(

[Qemu-devel] [PATCH 0/2] vnc: Drop some superfluous conditionals

2014-06-06 Thread Markus Armbruster
Markus Armbruster (2): vnc: Drop superfluous conditionals around g_free() vnc: Drop superfluous conditionals around g_strdup() ui/vnc-tls.c | 6 ++ ui/vnc.c | 16 +--- 2 files changed, 7 insertions(+), 15 deletions(-) -- 1.9.3

[Qemu-devel] [PATCH 2/2] vnc: Drop superfluous conditionals around g_strdup()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- ui/vnc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ui/vnc.c b/ui/vnc.c index d771a2c..0853ded 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -3010,9 +3010,7 @@ int vnc_display_password(DisplayState *ds, const char *password) g_fre

[Qemu-devel] [PATCH 1/2] vnc: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- ui/vnc-tls.c | 6 ++ ui/vnc.c | 12 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/ui/vnc-tls.c b/ui/vnc-tls.c index 50275de..6392326 100644 --- a/ui/vnc-tls.c +++ b/ui/vnc-tls.c @@ -443,10 +443,8 @@ static int vnc_set_x5

[Qemu-devel] [PATCH] audio: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- audio/alsaaudio.c | 12 audio/audio_template.h | 15 --- audio/ossaudio.c | 6 ++ hw/audio/adlib.c | 4 +--- 4 files changed, 11 insertions(+), 26 deletions(-) diff --git a/audio/alsaaudio.c b/audio/alsaaudio.c

[Qemu-devel] [PATCH] libcacard: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- libcacard/cac.c| 14 -- libcacard/card_7816.c | 12 +++- libcacard/vcard.c | 10 +++--- libcacard/vcard_emul_nss.c | 4 +--- libcacard/vreader.c| 4 +--- 5 files changed, 12 insertions(+), 32 deletion

[Qemu-devel] [PULL 39/42] qapi: Extract qapi/common.json definitions

2014-06-06 Thread Stefan Hajnoczi
From: Benoît Canet Signed-off-by: Benoit Canet Reviewed-by: Eric Blake Signed-off-by: Stefan Hajnoczi --- qapi-schema.json | 87 ++ qapi/common.json | 89 2 files changed, 91 insertion

Re: [Qemu-devel] [PATCH] KVM: Fix GSI number space limit

2014-06-06 Thread Paolo Bonzini
Il 06/06/2014 14:46, Alexander Graf ha scritto: KVM tells us the number of GSIs it can handle inside the kernel. That value is basically KVM_MAX_IRQ_ROUTES. However when we try to set the GSI mapping table, it checks for r = -EINVAL; if (routing.nr >= KVM_MAX_IRQ_ROUTES) goto out

[Qemu-devel] [PULL 33/42] blockdev: acquire AioContext in block_set_io_throttle

2014-06-06 Thread Stefan Hajnoczi
The block_set_io_throttle QMP and HMP commands modify I/O throttling limits for block devices. Acquire the BlockDriverState's AioContext to protect against race conditions with an IOThread that is running I/O for this device. Signed-off-by: Stefan Hajnoczi Reviewed-by: Benoit Canet --- blockde

[Qemu-devel] [PULL 32/42] throttle: add detach/attach test case

2014-06-06 Thread Stefan Hajnoczi
Add a test case that checks the timer is really removed/added by the detach/attach functions. Signed-off-by: Stefan Hajnoczi Reviewed-by: Benoit Canet --- tests/test-throttle.c | 24 1 file changed, 24 insertions(+) diff --git a/tests/test-throttle.c b/tests/test-throt

[Qemu-devel] [PULL 40/42] qapi: create two block related json modules

2014-06-06 Thread Stefan Hajnoczi
From: Benoît Canet qapi/block-core.json contains block definitions unrelated to emulation. qapi/block.json is a superset of the previous and contains definitions related to emulation. The purpose of these extractions is to be able to hook qapi/block-core.json generated code on qemu-nbd. Signed

[Qemu-devel] [PATCH] block: Drop superfluous conditionals around g_free()

2014-06-06 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- block/curl.c | 9 +++-- block/iscsi.c | 4 +--- hw/block/onenand.c | 4 +--- 3 files changed, 5 insertions(+), 12 deletions(-) diff --git a/block/curl.c b/block/curl.c index f491b0b..6498fd6 100644 --- a/block/curl.c +++ b/block/curl.c @@ -599,

[Qemu-devel] [PULL 35/42] qemu-img: Document check exit codes

2014-06-06 Thread Stefan Hajnoczi
From: Max Reitz The exit code 63 (check not supported by image format) was not even documented in the comment above the check command in the source code; add it, as it does indeed seem useful. Also, document all of check's exit codes in the manpage. Signed-off-by: Max Reitz Reported-by: Markus

[Qemu-devel] [PULL 36/42] rbd: Fix leaks in rbd_start_aio() error path

2014-06-06 Thread Stefan Hajnoczi
From: Kevin Wolf Signed-off-by: Kevin Wolf Reviewed-by: Benoit Canet Reviewed-by: Josh Durgin Signed-off-by: Stefan Hajnoczi --- block/rbd.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/block/rbd.c b/block/rbd.c index a78760b..93639f7 100644 --- a/block/rbd.c +++ b

[Qemu-devel] [PULL 28/42] virtio-blk: Allow config-wce in dataplane

2014-06-06 Thread Stefan Hajnoczi
From: Fam Zheng Dataplane now uses block layer. Protect bdrv_set_enable_write_cache with aio_context_acquire and aio_context_release, so we can enable config-wce to allow guest to modify the write cache online. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- hw/block/dataplane/vir

[Qemu-devel] [PULL 29/42] virtio-blk: Factor out virtio_blk_handle_scsi_req from virtio_blk_handle_scsi

2014-06-06 Thread Stefan Hajnoczi
From: Fam Zheng The common logic to process a scsi request in a VirtQueueElement is extracted to a function to share with dataplane. This makes VirtIOBlockReq.scsi unused, so drop it. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- hw/block/virtio-blk.c | 75

[Qemu-devel] [PULL 19/42] rbd: use BlockDriverState's AioContext

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_bh_new() to aio_bh_new() and qemu_aio_wait() to aio_poll(). The .bdrv_detach_aio_context() and .bdrv_attach_aio_context() interfaces are not needed since no fd handlers, timers, or BHs stay registered when requests have been d

[Qemu-devel] [PULL 30/42] dataplane: Support VIRTIO_BLK_T_SCSI_CMD

2014-06-06 Thread Stefan Hajnoczi
From: Fam Zheng Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- hw/block/dataplane/virtio-blk.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/hw/block/dataplane/virtio-blk.c b/hw/block/dataplane/virtio-blk.c index 217992b..c10b7b7 100644 --

[Qemu-devel] [PULL 34/42] block: fix wrong order in live block migration setup

2014-06-06 Thread Stefan Hajnoczi
From: chai wen The function init_blk_migration is better to be called before set_dirty_tracking as the reasons below. If we want to track dirty blocks via dirty_maps on a BlockDriverState when doing live block-migration, its correspoding 'BlkMigDevState' should be added to block_mig_state.bmds_l

[Qemu-devel] [PULL 31/42] throttle: add throttle_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Block I/O throttling uses timers and currently always adds them to the main loop. Throttling will break if bdrv_set_aio_context() is used to move a BlockDriverState to a different AioContext. This patch adds throttle_detach/attach_aio_context() interfaces so the throttling timers and uses them to

[Qemu-devel] [PULL 18/42] block/raw-win32: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext for raw-win32. Convert the aio-win32 code to support detach/attach and replace qemu_aio_wait() with aio_poll(). The .bdrv_detach/attach_aio_context() interfaces move the aio-win32 event notifier from the old to the new AioContext. Cc: Paolo

[Qemu-devel] [PULL 15/42] block/raw-posix: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext for Linux AIO. Convert the Linux AIO event notifier to use aio_set_event_notifier(). The .bdrv_detach/attach_aio_context() interfaces also need to be implemented to move the event notifier handler from the old to the new AioContext. Signed-

[Qemu-devel] [PULL 26/42] raw-posix: drop raw_get_aio_fd() since it is no longer used

2014-06-06 Thread Stefan Hajnoczi
virtio-blk data-plane now uses the QEMU block layer for I/O. We do not need raw_get_aio_fd() anymore. It was a layering violation anyway, so let's get rid of it. Signed-off-by: Stefan Hajnoczi --- block/raw-posix.c | 34 -- include/block/block.h | 9 ---

[Qemu-devel] [PULL 24/42] dataplane: delete IOQueue since it is no longer used

2014-06-06 Thread Stefan Hajnoczi
This custom Linux AIO request queue is no longer used by virtio-blk data-plane. Signed-off-by: Stefan Hajnoczi --- hw/block/dataplane/Makefile.objs | 2 +- hw/block/dataplane/ioq.c | 117 --- hw/block/dataplane/ioq.h | 57 ---

[Qemu-devel] [PULL 22/42] vmdk: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Implement .bdrv_detach/attach_aio_context() interfaces to propagate detach/attach to BDRVVmdkState->extents[].file. The block layer takes care of ->file and ->backing_hd but doesn't know about our extents BlockDriverStates, which is also part of the graph. Reviewed-by: Fam Zheng Signed-off-by: S

[Qemu-devel] [PULL 14/42] quorum: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Implement .bdrv_detach/attach_aio_context() interfaces to propagate detach/attach to BDRVQuorumState->bs[] children. The block layer takes care of ->file and ->backing_hd but doesn't know about our ->bs[] BlockDriverStates, which is also part of the graph. Reviewed-by: Benoît Canet Signed-off-by

[Qemu-devel] [PULL 21/42] ssh: use BlockDriverState's AioContext

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Use bdrv_get_aio_context() to register fd handlers in the right AioContext for this BlockDriverState. The .bdrv_detach_aio_context() and .bdrv_attach_aio_context() interfaces are not needed since no fd handlers, timers, or BHs stay registe

[Qemu-devel] [PULL 13/42] qed: use BlockDriverState's AioContext

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. Convert qemu_bh_new() to aio_bh_new() and qemu_aio_wait() to aio_poll() so we're using the BlockDriverState's AioContext. Implement .bdrv_detach/attach_aio_context() interfaces to move the QED_F_NEED_CHECK timer from the old AioContext to

[Qemu-devel] [PULL 12/42] nfs: implement .bdrv_detach/attach_aio_context()

2014-06-06 Thread Stefan Hajnoczi
Drop the assumption that we're using the main AioContext. The following functions need to be converted: * qemu_bh_new() -> aio_bh_new() * qemu_aio_set_fd_handler() -> aio_set_fd_handler() * qemu_aio_wait() -> aio_poll() The .bdrv_detach/attach_aio_context() interfaces also need to be implement

  1   2   3   >