[Qemu-devel] [CVE-2014-3615 PATCH v2 2/3] vbe: rework sanity checks

2014-09-04 Thread Gerd Hoffmann
Plug a bunch of holes in the bochs dispi interface parameter checking. Add a function doing verification on all registers. Call that unconditionally on every register write. That way we should catch everything, even changing one register affecting the valid range of another register. Some of the

[Qemu-devel] [CVE-2014-3615 PATCH v2 3/3] spice: make sure we don't overflow ssd->buf

2014-09-04 Thread Gerd Hoffmann
Related spice-only bug. We have a fixed 16 MB buffer here, being presented to the spice-server as qxl video memory in case spice is used with a non-qxl card. It's also used with qxl in vga mode. When using display resolutions requiring more than 16 MB of memory we are going to overflow that buff

[Qemu-devel] [CVE-2014-3615 PATCH v2 0/3] vbe: bochs dispi interface fixes

2014-09-04 Thread Gerd Hoffmann
Hi, Two fixes for the bochs dispi interface, one of them fixing a minor security issue. New in v2: Got a CVE number. Investigation & patch review found a related issue in the spice code, so there is an additional patch. /me plans to send a pull tomorrow, so this can go in fast enougth for be

[Qemu-devel] [CVE-2014-3615 PATCH v2 1/3] vbe: make bochs dispi interface return the correct memory size with qxl

2014-09-04 Thread Gerd Hoffmann
VgaState->vram_size is the size of the pci bar. In case of qxl not the whole pci bar can be used as vga framebuffer. Add a new variable vbe_size to handle that case. By default (if unset) it equals vram_size, but qxl can set vbe_size to something else. This makes sure VBE_DISPI_INDEX_VIDEO_MEMO

[Qemu-devel] Audio stream handling in QEMU device model

2014-09-04 Thread Harry Cruise
Hello, I am trying to comprehend QEMU AUDIO backend functionality and need to implementing device which has few audio channels from which it receives audio streams (sampled at some specific frequency), and further process that data stream like mixing two stream. I am new for the QEMU, Please h

Re: [Qemu-devel] Audio stream handling in QEMU device model

2014-09-04 Thread Gerd Hoffmann
On Do, 2014-09-04 at 00:22 -0700, Harry Cruise wrote: > Hello, > > > I am trying to comprehend QEMU AUDIO backend functionality and need to > implementing device which has few audio channels from which it > receives audio streams (sampled at some specific frequency), and > further process that da

Re: [Qemu-devel] [question] virtio-blk performance degradationhappenedwith virito-serial

2014-09-04 Thread Zhang Haoyu
>> > > If virtio-blk and virtio-serial share an IRQ, the guest operating system >> > > has to check each virtqueue for activity. Maybe there is some >> > > inefficiency doing that. >> > > AFAIK virtio-serial registers 64 virtqueues (on 31 ports + console) even >> > > if everything is unused. >>

Re: [Qemu-devel] [Qemu-ppc] [PATCH 4/5] target-ppc: Handle ibm, nmi-register RTAS call

