[Qemu-devel] [PACTH v4 2/6] target-arm: do not set do_interrupt handlers for ARM and AArch64 user modes

2014-09-10 Thread Ard Biesheuvel
From: Rob Herring User mode emulation should never get interrupts and thus should not use the system emulation exception handler function. Remove the reference, and '#ifndef USER_MODE_ONLY' the function itself as well, so that we can add system mode only functionality to it. Signed-off-by: Rob H

[Qemu-devel] [PACTH v4 1/6] target-arm: add powered off cpu state

2014-09-10 Thread Ard Biesheuvel
From: Rob Herring Add tracking of cpu power state in order to support powering off of cores in system emuluation. The initial state is determined by the start-powered-off QOM property. Signed-off-by: Rob Herring Reviewed-by: Peter Maydell Signed-off-by: Ard Biesheuvel --- target-arm/cpu-qom.

[Qemu-devel] [PACTH v4 3/6] target-arm: add hvc and smc exception emulation handling infrastructure

2014-09-10 Thread Ard Biesheuvel
From: Rob Herring Add the infrastructure to handle and emulate hvc and smc exceptions. This will enable emulation of things such as PSCI calls. This commit does not change the behavior and will exit with unknown exception. Signed-off-by: Rob Herring Signed-off-by: Ard Biesheuvel --- target-ar

[Qemu-devel] [PACTH v4 5/6] target-arm: add emulation of PSCI calls for system emulation

2014-09-10 Thread Ard Biesheuvel
From: Rob Herring Add support for handling PSCI calls in system emulation. Both version 0.1 and 0.2 of the PSCI spec are supported. Platforms can enable support by setting the "psci-conduit" QOM property on the cpus to SMC or HVC emulation and having a PSCI binding in their dtb. Signed-off-by: R

[Qemu-devel] [PACTH v4 0/6] ARM: add PSCI 0.2 support in TCG mode

2014-09-10 Thread Ard Biesheuvel
This series adds PSCI support to ARM and AArch64 system emulation when running in TCG mode. As PSCI calls can be made using either hypervisor call (HVC) or secure monitor call (SMC) instructions, support is added for handling those in patch #3 before patch #5 adds the actual PSCI dispatch logic. Pa

[Qemu-devel] [PACTH v4 4/6] target-arm: add missing PSCI constants needed for PSCI emulation

2014-09-10 Thread Ard Biesheuvel
This adds some PSCI function IDs and symbolic return codes that are needed to implement PSCI emulation in TCG mode. Reviewed-by: Peter Maydell Signed-off-by: Ard Biesheuvel --- target-arm/kvm-consts.h | 40 1 file changed, 40 insertions(+) diff --git a/

[Qemu-devel] [PACTH v4 6/6] arm/virt: enable PSCI emulation support for system emulation

2014-09-10 Thread Ard Biesheuvel
From: Rob Herring Now that we have PSCI emulation, enable it for the virt platform. This simplifies the virt machine a bit now that PSCI no longer needs to be a KVM only feature. Signed-off-by: Rob Herring Signed-off-by: Ard Biesheuvel --- hw/arm/virt.c | 82 +++---

Re: [Qemu-devel] [PATCH 0/8] add basic recovery logic to quorum driver

2014-09-10 Thread Liu Yuan
On Sun, Sep 07, 2014 at 05:12:31PM +0200, Benoît Canet wrote: > The Monday 01 Sep 2014 à 15:43:06 (+0800), Liu Yuan wrote : > > This patch set mainly add mainly two logics to implement device recover > > - notify qourum driver of the broken states from the child driver(s) > > - dirty track and sync

Re: [Qemu-devel] [RFC PATCH 0/8] Add Generic PCI host device update

2014-09-10 Thread alvise rigo
Hello Claudio, Unfortunately I'm still not able to reproduce the problem. I suspect though that the issue concerns the way the tests were conducted, so I take this opportunity to ask Rob how many disks you used to test the initial patch series. I used something like: -device lsi53c895a -drive if

Re: [Qemu-devel] [RFC v1 5/6] stm32f205: Add the SoC

2014-09-10 Thread Alistair Francis
On Tue, Sep 9, 2014 at 11:50 PM, Peter Crosthwaite wrote: > On Tue, Sep 9, 2014 at 6:24 PM, Alistair Francis wrote: >> This patch adds the stm32f205 SoC. This will be used by the >> Netduino 2 to create a machine >> >> Signed-off-by: Alistair Francis >> --- >> >> hw/arm/Makefile.objs

Re: [Qemu-devel] [PATCH 0/8] add basic recovery logic to quorum driver

2014-09-10 Thread Liu Yuan
On Wed, Sep 03, 2014 at 12:19:14AM +0200, Benoît Canet wrote: > The Monday 01 Sep 2014 à 15:43:06 (+0800), Liu Yuan wrote : > > Liu, > > Do you think this could work with qcow2 file backed by NFS servers ? It depends on which client we use. If we use Linux NFS client by 'posix file' protocol, I

[Qemu-devel] [RFC PATCH v2] Add HMP command "info memory-devices"

2014-09-10 Thread Zhu Guihua
Provides HMP equivalent of QMP query-memory-devices command. Signed-off-by: Zhu Guihua --- hmp-commands.hx | 2 ++ hmp.c | 43 +++ hmp.h | 1 + monitor.c | 7 +++ 4 files changed, 53 insertions(+) diff --git a/hmp-commands