2014-09-04 Thread Aravinda Prasad
On Friday 29 August 2014 03:46 AM, Alexander Graf wrote: > > > On 28.08.14 19:42, Aravinda Prasad wrote: >> >> >> On Thursday 28 August 2014 02:07 PM, Alexander Graf wrote: >>> >>> >>> On 28.08.14 08:38, Aravinda Prasad wrote: On Wednesday 27 August 2014 04:07 PM, Alexander Graf

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Hu Tao
On Fri, Aug 29, 2014 at 09:48:01AM +0100, Richard W.M. Jones wrote: > On Fri, Aug 29, 2014 at 04:33:12PM +0800, Hu Tao wrote: > > +if (prealloc == PREALLOC_MODE_FULL) { > > +/* posix_fallocate() doesn't set errno. */ > > +result = -posix_fallocate(fd, 0, total_size); > > +

[Qemu-devel] [PATCH 1/3] net: invoke callback when purging queue

2014-09-04 Thread Michael S. Tsirkin
devices rely on packet callbacks eventually running, but we violate this rule whenever we purge the queue. To fix, invoke callbacks on all packets on purge. Set length to 0, this way callers can detect that this happened and re-queue if necessary. Cc: qemu-sta...@nongnu.org Cc: Jason Wang Signed-

[Qemu-devel] [PATCH 2/3] net: complete all queued packets on VM stop

2014-09-04 Thread Michael S. Tsirkin
This completes all packets, ensuring that callbacks will not run when VM is stopped. Cc: qemu-sta...@nongnu.org Cc: Jason Wang Signed-off-by: Michael S. Tsirkin --- net/net.c | 33 - 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/net/net.c b/net/ne

[Qemu-devel] [PATCH 3/3] virtio-net: purge outstanding packets when starting vhost

2014-09-04 Thread Michael S. Tsirkin
whenever we start vhost, virtio could have outstanding packets queued, when they complete later we'll modify the ring while vhost is processing it. To prevent this, purge outstanding packets on vhost start. Cc: qemu-sta...@nongnu.org Cc: Jason Wang Signed-off-by: Michael S. Tsirkin --- hw/net/

[Qemu-devel] [Bug 1358722] Re: latest acpi commits causes memory allocation fault in macosx

2014-09-04 Thread Marco Minetti
The experiments for running MacOSXon KVM/QEMU I followed are here: http://www.contrib.andrew.cmu.edu/~somlo/OSXKVM/ -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1358722 Title: latest acpi commits

[Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Stefan Hajnoczi
On-disk structures should be marked packed so the compiler does not insert padding for field alignment. Padding should be explicit so on-disk layout is obvious and we don't rely on the architecture-specific ABI for alignment rules. The pahole(1) diff shows that the padding is now explicit and off

Re: [Qemu-devel] [PATCH 1/2] qemu-iotests: fix filter of encryption option

2014-09-04 Thread Hu Tao
On Fri, Aug 29, 2014 at 05:06:20PM +0100, Stefan Hajnoczi wrote: > On Thu, Aug 28, 2014 at 04:56:03PM +0800, Hu Tao wrote: > > We should filter out encryption=on, too. > > > > Signed-off-by: Hu Tao > > --- > > tests/qemu-iotests/common.filter | 2 +- > > 1 file changed, 1 insertion(+), 1 deletio

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Kevin Wolf
Am 04.09.2014 um 10:58 hat Stefan Hajnoczi geschrieben: > On-disk structures should be marked packed so the compiler does not > insert padding for field alignment. Padding should be explicit so > on-disk layout is obvious and we don't rely on the architecture-specific > ABI for alignment rules. >

Re: [Qemu-devel] [PATCH v13 1/6] block: round up file size to nearest sector

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 14:50 hat Eric Blake geschrieben: > On 08/29/2014 02:33 AM, Hu Tao wrote: > > +++ b/block/raw-posix.c > > @@ -1369,8 +1369,8 @@ static int raw_create(const char *filename, QemuOpts > > *opts, Error **errp) > > strstart(filename, "file:", &filename); > > > > /* Read out

Re: [Qemu-devel] [PATCH] target-i386: Reject invalid CPU feature names on the command-line

2014-09-04 Thread Igor Mammedov
On Thu, 21 Aug 2014 17:22:56 -0300 Eduardo Habkost wrote: > Instead of simply printing a warning, report an error when invalid CPU > options are provided on the CPU model string. > > Signed-off-by: Eduardo Habkost Reviewed-By: Igor Mammedov > --- > target-i386/cpu.c | 9 + > 1 file

Re: [Qemu-devel] [PATCH v13 1/6] block: round up file size to nearest sector

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > Signed-off-by: Hu Tao > diff --git a/tests/qemu-iotests/104 b/tests/qemu-iotests/104 > new file mode 100755 > index 000..0c1d4fb > --- /dev/null > +++ b/tests/qemu-iotests/104 > @@ -0,0 +1,57 @@ > +#!/bin/bash > +# > +# Test qcow2 creation with

Re: [Qemu-devel] Serial: possible hang during intensive interaction over the console

2014-09-04 Thread Kirill Batuzov
On Wed, 3 Sep 2014, Andrey Korolyov wrote: > Given 2.1 and isa-serial output, set as ttyS0 for the guest VM with > 9600 baud rate. > > The test case is quite simple - display as much data as possible over > serial console and do not hang the system. While qemu-1.1 works > perfectly, with complaini

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Benoît Canet
The Thursday 04 Sep 2014 à 09:58:41 (+0100), Stefan Hajnoczi wrote : > On-disk structures should be marked packed so the compiler does not > insert padding for field alignment. Padding should be explicit so > on-disk layout is obvious and we don't rely on the architecture-specific > ABI for alignm

Re: [Qemu-devel] [PATCH v13 2/6] block: don't convert file size to sector size

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > and avoid converting it back later. > > Signed-off-by: Hu Tao > diff --git a/block/raw-posix.c b/block/raw-posix.c > index 9c22e3f..abe0759 100644 > --- a/block/raw-posix.c > +++ b/block/raw-posix.c > @@ -1369,8 +1369,8 @@ static int raw_create(co

Re: [Qemu-devel] [PATCH 1/3] net: invoke callback when purging queue

2014-09-04 Thread Jason Wang
On 09/04/2014 04:39 PM, Michael S. Tsirkin wrote: > devices rely on packet callbacks eventually running, > but we violate this rule whenever we purge the queue. > To fix, invoke callbacks on all packets on purge. > Set length to 0, this way callers can detect that > this happened and re-queue if ne

Re: [Qemu-devel] Serial: possible hang during intensive interaction over the console

2014-09-04 Thread Andrey Korolyov
On Thu, Sep 4, 2014 at 1:46 PM, Kirill Batuzov wrote: > On Wed, 3 Sep 2014, Andrey Korolyov wrote: > >> Given 2.1 and isa-serial output, set as ttyS0 for the guest VM with >> 9600 baud rate. >> >> The test case is quite simple - display as much data as possible over >> serial console and do not ha

Re: [Qemu-devel] [PATCH v13 3/6] rename parse_enum_option to qapi_enum_parse and make it public

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > From: Peter Lieven > > relaxing the license to LGPLv2+ is intentional. > > Suggested-by: Markus Armbruster > Signed-off-by: Hu Tao > Signed-off-by: Peter Lieven > Reviewed-by: Eric Blake > Reviewed-by: Benoit Canet Reviewed-by: Kevin Wolf

Re: [Qemu-devel] [PATCH 2/3] net: complete all queued packets on VM stop

2014-09-04 Thread Jason Wang
On 09/04/2014 04:39 PM, Michael S. Tsirkin wrote: > This completes all packets, ensuring that callbacks > will not run when VM is stopped. > > Cc: qemu-sta...@nongnu.org > Cc: Jason Wang > Signed-off-by: Michael S. Tsirkin > --- > net/net.c | 33 - > 1 file change

Re: [Qemu-devel] [PATCH 4/4] blocksize: add blkconf_blocksize call to all block devices

2014-09-04 Thread Ekaterina Tumanova
On 09/03/2014 07:46 PM, Stefan Hajnoczi wrote: On Tue, Jul 29, 2014 at 02:27:19PM +0200, Ekaterina Tumanova wrote: This patch add the blkconf_blocksize call to all devices, which use DEFINE_BLOCK_PROPERTIES. If the underlying driver function fails, blkconf_blocksizes will set blocksizes to defau

[Qemu-devel] [PATCH] virtio: don't call device on !vm_running

2014-09-04 Thread Michael S. Tsirkin
On vm stop, virtio changes vm_running state too soon, so callbacks can get envoked with vm_running = false; Cc: qemu-sta...@nongnu.org Cc: Jason Wang Signed-off-by: Michael S. Tsirkin --- hw/virtio/virtio.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/hw/virtio/vi

Re: [Qemu-devel] [PATCH 2/3] net: complete all queued packets on VM stop

2014-09-04 Thread Michael S. Tsirkin
On Thu, Sep 04, 2014 at 06:15:12PM +0800, Jason Wang wrote: > On 09/04/2014 04:39 PM, Michael S. Tsirkin wrote: > > This completes all packets, ensuring that callbacks > > will not run when VM is stopped. > > > > Cc: qemu-sta...@nongnu.org > > Cc: Jason Wang > > Signed-off-by: Michael S. Tsirkin

Re: [Qemu-devel] [PULL 00/13] pci, pc fixes, features

2014-09-04 Thread Peter Maydell
On 3 September 2014 12:26, Michael S. Tsirkin wrote: > A problem was reported with this one. > I fixed it up, will send v2 pull. I accidentally just merged the v1 by mistake :-( Sorry about that; I'm going to merge in the v2 (it conflicts in vhost_net.c but fairly trivially so I'll fix that up) a

[Qemu-devel] [PATCH v2 0/4] target-ppc: Add FWNMI support in qemu for powerKVM guests

2014-09-04 Thread Aravinda Prasad
This series of patches add support for fwnmi in powerKVM guests. Currently upon machine check exception, if the address in error belongs to guest then KVM invokes guest's NMI interrupt vector 0x200. This patch series adds functionality where the guest's 0x200 interrupt vector is patched such that

[Qemu-devel] [PATCH v2 2/4] target-ppc: Register and handle HCALL to receive updated RTAS region

2014-09-04 Thread Aravinda Prasad
Receive updates from SLOF about the updated rtas-base. A separate patch for SLOF [1] adds functionality to invoke a a private HCALL whenever OS issues instantiate-rtas with a new rtas-base. This is required as qemu needs to know the updated rtas-base as it allocates error reporting structure in RT

[Qemu-devel] [PATCH v2 1/4] target-ppc: Extend rtas-blob

2014-09-04 Thread Aravinda Prasad
Extend rtas-blob to accommodate error log. Error log structure is saved in rtas space upon a machine check exception. Signed-off-by: Aravinda Prasad --- hw/ppc/spapr.c |4 1 file changed, 4 insertions(+) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 4b20e36..4a7c0ae 100644 --- a/h

[Qemu-devel] [PATCH v2 4/4] target-ppc: Handle ibm, nmi-register RTAS call

2014-09-04 Thread Aravinda Prasad
This patch adds FWNMI support in qemu for powerKVM guests by handling the ibm,nmi-register rtas call. Whenever OS issues ibm,nmi-register RTAS call, the machine check notification address is saved and the machine check interrupt vector 0x200 is patched to issue a private hcall. This patch also han

[Qemu-devel] [PATCH v2 3/4] target-ppc: Build error log

2014-09-04 Thread Aravinda Prasad
Whenever there is a physical memory error due to bit flips, which cannot be corrected by hardware, the error is passed on to the kernel. If the memory address in error belongs to guest address space then guest kernel is responsible to take action. Hence the error is passed on to guest via KVM by in

[Qemu-devel] [PATCH] virtio-pci: fix virtio-net child refcount in transports

2014-09-04 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-net child is not finalized! Dr

Re: [Qemu-devel] [PATCH v6 02/27] bootindex: add del_boot_device_path function

2014-09-04 Thread Gonglei (Arei)
> Subject: RE: [PATCH v6 02/27] bootindex: add del_boot_device_path function > > Hi, > > > > Subject: Re: [PATCH v6 02/27] bootindex: add del_boot_device_path > function > > > > > > On Wed, Sep 03, 2014 at 06:45:56AM +, Gonglei (Arei) wrote: > > > [...] > > > > > > 4. When we hotplug the virt

Re: [Qemu-devel] [PATCH] MAINTAINERS: update sheepdog maintainer

2014-09-04 Thread Stefan Hajnoczi
On Wed, Sep 03, 2014 at 10:13:17PM +0900, MORITA Kazutaka wrote: > Hitoshi takes over sheepdog maintenance from me. > > Signed-off-by: MORITA Kazutaka > --- > MAINTAINERS | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Thanks, applied to my block tree: https://github.com/stefanha/qemu/c

Re: [Qemu-devel] [PATCH v6 02/27] bootindex: add del_boot_device_path function

2014-09-04 Thread Gonglei (Arei)
Hi, > > I've confirmed that this is a bug, and have posted a patch fix it. > > Please review, thanks! > > [PATCH] virtio-pci: fix virtio-net child refcount in transports > > Best regards, > -Gonglei So, about Gerd's previous question: > When hot-unplugging virtio-net-pci I'd expect we free b

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Eric Blake
On 09/04/2014 02:58 AM, Stefan Hajnoczi wrote: > On-disk structures should be marked packed so the compiler does not > insert padding for field alignment. Padding should be explicit so > on-disk layout is obvious and we don't rely on the architecture-specific > ABI for alignment rules. > > The pa

Re: [Qemu-devel] [PATCH v3 0/3] add check for PCIe root ports and downstream ports

2014-09-04 Thread Gonglei (Arei)
Ping... Michael? Thanks! Best regards, -Gonglei > -Original Message- > From: Gonglei (Arei) > Sent: Monday, September 01, 2014 9:29 PM > To: qemu-devel@nongnu.org > Cc: m...@redhat.com; Huangweidong (C); pbonz...@redhat.com; > afaer...@suse.de; imamm...@redhat.com; peter.crosthwa...@xil

Re: [Qemu-devel] [RESEND PATCH v3 1/8] acpi, piix4: Add memory hot unplug support for piix4.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:32 +0800 Tang Chen wrote: > From: Hu Tao > > Implement acpi_memory_unplug_cb(), sending an sci to guest to trigger > memory hot-remove, and call it in piix4_device_unplug_cb(). > > Signed-off-by: Hu Tao > Signed-off-by: Tang Chen > --- > hw/acpi/memory_hotplug.c

Re: [Qemu-devel] [PATCH v13 4/6] qapi: introduce PreallocMode and a new PreallocMode full.

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > This patch prepares for the subsequent patches. > > Signed-off-by: Hu Tao > @@ -1915,7 +1916,7 @@ static int qcow2_create(const char *filename, QemuOpts > *opts, Error **errp) > uint64_t size = 0; > int flags = 0; > size_t cluster_

Re: [Qemu-devel] [RESEND PATCH v3 2/8] acpi, ich9: Add memory hot unplug support for ich9.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:33 +0800 Tang Chen wrote: > Implement ich9_pm_device_unplug_cb() to support memory hot-remove, > calling acpi_memory_unplug_cb(). And itself will be called in > ich9_device_unplug_cb(). > > Signed-off-by: Tang Chen > --- > hw/acpi/ich9.c | 12 > h

Re: [Qemu-devel] [PULL 00/13] pci, pc fixes, features

2014-09-04 Thread Peter Maydell
On 4 September 2014 12:11, Peter Maydell wrote: > On 3 September 2014 12:26, Michael S. Tsirkin wrote: >> A problem was reported with this one. >> I fixed it up, will send v2 pull. > > I accidentally just merged the v1 by mistake :-( > Sorry about that; I'm going to merge in the v2 (it conflicts

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > This patch adds a new option preallocation for raw format, and implements > full preallocation. > > Signed-off-by: Hu Tao v12 was better, it wasn't doing only metadata preallocation when you told it to do full preallocation. > +if (prealloc =

Re: [Qemu-devel] [RESEND PATCH v3 3/8] pc: Add memory hot unplug support for pc machine.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:34 +0800 Tang Chen wrote: > From: Hu Tao > > Implement device unplug callback for PCMachine. And it now only support > pc-dimm hot-remove. The callback will call piix4 or ich9 callbacks introduced > in previous patches. > > Signed-off-by: Hu Tao > Signed-off-by: Tang

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Richard W.M. Jones
On Thu, Sep 04, 2014 at 02:35:22PM +0200, Kevin Wolf wrote: > Please change the code to always write zeros for FULL, How is this useful for anyone? You don't know if the underlying SAN is going to detect these zeroes or combine these blocks together. It's just slow for no reason. Rich. -- Rich

[Qemu-devel] [PATCH v5 0/3] ivshmem: update documentation, add client/server tools

2014-09-04 Thread David Marchand
Here is a patchset containing an update on ivshmem specs documentation and importing ivshmem server and client tools. These tools have been written from scratch and are not related to what is available in nahanni repository. I put them in contrib/ directory as the qemu-doc.texi was already telling

[Qemu-devel] [PATCH v5 2/3] docs: update ivshmem device spec

2014-09-04 Thread David Marchand
Add some notes on the parts needed to use ivshmem devices: more specifically, explain the purpose of an ivshmem server and the basic concept to use the ivshmem devices in guests. Move some parts of the documentation and re-organise it. Signed-off-by: David Marchand Reviewed-by: Claudio Fontana -

[Qemu-devel] [PATCH v5 1/3] contrib: add ivshmem client and server

2014-09-04 Thread David Marchand
When using ivshmem devices, notifications between guests can be sent as interrupts using a ivshmem-server (typical use described in documentation). The client is provided as a debug tool. Signed-off-by: Olivier Matz Signed-off-by: David Marchand --- Makefile|

[Qemu-devel] [PATCH v5 3/3] ivshmem: add check on protocol version in QEMU

2014-09-04 Thread David Marchand
Send a protocol version as the first message from server, clients must close communication if they don't support this protocol version. Older QEMUs should be fine with this change in the protocol since they overrides their own vm_id on reception of an id associated to no eventfd. Signed-off-by: Da

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Kevin Wolf
Am 04.09.2014 um 14:45 hat Richard W.M. Jones geschrieben: > On Thu, Sep 04, 2014 at 02:35:22PM +0200, Kevin Wolf wrote: > > Please change the code to always write zeros for FULL, > > How is this useful for anyone? You don't know if the underlying SAN > is going to detect these zeroes or combine

Re: [Qemu-devel] [Important] Query regarding bdrv_co_discard

2014-09-04 Thread Sanjay Kumar2
Output of hdparam is below. Also let me know does network based protocol supports 'qcow2' format. As my block driver is network based. It is perfectly working for raw format. When I change the type='qcow2', then it is not working because bdrv_get_geometry() is returning 0. This I am talking abou

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Richard W.M. Jones
On Thu, Sep 04, 2014 at 02:52:57PM +0200, Kevin Wolf wrote: > Am 04.09.2014 um 14:45 hat Richard W.M. Jones geschrieben: > > On Thu, Sep 04, 2014 at 02:35:22PM +0200, Kevin Wolf wrote: > > > Please change the code to always write zeros for FULL, > > > > How is this useful for anyone? You don't kn

Re: [Qemu-devel] [PATCH v13 6/6] qcow2: Add full preallocation option

2014-09-04 Thread Kevin Wolf
Am 29.08.2014 um 10:33 hat Hu Tao geschrieben: > preallocation=full allocates disk space by fallocating the space if > posix_fallocate() is available, otherwise by writing zeros to disk to > ensure disk space in any cases. > > Signed-off-by: Hu Tao > --- > block/qcow2.c | 61 >

Re: [Qemu-devel] [Qemu-ppc] [PATCH 4/5] target-ppc: Handle ibm, nmi-register RTAS call

2014-09-04 Thread Alexander Graf
> Am 04.09.2014 um 10:25 schrieb Aravinda Prasad : > > > >> On Friday 29 August 2014 03:46 AM, Alexander Graf wrote: >> >> >>> On 28.08.14 19:42, Aravinda Prasad wrote: >>> >>> On Thursday 28 August 2014 02:07 PM, Alexander Graf wrote: > On 28.08.14 08:38, Aravinda Pra

Re: [Qemu-devel] [Bug 1358722] Re: latest acpi commits causes memory allocation fault in macosx

2014-09-04 Thread Gabriel L. Somlo
On Thu, 04 Sep 2014 08:43:12, Marco Minetti wrote: > The experiments for running MacOSXon KVM/QEMU I followed are here: > http://www.contrib.andrew.cmu.edu/~somlo/OSXKVM/ > [...] > > Bug description: > qemu release 2.1.0 > > Hi, > I've found a regression on MacOSX guest (10.9.4) after mer

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread shhuiw
At 2014-09-04 08:07:32, "Eric Blake" wrote: >On 09/04/2014 02:58 AM, Stefan Hajnoczi wrote: >> On-disk structures should be marked packed so the compiler does not >> insert padding for field alignment. Padding should be explicit so >> on-disk layout is obvious and we don't rely on the architect

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Daniel P. Berrange
On Thu, Sep 04, 2014 at 02:07:14PM +0100, Richard W.M. Jones wrote: > On Thu, Sep 04, 2014 at 02:52:57PM +0200, Kevin Wolf wrote: > > Am 04.09.2014 um 14:45 hat Richard W.M. Jones geschrieben: > > > On Thu, Sep 04, 2014 at 02:35:22PM +0200, Kevin Wolf wrote: > > > > Please change the code to always

Re: [Qemu-devel] [RFC][patch 0/6] pci pass-through support for qemu/KVM on s390

2014-09-04 Thread Alex Williamson
On Thu, 2014-09-04 at 12:52 +0200, frank.blasc...@de.ibm.com wrote: > This set of patches implements pci pass-through support for qemu/KVM on s390. > PCI support on s390 is very different from other platforms. > Major differences are: > > 1) all PCI operations are driven by special s390 instructio

Re: [Qemu-devel] [RESEND PATCH v3 3/8] pc: Add memory hot unplug support for pc machine.

2014-09-04 Thread Igor Mammedov
On Thu, 4 Sep 2014 14:44:41 +0200 Igor Mammedov wrote: > On Wed, 27 Aug 2014 16:08:34 +0800 > Tang Chen wrote: > > > From: Hu Tao > > > > Implement device unplug callback for PCMachine. And it now only support > > pc-dimm hot-remove. The callback will call piix4 or ich9 callbacks > > introdu

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Kevin Wolf
Am 04.09.2014 um 15:07 hat Richard W.M. Jones geschrieben: > On Thu, Sep 04, 2014 at 02:52:57PM +0200, Kevin Wolf wrote: > > Am 04.09.2014 um 14:45 hat Richard W.M. Jones geschrieben: > > > On Thu, Sep 04, 2014 at 02:35:22PM +0200, Kevin Wolf wrote: > > > > Please change the code to always write ze

Re: [Qemu-devel] [RESEND PATCH v3 4/8] qdev: Add memory hot unplug support for bus-less devices.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:35 +0800 Tang Chen wrote: > From: Hu Tao > > Implement bus-less device hot-remove in qdev_unplug(). It will call PCMachine > callback introduced in previous patch. > subject/commit message doesn't need to mention memory hotplug/PCMachine, it's generic handling that ap

Re: [Qemu-devel] [PATCH v6 02/27] bootindex: add del_boot_device_path function

2014-09-04 Thread Eduardo Habkost
On Thu, Sep 04, 2014 at 03:01:41AM +, Gonglei (Arei) wrote: > Hi, > > > From: Eduardo Habkost [mailto:ehabk...@redhat.com] > > Sent: Thursday, September 04, 2014 2:13 AM > > Subject: Re: [PATCH v6 02/27] bootindex: add del_boot_device_path function > > > > On Wed, Sep 03, 2014 at 06:45:56AM +

Re: [Qemu-devel] Don't return type from host in readdir on local 9p filesystem

2014-09-04 Thread Bastian Blank
On Wed, Sep 03, 2014 at 04:39:35PM -0500, Aneesh Kumar K.V wrote: > Michael Tokarev writes: > > From: Bastian Blank > > > > When using mapped mode in 9pfs, readdir implementation > > should not return file type in d_type from the host > > readdir, instead, it should use the type stored in > > the

Re: [Qemu-devel] tcmu-runner and QEMU

2014-09-04 Thread Benoît Canet
The Wednesday 03 Sep 2014 à 14:11:59 (+0100), Stefan Hajnoczi wrote : > On Tue, Sep 02, 2014 at 05:20:55PM -0700, Andy Grover wrote: > > On 09/02/2014 02:25 AM, Stefan Hajnoczi wrote: > > > The qemu-lio tool would live in the QEMU codebase and reuse all the > > > infrastructure. For example, it co

[Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Semion Prihodko
Hi guys, Need your help. I trying to find a way to compile/link a minimal kernel which outputs "Hello World" in qemu-system-aarch64. No tutorial found. There is no problem running the same example in Foundation emulator, but I need QEMU. Trying to reuse axf-file in Foundation example: aarch64-li

[Qemu-devel] [RFC][patch 3/6] KVM: s390: Add GISA support

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch adds GISA (Guest Interrupt State Area) support to s390 kvm. GISA can be used for exitless interrupts. The patch provides a set of functions for GISA related operations like accessing GISA fields or registering ISCs for alert. Exploiters of GISA will follow with add

Re: [Qemu-devel] [PULL 00/10] Trivial patches for 2014-09-03

2014-09-04 Thread Peter Maydell
On 3 September 2014 07:35, Michael Tokarev wrote: > Here's a next trivial-patches batch. A few little things here and there. > Please consider applying. > > Thanks, > > /mjt > > The following changes since commit 30eaca3acdf17d7bcbd1213eb149c02037edfb0b: > > Merge remote-tracking branch 'remote

[Qemu-devel] [RFC][patch 1/6] s390: cio: chsc function to register GIB

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch provides a new chsc function to register/unregister a GIB (Guest Information Block). Signed-off-by: Frank Blaschka --- arch/s390/include/asm/cio.h |1 drivers/s390/cio/chsc.c | 50 2 files changed, 51 inser

[Qemu-devel] [RFC][patch 4/6] KVM: s390: Add PCI pass-through support

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch implemets PCI pass-through kernel support for s390. Design approach is very similar to the x86 device assignment. User space executes the KVM_ASSIGN_PCI_DEVICE ioctl to create a proxy instance in the kernel KVM and connect this instance to the host pci device. s390

[Qemu-devel] [RFC][patch 0/6] pci pass-through support for qemu/KVM on s390

2014-09-04 Thread frank . blaschka
This set of patches implements pci pass-through support for qemu/KVM on s390. PCI support on s390 is very different from other platforms. Major differences are: 1) all PCI operations are driven by special s390 instructions 2) all s390 PCI instructions are privileged 3) PCI config and memory spaces

[Qemu-devel] [RFC][patch 2/6] s390: pci: export pci functions for pass-through usage

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch exports a couple of zPCI functions. The new pci pass-through driver for KVM will use this functions to enable the device with virtualization information and update the device dma translation table on the host. We add a new interface to purge the translation table o

Re: [Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Peter Maydell
On 4 September 2014 11:40, Semion Prihodko wrote: > Hi guys, > > Need your help. I trying to find a way to compile/link a minimal kernel > which outputs "Hello World" in qemu-system-aarch64. No tutorial found. There > is no problem running the same example in Foundation emulator, but I need > QEMU

[Qemu-devel] [RFC][patch 6/6] s390: Add PCI pass-through device support

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch adds a new device class handling s390 pci pass-through device assignment. The approach is very similar to the x86 device assignment. The device executes the KVM_ASSIGN_PCI_DEVICE ioctl to create a proxy instance in the kernel KVM and connect this instance to the ho

[Qemu-devel] [RFC][patch 5/6] s390: Add PCI bus support

2014-09-04 Thread frank . blaschka
From: Frank Blaschka This patch implements a pci bus for s390x together with some infrastructure to generate and handle hotplug events. It also provides device configuration/unconfiguration via sclp instruction interception. Signed-off-by: Frank Blaschka --- default-configs/s390x-softmmu.

Re: [Qemu-devel] [RESEND PATCH v3 5/8] pc-dimm: Add pc_dimm_unrealize() for memory hot unplug support.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:36 +0800 Tang Chen wrote: > From: Hu Tao > > Implement unrealize function for pc-dimm device. It delete subregion from s/delete/removes/ > hotplug region, and delete ram address range from guest ram list. > > Signed-off-by: Hu Tao > Signed-off-by: Tang Chen > --- >

Re: [Qemu-devel] Serial: possible hang during intensive interaction over the console

2014-09-04 Thread Kirill Batuzov
On Thu, 4 Sep 2014, Andrey Korolyov wrote: > > Thanks, the launch string can be borrowed from attach here: > http://lists.nongnu.org/archive/html/qemu-devel/2014-09/msg00482.html, > the same VM is going under test. > > > By hang I mean stopping ability to send icmp replies, it is like a > kind o

Re: [Qemu-devel] Question about cow format with hexdump

2014-09-04 Thread shhuiw
Sorry to trouble you all. I found the right way: I should use the -o option when I create cow image files. Then hexdump can give full info. ~> touch testcow # maked up backing_file ahead to get non-0s .mtime ~> qemu-img create -f cow -o backing_file=testcow,size=1M dummy Formatti

Re: [Qemu-devel] [PATCH 1/3] net: invoke callback when purging queue

2014-09-04 Thread Stefan Hajnoczi
On Thu, Sep 04, 2014 at 11:39:10AM +0300, Michael S. Tsirkin wrote: > devices rely on packet callbacks eventually running, > but we violate this rule whenever we purge the queue. > To fix, invoke callbacks on all packets on purge. > Set length to 0, this way callers can detect that > this happened

Re: [Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Semion Prihodko
Still don't know how to build/run a simple Hello World kernel on qemu-system-aarch64? Guys, this is a very basic thing, please provide concrete steps. Thanks. 2014-09-04 16:29 GMT+03:00 Peter Maydell : > On 4 September 2014 11:40, Semion Prihodko wrote: > > Hi guys, > > > > Need your help. I t

Re: [Qemu-devel] [PATCH v13 5/6] raw-posix: Add full preallocation option

2014-09-04 Thread Richard W.M. Jones
On Thu, Sep 04, 2014 at 03:17:51PM +0200, Kevin Wolf wrote: > Am 04.09.2014 um 15:07 hat Richard W.M. Jones geschrieben: > > On Thu, Sep 04, 2014 at 02:52:57PM +0200, Kevin Wolf wrote: > > > Am 04.09.2014 um 14:45 hat Richard W.M. Jones geschrieben: > > > > On Thu, Sep 04, 2014 at 02:35:22PM +0200,

Re: [Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Peter Maydell
On 4 September 2014 14:40, Semion Prihodko wrote: > Still don't know how to build/run a simple Hello World kernel on > qemu-system-aarch64? > > Guys, this is a very basic thing, please provide concrete steps. Thanks It's a non-standard use case. The usual use case is "boot Linux", which you can f

Re: [Qemu-devel] [Qemu-ppc] [PATCH 4/5] target-ppc: Handle ibm, nmi-register RTAS call

2014-09-04 Thread Aravinda Prasad
On Thursday 04 September 2014 06:39 PM, Alexander Graf wrote: > > >> Am 04.09.2014 um 10:25 schrieb Aravinda Prasad : >> >> >> >>> On Friday 29 August 2014 03:46 AM, Alexander Graf wrote: >>> >>> On 28.08.14 19:42, Aravinda Prasad wrote: > On Thursday 28 August 2014 02:07 PM,

Re: [Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Peter Maydell
On 4 September 2014 14:49, Semion Prihodko wrote: > Does it mean QEMU emulator is designed to run Linux only? This is not true. No. It means what I said: you can do this, but you're doing something odd and therefore you can't expect that there will be documentation holding your hand every step of

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Stefan Hajnoczi
On Thu, Sep 04, 2014 at 06:07:32AM -0600, Eric Blake wrote: > On 09/04/2014 02:58 AM, Stefan Hajnoczi wrote: > > On-disk structures should be marked packed so the compiler does not > > insert padding for field alignment. Padding should be explicit so > > on-disk layout is obvious and we don't rely

Re: [Qemu-devel] [PATCH] virtio: don't call device on !vm_running

2014-09-04 Thread Stefan Hajnoczi
On Thu, Sep 04, 2014 at 01:32:54PM +0300, Michael S. Tsirkin wrote: > On vm stop, virtio changes vm_running state > too soon, so callbacks can get envoked with > vm_running = false; > > Cc: qemu-sta...@nongnu.org > Cc: Jason Wang > Signed-off-by: Michael S. Tsirkin > --- > hw/virtio/virtio.c |

Re: [Qemu-devel] [RESEND PATCH v3 7/8] pc, acpi bios: Add memory hot unplug interface.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:38 +0800 Tang Chen wrote: > From: Hu Tao > > This patch implements MEMORY_SLOT_EJECT_METHOD according to ACPI spec. > > Signed-off-by: Hu Tao > Signed-off-by: Tang Chen > --- > hw/i386/ssdt-mem.dsl | 5 + > hw/i386/ssdt-misc.dsl| 15 +++

Re: [Qemu-devel] HelloWord kernel for qemu-system-aarch64

2014-09-04 Thread Semion Prihodko
Does it mean QEMU emulator is designed to run Linux only? This is not true. So I ask QEMU developers for help, because they are able to resolve problems to some extent. Please help me guys. Thanks. 2014-09-04 16:44 GMT+03:00 Peter Maydell : > On 4 September 2014 14:40, Semion Prihodko wrote: >

Re: [Qemu-devel] [Important] Query regarding bdrv_co_discard

2014-09-04 Thread Stefan Hajnoczi
On Thu, Sep 04, 2014 at 05:56:53AM -0700, Sanjay Kumar2 wrote: > Output of hdparam is below. Also let me know does network based protocol > supports 'qcow2' format. As my block driver is network based. It is perfectly > working for raw format. When I change the type='qcow2', then it is not > wor

Re: [Qemu-devel] [RESEND PATCH v3 8/8] monitor: Add memory hot unplug support for device_del command.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:39 +0800 Tang Chen wrote: > From: Hu Tao > > Implement find_peripheral_device() to find bus-less device, and call it in > qmp_device_del() so that device_del command will be able to remove memory > device. probably patch should go before 4/8 > > Signed-off-by: Hu Tao

Re: [Qemu-devel] [PATCH] cow: make padding in the header explicit

2014-09-04 Thread Kevin Wolf
Am 04.09.2014 um 15:51 hat Stefan Hajnoczi geschrieben: > On Thu, Sep 04, 2014 at 06:07:32AM -0600, Eric Blake wrote: > > On 09/04/2014 02:58 AM, Stefan Hajnoczi wrote: > > > On-disk structures should be marked packed so the compiler does not > > > insert padding for field alignment. Padding shoul

Re: [Qemu-devel] [PATCH v3 0/4] libqos: add a simple first-fit memory allocator

2014-09-04 Thread Stefan Hajnoczi
On Fri, Aug 01, 2014 at 11:38:55AM -0400, John Snow wrote: > This set collects two patches by Marc Marí already on the mailing list, > but goes further by adding a simple memory allocator that allows us to > track and debug freed memory, and optionally keep track of any leaks. > > For convenience:

Re: [Qemu-devel] [PATCH 4/4] blocksize: add blkconf_blocksize call to all block devices

2014-09-04 Thread Christian Borntraeger
On 03/09/14 17:46, Stefan Hajnoczi wrote: > On Tue, Jul 29, 2014 at 02:27:19PM +0200, Ekaterina Tumanova wrote: >> This patch add the blkconf_blocksize call to all >> devices, which use DEFINE_BLOCK_PROPERTIES. >> If the underlying driver function fails, blkconf_blocksizes >> will set blocksizes to

Re: [Qemu-devel] [RFC][patch 3/6] KVM: s390: Add GISA support

2014-09-04 Thread Heiko Carstens
On Thu, Sep 04, 2014 at 12:52:26PM +0200, frank.blasc...@de.ibm.com wrote: > +void kvm_s390_gisa_register_alert(struct kvm *kvm, u32 gisc) > +{ > + int bito = BITS_PER_BYTE * 7 + gisc; > + > + set_bit(bito ^ (BITS_PER_LONG - 1), &kvm->arch.iam); > +} Just a very minor nit: you could also u

Re: [Qemu-devel] NBD TLS support in QEMU

2014-09-04 Thread Benoît Canet
The Wednesday 03 Sep 2014 à 17:44:17 (+0100), Stefan Hajnoczi wrote : > Hi, > QEMU offers both NBD client and server functionality. The NBD protocol > runs unencrypted, which is a problem when the client and server > communicate over an untrusted network. > > The particular use case that prompted

Re: [Qemu-devel] [RESEND PATCH v3 6/8] acpi: Add hardware implementation for memory hot unplug.

2014-09-04 Thread Igor Mammedov
On Wed, 27 Aug 2014 16:08:37 +0800 Tang Chen wrote: > This patch adds a bool member named "is_removing" to MemStatus indicating if > the memory device is being removed. It is set to true in > acpi_memory_unplug_cb() > when doing memory hot-remove with device_del command, or write an > ACPI_EJECT

Re: [Qemu-devel] [Bug 1358722] Re: latest acpi commits causes memory allocation fault in macosx

2014-09-04 Thread Marco Minetti
On Thu, 2014-09-04 at 09:10 -0400, Gabriel L. Somlo wrote: > On Thu, 04 Sep 2014 08:43:12, Marco Minetti wrote: > > The experiments for running MacOSXon KVM/QEMU I followed are here: > > http://www.contrib.andrew.cmu.edu/~somlo/OSXKVM/ > > > [...] > > > > Bug description: > > qemu release 2.1.

[Qemu-devel] [PATCH v2] xen-hvm.c: Always return -1 when failure occurs in xen_hvm_init()

2014-09-04 Thread Chen Gang
When failure occurs, it need use "return -1" instead of exit(1), so can let upper caller has chance to print failure information, too. For simplify thinking, in xen_hvm_init(), also use '-1' instead of all '-errno', since all related upper callers always exit(1) for failure. It is not a normal fu

  1   2   3   4   >