Re: [Qemu-devel] OVMF, Q35 and USB keyboard/mouse

2014-09-10 Thread Laszlo Ersek
On 09/10/14 08:31, Gerd Hoffmann wrote: > Hi, > >> So at this point I'm wondering why guests and "info qtree" are contradictory, >> and whether the combination of OVMF and OS X tickle some qemu usb emulation >> bug differently than all other (working) combinations ? > > It's due to the way how

[Qemu-devel] [PATCH 03/23] block: Connect BlockBackend to BlockDriverState

2014-09-10 Thread Markus Armbruster
The pointer from BlockBackend to BlockDriverState is a strong reference, managed with bdrv_ref() / bdrv_unref(), the back-pointer is a weak one. Convenience function blk_new_with_bs() creates a BlockBackend with its BlockDriverState. Callers have to unref both. The commit after next will relieve

[Qemu-devel] [PATCH 01/23] block: Split bdrv_new_named() off bdrv_new()

2014-09-10 Thread Markus Armbruster
Creating an anonymous BDS can't fail. Make that obvious. Signed-off-by: Markus Armbruster --- block.c | 26 +++--- block/iscsi.c | 2 +- block/vvfat.c | 2 +- blockdev.c| 2 +- hw/block/xen_disk.c | 2 +- include/block/block.h

[Qemu-devel] [PATCH 10/23] block: Eliminate DriveInfo member bdrv, use blk_by_legacy_dinfo()

2014-09-10 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- blockdev.c | 3 +-- hw/arm/collie.c | 9 + hw/arm/gumstix.c | 5 +++-- hw/arm/mainstone.c | 8 hw/arm/musicpal.c|

[Qemu-devel] [PATCH 09/23] block: Merge BlockBackend and BlockDriverState name spaces

2014-09-10 Thread Markus Armbruster
BlockBackend's name space is separate only to keep the patches simple. Time to merge the two. Signed-off-by: Markus Armbruster --- block.c | 11 +++ block/block-backend.c | 10 +- 2 files changed, 8 insertions(+), 13 deletions(-) diff --git a/block.c b/block.c inde

[Qemu-devel] [PATCH 06/23] block: Eliminate bdrv_states, use block_next() instead

2014-09-10 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- block.c | 43 +++ block/block-backend.c | 4 include/block/block_int.h | 2 -- 3 files changed, 23 insertions(+), 26 deletions(-) diff --git a/block.c b/block.c index a6c03da..89f9cf0 100644

[Qemu-devel] [PATCH 07/23] block: Eliminate bdrv_iterate(), use bdrv_next()

2014-09-10 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- block-migration.c | 30 +++--- block.c | 9 - blockdev.c| 31 +-- include/block/block.h | 2 -- monitor.c | 33 + 5 files ch

[Qemu-devel] [PATCH 23/23] block: Make device model's references to BlockBackend strong

2014-09-10 Thread Markus Armbruster
Doesn't make a difference just yet, but it's the right thing to do. Signed-off-by: Markus Armbruster --- block/block-backend.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/block/block-backend.c b/block/block-backend.c index 6c0c8f2..7ad4e44 100644 --- a/block/block-back

[Qemu-devel] [PATCH 08/23] block: Eliminate BlockDriverState member device_name[]

2014-09-10 Thread Markus Armbruster
device_name[] is can become non-empty only in bdrv_new_named() and bdrv_move_feature_fields(). The latter is used only to undo damage done by bdrv_swap(). The former is called only by blk_new_with_bs(). Therefore, when a BlockDriverState's device_name[] is non-empty, then it's owned by a BlockBac

[Qemu-devel] [PATCH 00/23] Split BlockBackend off BDS with an axe

2014-09-10 Thread Markus Armbruster
My last attempt got bogged down because I tried to do a reasonably complete job, and the complexity proved more than I could handle with the limited amount of uninterrupted time available. This time, I'm cutting BlockBackend off with an axe, leaving most of the work for later. Done in this series

[Qemu-devel] [PATCH 21/23] blockdev: Convert qmp_eject(), qmp_change_blockdev() to BlockBackend

2014-09-10 Thread Markus Armbruster
Much more command code needs conversion. I'm converting these now because they's using bdrv_dev_* functions, which I'm about to lift into BlockBackend. Signed-off-by: Markus Armbruster --- blockdev.c | 20 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/block

[Qemu-devel] [PATCH 04/23] block: Connect BlockBackend and DriveInfo

2014-09-10 Thread Markus Armbruster
Make the BlockBackend own the DriveInfo. Change blockdev_init() to return the BlockBackend instead of the DriveInfo. Signed-off-by: Markus Armbruster --- block/block-backend.c | 38 +++ blockdev.c| 79 +-- inclu

[Qemu-devel] [PATCH 20/23] block/qapi: Convert qmp_query_block() to BlockBackend

2014-09-10 Thread Markus Armbruster
Much more command code needs conversion. I start with this one because it's using bdrv_dev_* functions, which I'm about to lift into BlockBackend. While there, give bdrv_query_info() internal linkage. Signed-off-by: Markus Armbruster --- block/qapi.c | 15 --- include/block

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Nikunj A Dadhania
Greg Kurz writes: > On Mon, 8 Sep 2014 19:05:02 +0300 > "Michael S. Tsirkin" wrote: > >> commit cc943c36faa192cd4b32af8fe5edb31894017d35 >> pci: Use bus master address space for delivering MSI/MSI-X messages >> breaks virtio-net for rhel6.[56] x86 guests because they don't >> enable bus mast

[Qemu-devel] [PATCH 02/23] block: New BlockBackend

2014-09-10 Thread Markus Armbruster
A block device consists of a frontend device model and a backend. A block backend has a tree of block drivers doing the actual work. The tree is managed by the block layer. We currently use a single abstraction BlockDriverState both for tree nodes and the backend as a whole. Drawbacks: * Its AP

[Qemu-devel] [PATCH 12/23] virtio-blk: Drop redundant VirtIOBlock member conf

2014-09-10 Thread Markus Armbruster
Commit 12c5674 turned it into a pointer to member blk.conf. Signed-off-by: Markus Armbruster --- hw/block/virtio-blk.c | 28 ++-- include/hw/virtio/virtio-blk.h | 1 - 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/hw/block/virtio-blk.c b/hw/bl

[Qemu-devel] [PATCH 16/23] pc87312: Drop unused members of PC87312State

2014-09-10 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- include/hw/isa/pc87312.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/include/hw/isa/pc87312.h b/include/hw/isa/pc87312.h index befc8bd..bf74470 100644 --- a/include/hw/isa/pc87312.h +++ b/include/hw/isa/pc87312.h @@ -47,13 +47,10 @@ typedef struct PC

[Qemu-devel] [PATCH 15/23] ide: Complete conversion from BlockDriverState to BlockBackend

2014-09-10 Thread Markus Armbruster
Add a BlockBackend member to TrimAIOCB, so ide_issue_trim_cb() can use blk_aio_discard() instead of bdrv_aio_discard(). Signed-off-by: Markus Armbruster --- hw/ide/core.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/ide/core.c b/hw/ide/core.c index fe12145..c043db

[Qemu-devel] [PATCH 05/23] block: Make BlockBackend own its BlockDriverState

2014-09-10 Thread Markus Armbruster
On BlockBackend destruction, unref its BlockDriverState. Replaces the callers' unrefs. Signed-off-by: Markus Armbruster --- block/block-backend.c | 9 ++--- blockdev.c| 11 +++ hw/block/xen_disk.c | 6 +++--- qemu-img.c| 35 +--

[Qemu-devel] [PATCH 19/23] blockdev: Drop DriveInfo member enable_auto_del

2014-09-10 Thread Markus Armbruster
Commit 2d246f0 introduced DriveInfo member enable_auto_del to distinguish DriveInfo created via drive_new() from DriveInfo created via qmp_blockdev_add(). The latter no longer exist. Drop enable_auto_del. Signed-off-by: Markus Armbruster --- blockdev.c| 7 ++- include/sysem

[Qemu-devel] [PATCH 13/23] virtio-blk: Rename VirtIOBlkConf variables to conf

2014-09-10 Thread Markus Armbruster
This is consistent with how VirtIOFOOConf variables are named elsewhere, and makes blk available for BlockBackend variables. Signed-off-by: Markus Armbruster --- hw/block/dataplane/virtio-blk.c | 33 +- hw/block/dataplane/virtio-blk.h | 2 +- hw/block/virtio-blk.c

[Qemu-devel] [PATCH 17/23] blockdev: Drop superfluous DriveInfo member id

2014-09-10 Thread Markus Armbruster
Signed-off-by: Markus Armbruster --- block/block-backend.c | 1 - blockdev.c| 3 +-- include/sysemu/blockdev.h | 1 - 3 files changed, 1 insertion(+), 4 deletions(-) diff --git a/block/block-backend.c b/block/block-backend.c index cc21f3c..1bac033 100644 --- a/block/block-bac

[Qemu-devel] [PATCH 18/23] blockdev: Fix blockdev-add not to create IDE drive (0, 0)

2014-09-10 Thread Markus Armbruster
blockdev_init() always creates a DriveInfo, but only drive_new() fills it in. qmp_blockdev_add() leaves it blank. This results in a drive with type = IF_IDE, bus = 0, unit = 0. Screwed up in commit ee13ed1c. Board initialization code looking for IDE drive (0,0) can pick up one of these bogus dr

Re: [Qemu-devel] [PATCH v5 05/22] block: Convert bdrv_em_aiocb_info.cancel to .cancel_async

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 07:59, Fam Zheng ha scritto: > @@ -4679,6 +4679,9 @@ static void bdrv_aio_cancel_em(BlockDriverAIOCB > *blockacb) > { > BlockDriverAIOCBSync *acb = > container_of(blockacb, BlockDriverAIOCBSync, common); > + > +acb->ret = -ECANCELED; > +acb->common.cb(acb->comm

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 01:44:49PM +0530, Nikunj A Dadhania wrote: > Greg Kurz writes: > > > On Mon, 8 Sep 2014 19:05:02 +0300 > > "Michael S. Tsirkin" wrote: > > > >> commit cc943c36faa192cd4b32af8fe5edb31894017d35 > >> pci: Use bus master address space for delivering MSI/MSI-X messages > >

[Qemu-devel] [PATCH 22/23] block: Lift device model API into BlockBackend

2014-09-10 Thread Markus Armbruster
Move device model attachment / detachment and the BlockDevOps device model callbacks and their wrappers from BlockDriverState to BlockBackend. Signed-off-by: Markus Armbruster --- block.c| 126 + block/block-backend.c | 107

[Qemu-devel] [PATCH 11/23] block: Rename BlockDriverAIOCB* to BlockAIOCB*

2014-09-10 Thread Markus Armbruster
I'll use BlockDriverAIOCB with block backends shortly, and the name is going to fit badly there. It's a block layer thing anyway, not just a block driver thing. Signed-off-by: Markus Armbruster --- block-migration.c | 2 +- block.c | 151 ++---

Re: [Qemu-devel] [PATCH v1 1/2] block/archipelago: Implement bdrv_truncate()

2014-09-10 Thread Chrysostomos Nanakos
On 09/10/2014 11:20 AM, Kevin Wolf wrote: Am 09.09.2014 um 19:38 hat Chrysostomos Nanakos geschrieben: Signed-off-by: Chrysostomos Nanakos --- block/archipelago.c | 63 +-- 1 file changed, 61 insertions(+), 2 deletions(-) Thanks, applied all

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 12:35:32AM +0200, Greg Kurz wrote: > On Mon, 8 Sep 2014 19:05:02 +0300 > "Michael S. Tsirkin" wrote: > > > commit cc943c36faa192cd4b32af8fe5edb31894017d35 > > pci: Use bus master address space for delivering MSI/MSI-X messages > > breaks virtio-net for rhel6.[56] x86 g

Re: [Qemu-devel] [PATCH v1 1/2] block/archipelago: Implement bdrv_truncate()

2014-09-10 Thread Kevin Wolf
Am 09.09.2014 um 19:38 hat Chrysostomos Nanakos geschrieben: > Signed-off-by: Chrysostomos Nanakos > --- > block/archipelago.c | 63 > +-- > 1 file changed, 61 insertions(+), 2 deletions(-) Thanks, applied all to the block branch. Can you pleas

Re: [Qemu-devel] [PATCH 0/3] build-sys: Exclude empty object files when linking libqemuutil.a

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 08:19, Fam Zheng ha scritto: > Paolo, > > Since Stefan reviewed the first patch, would you apply this series? Yes, pull request coming soon. Paolo

Re: [Qemu-devel] [PATCH v1 1/2] block/archipelago: Implement bdrv_truncate()

2014-09-10 Thread Kevin Wolf
Am 10.09.2014 um 10:25 hat Chrysostomos Nanakos geschrieben: > On 09/10/2014 11:20 AM, Kevin Wolf wrote: > >Am 09.09.2014 um 19:38 hat Chrysostomos Nanakos geschrieben: > >>Signed-off-by: Chrysostomos Nanakos > >>--- > >> block/archipelago.c | 63 > >> ++

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Paolo Bonzini
Il 09/09/2014 22:51, Michael S. Tsirkin ha scritto: > > i440FX/PIIX3 state is loaded before i8259, so the interrupt will never > > be in the i8259 ISR. I am not sure why it is a problem for > > record/replay, but I think it's plausible to consider this a bug. i8259 > > state should not be affecte

[Qemu-devel] [RESEND RFC PATCH v2] Add HMP command "info memory-devices"

2014-09-10 Thread Zhu Guihua
This patch provides HMP equivalent of QMP query-memory-devices command. By this command "info memory-devices", user can know all information about hotpluggable memmory device such as id. With id of devices, hot removing hotpluggable memory devices becomes possible by command 'device_del'. Chang

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Peter Maydell
On 10 September 2014 09:38, Paolo Bonzini wrote: > Il 09/09/2014 22:51, Michael S. Tsirkin ha scritto: >> Sorry I still don't understand. Why do stuff from vmstate callback then? >> How is it different? > > Reconstructing internal state from post_load is okay. > > What is not okay (and I think it

Re: [Qemu-devel] [PATCH] block: Make op blockers recursive

2014-09-10 Thread Fam Zheng
On Thu, 09/04 21:42, Stefan Hajnoczi wrote: > On Tue, Aug 26, 2014 at 06:45:54AM +, Benoît Canet wrote: > > On Tue, Aug 26, 2014 at 12:42:04PM +0800, Fam Zheng wrote: > > > On Mon, 08/25 12:12, Benoît Canet wrote: > > > > On Mon, Aug 25, 2014 at 05:37:37PM +0800, Fam Zheng wrote: > > > > > On M

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Greg Kurz
On Wed, 10 Sep 2014 13:44:49 +0530 Nikunj A Dadhania wrote: > Greg Kurz writes: > > > On Mon, 8 Sep 2014 19:05:02 +0300 > > "Michael S. Tsirkin" wrote: > > > >> commit cc943c36faa192cd4b32af8fe5edb31894017d35 > >> pci: Use bus master address space for delivering MSI/MSI-X messages > >> brea

Re: [Qemu-devel] ballooning not working on hotplugged pc-dimm

2014-09-10 Thread zhanghailiang
On 2014/9/9 11:05, Alexandre DERUMIER wrote: Hello, I was playing with pc-dimm hotplug, and I notice that balloning is not working on memory space of pc-dimm devices. example: qemu -m size=1024,slots=255,maxmem=15000M #free -m : 1024M -> qmp balloon 512M #free -m : 512M -> hotplug pc-dimm

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Greg Kurz
On Wed, 10 Sep 2014 12:32:30 +0300 "Michael S. Tsirkin" wrote: > On Wed, Sep 10, 2014 at 01:44:49PM +0530, Nikunj A Dadhania wrote: > > Greg Kurz writes: > > > > > On Mon, 8 Sep 2014 19:05:02 +0300 > > > "Michael S. Tsirkin" wrote: > > > > > >> commit cc943c36faa192cd4b32af8fe5edb31894017d35 >

Re: [Qemu-devel] [PATCH] Fix typos and misspellings in comments

2014-09-10 Thread zhanghailiang
On 2014/9/9 21:43, Andreas Färber wrote: Am 09.09.2014 10:09, schrieb Peter Maydell: On 9 September 2014 04:23, zhanghailiang wrote: diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 2ab4460..bedef2f 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -541,7 +541,7 @@ static void *spapr_creat

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 10:51, Peter Maydell ha scritto: > > What is not okay (and I think it should be a rule) is to touch other > > devices from post_load, unless you know that they are deserialized > > first. For example it's okay for a PCI device to talk to the parent > > bridge in its post_load functio

Re: [Qemu-devel] [PATCH 1/6] hw/arm/virt: Provide flash devices for boot ROMs

2014-09-10 Thread Ard Biesheuvel
On 9 September 2014 20:20, Peter Maydell wrote: > On 5 September 2014 16:15, Ard Biesheuvel wrote: >> From: Peter Maydell >> >> Add two flash devices to the virt board, so that it can be used for >> running guests which want a bootrom image such as UEFI. We provide >> two flash devices to make i

Re: [Qemu-devel] [PATCH v5 00/22] block: Asynchronous request cancellation

2014-09-10 Thread Bin Wu
On 2014/9/10 13:59, Fam Zheng wrote: v5: Fix IDE callback. (Paolo) Fix blkdebug. (Paolo) Drop the DMA fix which is independent of this series. (Paolo) Incorperate Yuan's patch on quorum_aio_cancel. (Benoît) Commit message wording fix. (Benoît) Rename qemu_aio_release to q

Re: [Qemu-devel] [PATCH v7 RESEND 4/8] memory: add parameter errp to memory_region_init_rom_device

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 04:05, Hu Tao ha scritto: >> > >> > Better not use error_abort if we can avoid it, and here it's particularly >> > easy... > Is error_abort deprecated? No, not at at all. It is useful whenever you know that an error cannot happen. However, if it makes sense and it is easy, error p

[Qemu-devel] [PATCH v15 1/5] block: round up file size to nearest sector

2014-09-10 Thread Hu Tao
Currently the file size requested by user is rounded down to nearest sector, causing the actual file size could be a bit less than the size user requested. Since some formats (like qcow2) record virtual disk size in bytes, this can make the last few bytes cannot be accessed. This patch fixes it by

[Qemu-devel] [PATCH v15 5/5] qcow2: Add falloc and full preallocation option

2014-09-10 Thread Hu Tao
preallocation=falloc allocates disk space by posix_fallocate(), preallocation=full allocates disk space by writing zeros to disk. Both modes imply preallocation=metadata. Signed-off-by: Hu Tao Reviewed-by: Max Reitz --- block/qcow2.c | 63 ++-

[Qemu-devel] [PATCH v15 4/5] raw-posix: Add falloc and full preallocation option

2014-09-10 Thread Hu Tao
This patch adds a new option preallocation for raw format, and implements falloc and full preallocation. Signed-off-by: Hu Tao Reviewed-by: Max Reitz --- block/raw-posix.c | 92 +++ qemu-doc.texi | 9 ++ qemu-img.texi | 9 ++

Re: [Qemu-devel] [PATCH v3] dump: let dump_error return error info to caller

2014-09-10 Thread zhanghailiang
On 2014/9/9 23:10, Eric Blake wrote: On 09/03/2014 03:54 AM, zhanghailiang wrote: The second parameter of dump_error is unused, but one purpose of using this function is to report the error info. Use error_set to return the error info to the caller. Signed-off-by: zhanghailiang --- V3: - Dro

[Qemu-devel] [PATCH v15 0/5] qcow2, raw: add preallocation=full and preallocation=falloc

2014-09-10 Thread Hu Tao
This series adds two preallocation mode to qcow2 and raw: Option preallocation=full preallocates disk space for image by writing zeros to disk, this ensures disk space in any cases. Option preallocation=falloc preallocates disk space by calling posix_fallocate(). This is faster than preallocation

[Qemu-devel] [PATCH v15 3/5] qapi: introduce PreallocMode and new PreallocModes full and falloc.

2014-09-10 Thread Hu Tao
This patch prepares for the subsequent patches. Signed-off-by: Hu Tao Reviewed-by: Max Reitz Reviewed-by: Kevin Wolf Reviewed-by: Eric Blake --- block/qcow2.c | 28 ++-- qapi/block-core.json | 17 + tests/qemu-iotests/049.out | 2 +-

[Qemu-devel] [PATCH v15 2/5] block: don't convert file size to sector size

2014-09-10 Thread Hu Tao
and avoid converting it back later. Signed-off-by: Hu Tao Reviewed-by: Max Reitz Reviewed-by: Benoît Canet --- block/gluster.c | 9 - block/qcow.c | 8 block/qcow2.c | 10 +- block/raw-posix.c | 12 ++-- block/raw-win32.c | 6 +++--- 5 files chang

Re: [Qemu-devel] [Qemu-ppc] [PATCH 1/3] target-ppc : Add floating point ability to 440x5 PPC CPU

2014-09-10 Thread Alexander Graf
On 10.09.14 07:03, Pierre Mallard wrote: > This patch add some floating point operation for PPC440x5. > Compile with PPC440x5_HAVE_FPU enabled in configure extra-cflags > > Signed-off-by: Pierre Mallard Instead of the define, could we just create a new CPU that has these flags enabled? Just ca

Re: [Qemu-devel] [PATCH 1/6] hw/arm/virt: Provide flash devices for boot ROMs

2014-09-10 Thread Peter Maydell
On 10 September 2014 10:09, Ard Biesheuvel wrote: > On 9 September 2014 20:20, Peter Maydell wrote: >> There were previously questions about whether we should >> have flash or RAM at the bottom, but I think it makes >> sense just to have a "like vexpress" config with two >> flash devices. This do

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Nikunj A Dadhania
Greg Kurz writes: >> > > I did some debugging: it looks like the guest kernel calls the OF >> > > quisece call to flush pending DMA and disables bus master on the >> > > virtio-blk device (PCI_COMMAND == 0x3). >> > >> > Getting confused, above you are talking about virtio-net and here it is >> >

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Nikunj A Dadhania
"Michael S. Tsirkin" writes: > On Wed, Sep 10, 2014 at 01:44:49PM +0530, Nikunj A Dadhania wrote: >> Greg Kurz writes: >> >> > On Mon, 8 Sep 2014 19:05:02 +0300 >> > "Michael S. Tsirkin" wrote: >> > >> >> commit cc943c36faa192cd4b32af8fe5edb31894017d35 >> >> pci: Use bus master address spa

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 11:05:39AM +0200, Paolo Bonzini wrote: > Il 10/09/2014 10:51, Peter Maydell ha scritto: > > > What is not okay (and I think it should be a rule) is to touch other > > > devices from post_load, unless you know that they are deserialized > > > first. For example it's okay for

Re: [Qemu-devel] [Qemu-ppc] [PATCH 0/3] Enabling floating point instruction to 440x5 CPUs

2014-09-10 Thread Alexander Graf
On 10.09.14 07:03, Pierre Mallard wrote: > This patch series enable floating point instruction in 440x5 CPUs > which have the capabilities to have optional APU FPU. > > 1) Add floating point standard insns flag to 440x5 in case there is an apu > fpu. > 2) Define a new floating point insns flag

Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/3] target-ppc : Add PPC_FLOAT_64 flag to instructions type

2014-09-10 Thread Alexander Graf
On 10.09.14 07:03, Pierre Mallard wrote: > This patch declare a new floating point instruction flag PPC_FLOAT_64 to be > used > by fcfid, fctid[z] operations. Note that due to limited number of bit, > FSEL and FRES points now to same value, and PPC_FLOAT_64 to former FSEL > value. > (There se

Re: [Qemu-devel] [PATCH v5 00/22] block: Asynchronous request cancellation

2014-09-10 Thread Fam Zheng
On Wed, 09/10 17:09, Bin Wu wrote: > On 2014/9/10 13:59, Fam Zheng wrote: > >v5: Fix IDE callback. (Paolo) > > Fix blkdebug. (Paolo) > > Drop the DMA fix which is independent of this series. (Paolo) > > Incorperate Yuan's patch on quorum_aio_cancel. (Benoît) > > Commit message wordi

Re: [Qemu-devel] [Qemu-ppc] [PATCH 3/3] target-ppc : Add PPC_FLOAT_64 type to fctid, fctidz and fcfid and remove their TARGET_PPC64 restriction

2014-09-10 Thread Alexander Graf
On 10.09.14 07:03, Pierre Mallard wrote: > Apply the new PPC_FLOAT_64 flag to fctid[z] and fcfid. > May also be applyed to fctidu[z] and fcfid[su][z], but since they are not > mentionned in xilinx documentation it might not be needed yet. > > Signed-off-by: Pierre Mallard > --- > target-ppc/

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Alexander Graf
On 09.09.14 17:59, Paolo Bonzini wrote: > Il 09/09/2014 17:25, Eric Auger ha scritto: Please provide a wrapper like sysbus_register_dynamic that takes the params/address_space_mem/mpic as parameter. platform_bus_init_notify and DynSysbusNotifier can remain hidden within the .

Re: [Qemu-devel] [PATCH v5 05/22] block: Convert bdrv_em_aiocb_info.cancel to .cancel_async

2014-09-10 Thread Fam Zheng
On Wed, 09/10 10:20, Paolo Bonzini wrote: > Il 10/09/2014 07:59, Fam Zheng ha scritto: > > @@ -4679,6 +4679,9 @@ static void bdrv_aio_cancel_em(BlockDriverAIOCB > > *blockacb) > > { > > BlockDriverAIOCBSync *acb = > > container_of(blockacb, BlockDriverAIOCBSync, common); > > + > > +

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 11:31, Alexander Graf ha scritto: >> > Yeah, please do the registration in sysbus.c, not in virt.c. There is >> > no reason to make the platform_bus_init_notify+DynSysbusNotifier >> > interface public. The code in sysbus.c can fill in the fields. > Sysbus != Platform bus. Sysbus is

Re: [Qemu-devel] [PATCH v5 05/22] block: Convert bdrv_em_aiocb_info.cancel to .cancel_async

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 11:36, Fam Zheng ha scritto: >> > >> > This could call the callback before I/O is finished. I/O can then >> > complete and write to disk stuff that was not meant to be written. > I think the request is already completed when bdrv_aio_rw_vector returns this > blockacb. I shouldn't ov

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 10:38:46AM +0200, Paolo Bonzini wrote: > Il 09/09/2014 22:51, Michael S. Tsirkin ha scritto: > > > i440FX/PIIX3 state is loaded before i8259, so the interrupt will never > > > be in the i8259 ISR. I am not sure why it is a problem for > > > record/replay, but I think it's p

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 02:45:51PM +0530, Nikunj A Dadhania wrote: > "Michael S. Tsirkin" writes: > > > On Wed, Sep 10, 2014 at 01:44:49PM +0530, Nikunj A Dadhania wrote: > >> Greg Kurz writes: > >> > >> > On Mon, 8 Sep 2014 19:05:02 +0300 > >> > "Michael S. Tsirkin" wrote: > >> > > >> >> comm

Re: [Qemu-devel] [PATCH 02/23] block: New BlockBackend

2014-09-10 Thread Kevin Wolf
Am 10.09.2014 um 10:13 hat Markus Armbruster geschrieben: > A block device consists of a frontend device model and a backend. > > A block backend has a tree of block drivers doing the actual work. > The tree is managed by the block layer. > > We currently use a single abstraction BlockDriverState

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Alexander Graf
On 10.09.14 11:43, Paolo Bonzini wrote: > Il 10/09/2014 11:31, Alexander Graf ha scritto: Yeah, please do the registration in sysbus.c, not in virt.c. There is no reason to make the platform_bus_init_notify+DynSysbusNotifier interface public. The code in sysbus.c can fill in the

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 12:50, Michael S. Tsirkin ha scritto: > OK, got this, thanks for the explanation! > So the reason i8259 might be out of sync is > because it's not yet deserialized. Yes, especially the IMR/IRR/ISR fields. > I think it's a good idea to put (at least the > last part) in the commit log

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 11:58:34AM +0200, Paolo Bonzini wrote: > Il 10/09/2014 12:50, Michael S. Tsirkin ha scritto: > > OK, got this, thanks for the explanation! > > So the reason i8259 might be out of sync is > > because it's not yet deserialized. > > Yes, especially the IMR/IRR/ISR fields. > >

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 11:56, Alexander Graf ha scritto: > > > On 10.09.14 11:43, Paolo Bonzini wrote: >> Il 10/09/2014 11:31, Alexander Graf ha scritto: > Yeah, please do the registration in sysbus.c, not in virt.c. There is > no reason to make the platform_bus_init_notify+DynSysbusNotifier

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 13:04, Michael S. Tsirkin ha scritto: >> > This patch disables raising an irq while loading the state of PCI >> > bridge. >> > Because the i8259 has not been deserialized yet, raising an interrupt >> > could bring the system out-of-sync with the migration source. For >>

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 11:56, Alexander Graf ha scritto: > > > On 10.09.14 11:43, Paolo Bonzini wrote: >> Il 10/09/2014 11:31, Alexander Graf ha scritto: > Yeah, please do the registration in sysbus.c, not in virt.c. There is > no reason to make the platform_bus_init_notify+DynSysbusNotifier

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Alexander Graf
On 10.09.14 12:05, Paolo Bonzini wrote: > Il 10/09/2014 11:56, Alexander Graf ha scritto: >> >> >> On 10.09.14 11:43, Paolo Bonzini wrote: >>> Il 10/09/2014 11:31, Alexander Graf ha scritto: >> Yeah, please do the registration in sysbus.c, not in virt.c. There is >> no reason to make the

Re: [Qemu-devel] [PATCH 05/23] block: Make BlockBackend own its BlockDriverState

2014-09-10 Thread Kevin Wolf
Am 10.09.2014 um 10:13 hat Markus Armbruster geschrieben: > On BlockBackend destruction, unref its BlockDriverState. Replaces the > callers' unrefs. > > Signed-off-by: Markus Armbruster > --- > block/block-backend.c | 9 ++--- > blockdev.c| 11 +++ > hw/block/xen_disk.c

Re: [Qemu-devel] [PATCH 08/10] pckbd: adding new fields to vmstate

2014-09-10 Thread Paolo Bonzini
Il 09/09/2014 15:07, Juan Quintela ha scritto: > Paolo Bonzini wrote: >> From: Pavel Dovgalyuk >> >> This patch adds outport to VMState to allow correct saving and restoring >> the state of PC keyboard controller. >> >> Signed-off-by: Pavel Dovgalyuk >> Signed-off-by: Paolo Bonzini > > Acked-b

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 12:09, Alexander Graf ha scritto: > Fair enough. > > As far as moving "platform bus" logic into sysbus, I'd really like to > hold back and see what this whole thing ends up getting used for first. > > So for now, I'd definitely prefer to keep "platform bus" logic and > "sysbus" logi

Re: [Qemu-devel] [PATCH 09/10] piix: do not raise irq while loading vmstate

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 12:07:22PM +0200, Paolo Bonzini wrote: > Il 10/09/2014 13:04, Michael S. Tsirkin ha scritto: > >> > This patch disables raising an irq while loading the state of PCI > >> > bridge. > >> > Because the i8259 has not been deserialized yet, raising an interrupt > >> >

Re: [Qemu-devel] [PATCH] virtio-pci: enable bus master for old guests

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 11:01:48AM +0200, Greg Kurz wrote: > On Wed, 10 Sep 2014 12:32:30 +0300 > "Michael S. Tsirkin" wrote: > > > On Wed, Sep 10, 2014 at 01:44:49PM +0530, Nikunj A Dadhania wrote: > > > Greg Kurz writes: > > > > > > > On Mon, 8 Sep 2014 19:05:02 +0300 > > > > "Michael S. Tsir

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Alexander Graf
On 10.09.14 12:21, Paolo Bonzini wrote: > Il 10/09/2014 12:09, Alexander Graf ha scritto: >> Fair enough. >> >> As far as moving "platform bus" logic into sysbus, I'd really like to >> hold back and see what this whole thing ends up getting used for first. >> >> So for now, I'd definitely prefer

Re: [Qemu-devel] [PATCH 1/6] hw/arm/virt: Provide flash devices for boot ROMs

2014-09-10 Thread Ard Biesheuvel
On 10 September 2014 11:12, Peter Maydell wrote: > On 10 September 2014 10:09, Ard Biesheuvel wrote: >> On 9 September 2014 20:20, Peter Maydell wrote: >>> There were previously questions about whether we should >>> have flash or RAM at the bottom, but I think it makes >>> sense just to have a "

Re: [Qemu-devel] [PATCH v3 1/6] hw/misc/dyn_sysbus_binding: helpers for sysbus device dynamic binding

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 12:26, Alexander Graf ha scritto: > > It's not even clear to me that E500 CCSR devices should be sysbus, in > > fact... > > The problem if you continue that thought process is that we'd end up > with 500 different buses and 500 different uart boilerplate devices just > to fit into the

Re: [Qemu-devel] [PATCH 07/10] serial: fixing vmstate for save/restore

2014-09-10 Thread Paolo Bonzini
Il 09/09/2014 14:30, Paolo Bonzini ha scritto: > From: Pavel Dovgalyuk > > Some fields were added to VMState by this patch to preserve correct > loading of the serial port controller state. > Updating FCR value while loading was also modified to disable generating > an interrupt by loadvm. This

Re: [Qemu-devel] [PATCH] hw/arm/virt: fix pl011 and pl031 irq flags

2014-09-10 Thread Christoffer Dall
On Tue, Sep 09, 2014 at 03:53:43PM +0100, Peter Maydell wrote: > The pl011 and pl031 devices both use level triggered interrupts, > but the device tree we construct was incorrectly telling the > kernel to configure the GIC to treat them as edge triggered. > This meant that output from the pl011 wou

Re: [Qemu-devel] [PATCH] hw/arm/virt: fix pl011 and pl031 irq flags

2014-09-10 Thread Ard Biesheuvel
On 10 September 2014 12:43, Christoffer Dall wrote: > On Tue, Sep 09, 2014 at 03:53:43PM +0100, Peter Maydell wrote: >> The pl011 and pl031 devices both use level triggered interrupts, >> but the device tree we construct was incorrectly telling the >> kernel to configure the GIC to treat them as e

Re: [Qemu-devel] [PATCH 00/10] x86: migrate more data

2014-09-10 Thread Paolo Bonzini
Il 09/09/2014 14:29, Paolo Bonzini ha scritto: > Juan, David, Amit, here are Pavel's fixes for x86 migration. > Please help applying them, or ack them so that I can merge > them through the KVM tree. > > Thanks, > > Paolo > > Paolo Bonzini (1): > vl: use QLIST_FOREACH_SAFE to visit change stat

Re: [Qemu-devel] [PATCH 00/10] x86: migrate more data

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 12:50:35PM +0200, Paolo Bonzini wrote: > Il 09/09/2014 14:29, Paolo Bonzini ha scritto: > > Juan, David, Amit, here are Pavel's fixes for x86 migration. > > Please help applying them, or ack them so that I can merge > > them through the KVM tree. > > > > Thanks, > > > > Pa

Re: [Qemu-devel] [RFC v1 2/6] stm32f205_USART: Add the stm32f205 SoC USART Controller

2014-09-10 Thread Alistair Francis
On Tue, Sep 9, 2014 at 11:21 PM, Peter Crosthwaite wrote: > On Tue, Sep 9, 2014 at 6:24 PM, Alistair Francis wrote: >> This patch adds the stm32f205 USART controller >> (UART also uses the same controller). >> >> Signed-off-by: Alistair Francis >> --- >> V2: >> - Small changes thanks to Peter C

  1   2   3   4   >