[Qemu-devel] [PULL v2 1/8] console: add qemu_pixelformat_from_pixman

2014-09-10 Thread Gerd Hoffmann
Function to convert pixman format codes to qemu PixelFormat. [ Benjamin Herrenschmidt: fix BGRA+RGBA shifts ] Signed-off-by: Gerd Hoffmann --- include/ui/qemu-pixman.h | 1 + ui/qemu-pixman.c | 56 2 files changed, 57 insertions(+) diff

[Qemu-devel] [PULL v2 2/8] console: add qemu_default_pixman_format

2014-09-10 Thread Gerd Hoffmann
Function returning the default pixman format for a given depth. Signed-off-by: Gerd Hoffmann --- include/ui/qemu-pixman.h | 1 + ui/qemu-pixman.c | 25 + 2 files changed, 26 insertions(+) diff --git a/include/ui/qemu-pixman.h b/include/ui/qemu-pixman.h index 090

[Qemu-devel] [PULL v2 5/8] console: add qemu_create_displaysurface_guestmem

2014-09-10 Thread Gerd Hoffmann
This patch adds a qemu_create_displaysurface_guestmem helper function. Works simliar to qemu_create_displaysurface_from, but accepts a guest address instead of a host pointer and it handles cpu_physical_memory_{map,unmap} for you. Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 4

[Qemu-devel] [PULL v2 0/8] console: pixman conversion continued

2014-09-10 Thread Gerd Hoffmann
Hi, This patch series makes the console code use pixman format codes internally. It also adds some helper functions for gfx emulation code. I have some wip patches for pl110 using them, but they are not ready yet so they are not included in this pull req. v2: added missing signed-off-by plea

[Qemu-devel] [PULL v2 3/8] console: reimplement qemu_default_pixelformat

2014-09-10 Thread Gerd Hoffmann
Use the new qemu_pixelformat_from_pixman and qemu_default_pixman_format functions to reimplement qemu_default_pixelformat (qemu_different_endianness_pixelformat too). Signed-off-by: Gerd Hoffmann --- ui/console.c | 117 ++- 1 file changed,

[Qemu-devel] [PULL v2 7/8] console: add qemu_pixman_linebuf_copy

2014-09-10 Thread Gerd Hoffmann
Helper function for copying data from linebuf to framebuffer using pixman, possibly converting in case src and dst formats differ. Signed-off-by: Gerd Hoffmann --- include/ui/qemu-pixman.h | 2 ++ ui/qemu-pixman.c | 9 + 2 files changed, 11 insertions(+) diff --git a/include/ui/

[Qemu-devel] [PULL v2 6/8] console: add dpy_gfx_update_dirty

2014-09-10 Thread Gerd Hoffmann
Calls dpy_gfx_update for all dirty scanlines. Works for DisplaySurfaces backed by guest memory (i.e. the ones created using qemu_create_displaysurface_guestmem). Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 4 ui/console.c | 61 +++

Re: [Qemu-devel] [PATCH 04/10] pcspk: adding vmstate for save/restore

2014-09-10 Thread Michael S. Tsirkin
On Tue, Sep 09, 2014 at 03:28:43PM +0200, Paolo Bonzini wrote: > Il 09/09/2014 15:26, Juan Quintela ha scritto: > > Paolo Bonzini wrote: > >> From: Pavel Dovgalyuk > >> > >> VMState added by this patch preserves correct > >> loading of the PC speaker device state. > >> > >> This breaks migration

[Qemu-devel] [PATCH] sdl2: drop sdl_zoom.h

2014-09-10 Thread Gerd Hoffmann
It isn't used. Signed-off-by: Gerd Hoffmann --- ui/sdl2.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ui/sdl2.c b/ui/sdl2.c index fcac87b..1ad74ba 100644 --- a/ui/sdl2.c +++ b/ui/sdl2.c @@ -35,7 +35,6 @@ #include "ui/console.h" #include "ui/input.h" #include "sysemu/sysemu.h" -#include

[Qemu-devel] [PULL v2 8/8] console: Remove unused QEMU_BIG_ENDIAN_FLAG

2014-09-10 Thread Gerd Hoffmann
From: Benjamin Herrenschmidt If we need to, we should use the pixman formats instead but for now this is unused except in commented out code so take it out to avoid further confusion about surface endianness. Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Gerd Hoffmann --- include/ui/co

[Qemu-devel] [PULL v2 4/8] console: stop using PixelFormat

2014-09-10 Thread Gerd Hoffmann
With this patch the qemu console core stops using PixelFormat and pixman format codes side-by-side, pixman format code is the primary way to specify the DisplaySurface format: * DisplaySurface stops carrying a PixelFormat field. * qemu_create_displaysurface_from() expects a pixman format now. F

[Qemu-devel] [PATCH v2 1/4] hw/arm/boot: load DTB as a ROM image

2014-09-10 Thread Ard Biesheuvel
In order to make the device tree blob (DTB) available in memory not only at first boot, but also after system reset, use rom_blob_add_fixed() to install it into memory. Reviewed-by: Peter Maydell Signed-off-by: Ard Biesheuvel --- hw/arm/boot.c | 5 - 1 file changed, 4 insertions(+), 1 delet

[Qemu-devel] [PATCH v2 2/4] hw/arm/boot: pass an address limit to and return size from load_dtb()

2014-09-10 Thread Ard Biesheuvel
Add an address limit input parameter to load_dtb() so that we can tell it how much memory the dtb is allowed to consume. If the dtb doesn't fit, return 0, otherwise return the actual size of the loaded dtb, or -1 on error. Signed-off-by: Ard Biesheuvel --- hw/arm/boot.c | 16 +--- 1

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

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 13:56, Michael S. Tsirkin ha scritto: >> > I've applied all patches except 4 to the uq/master branch. Patch 4 >> > deserves more discussion to see what to do about older machine types >> > (spoiler: my idea is "nothing" :)). >> > >> > Paolo > 9/10 with a tweak to commit log/comments

[Qemu-devel] [PATCH] sdl2: keymap fixups

2014-09-10 Thread Gerd Hoffmann
Make a few keys works correctly in SDL2. Signed-off-by: Gerd Hoffmann --- ui/sdl2-keymap.h | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ui/sdl2-keymap.h b/ui/sdl2-keymap.h index 5a12f45..cbedaa4 100644 --- a/ui/sdl2-keymap.h +++ b/ui/sdl2-keymap.h @@ -105,9 +105,10

[Qemu-devel] [PATCH v2 0/4] ARM: load_dtb() changes for -bios and ELF images

2014-09-10 Thread Ard Biesheuvel
I split off these patches from the series I sent last week. Peter's NOR flash patch has been merged in the mean time, and the CPU reset patch needs to be discussed more widely before we can move forward with it. So what remains are changes in the DTB handling in hw/arm/boot.c, to load a DTB even w

[Qemu-devel] [PATCH v2 4/4] hw/arm/boot: enable DTB support when booting ELF images

2014-09-10 Thread Ard Biesheuvel
Add support for loading DTB images when booting ELF images using -kernel. If there are no conflicts with the placement of the ELF segments, the DTB image is loaded at the base of RAM. Signed-off-by: Ard Biesheuvel --- hw/arm/boot.c | 16 ++-- 1 file changed, 14 insertions(+), 2 delet

[Qemu-devel] [PATCH v2 3/4] hw/arm/boot: load device tree to base of DRAM if no -kernel option was passed

2014-09-10 Thread Ard Biesheuvel
If we are running the 'virt' machine, we may have a device tree blob but no kernel to supply it to if no -kernel option was passed. In that case, copy it to the base of RAM where it can be picked up by a bootloader. Signed-off-by: Ard Biesheuvel --- hw/arm/boot.c | 10 ++ 1 file changed,

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

2014-09-10 Thread zhanghailiang
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 --- V4: - Adjust the errp argument to the end - Remove trailing '.' in error messages V3: - Drop

Re: [Qemu-devel] the userspace process vapp mmap filed // [PULL 13/37] vhost-user: fix regions provied with VHOST_USER_SET_MEM_TABLE message

2014-09-10 Thread Nikolay Nikolaev
Hello, see my answer inline: On Wed, Sep 10, 2014 at 6:00 AM, Linhaifeng wrote: > Hi, > > Thank you for your answer.I think the problem is not how to publish the patch > the problem is there is no standard vhost-user module. > > I just use the vapp to test the new backend vhost-user. I found th

Re: [Qemu-devel] [PATCH 06/10] parallel: adding vmstate for save/restore

2014-09-10 Thread Michael S. Tsirkin
On Tue, Sep 09, 2014 at 03:40:07PM +0200, Paolo Bonzini wrote: > Il 09/09/2014 15:32, Juan Quintela ha scritto: > > This breaks migration with old machine type, but as far as I can see, > > parallel is only added when used, and if we are using it, we need this, > > right? > > Yes. Presumably, yo

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

2014-09-10 Thread Benoît Canet
The Wednesday 10 Sep 2014 à 10:13:30 (+0200), Markus Armbruster wrote : > 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 +-

Re: [Qemu-devel] [PATCH 06/10] parallel: adding vmstate for save/restore

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 14:09, Michael S. Tsirkin ha scritto: >> > Yes. > > Presumably, your next statement means that guests can typically recover > if parallel state is discarded in migration? No, it means that I would not care just like for pcspk. If they are using parallel at the time of migration, th

Re: [Qemu-devel] [PATCH 04/10] pcspk: adding vmstate for save/restore

2014-09-10 Thread Michael S. Tsirkin
On Wed, Sep 10, 2014 at 12:59:35PM +0200, Paolo Bonzini wrote: > Il 10/09/2014 14:02, Michael S. Tsirkin ha scritto: > > That's not too hard: we need two types that only > > differ in the vmstate. > > Use the correct one to create the device depending > > on the pc type. > > > > Put in that light,

Re: [Qemu-devel] [PATCH v2 4/4] hw/arm/boot: enable DTB support when booting ELF images

2014-09-10 Thread Peter Maydell
On 10 September 2014 11:59, Ard Biesheuvel wrote: > Add support for loading DTB images when booting ELF images using > -kernel. If there are no conflicts with the placement of the ELF > segments, the DTB image is loaded at the base of RAM. > > Signed-off-by: Ard Biesheuvel > --- > hw/arm/boot.c

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

2014-09-10 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > Il 09/09/2014 15:59, Juan Quintela ha scritto: > > But poll_msl is "more" interesting, because we are not "reseting it". > > > > So, we have that if we are migrating from an old version, we would have > > poll_msl == -1, and we used to have it to

Re: [Qemu-devel] [PATCH 04/10] pcspk: adding vmstate for save/restore

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 14:20, Michael S. Tsirkin ha scritto: > > Do you have an example? I can think of one that we did in RHEL (hda) > > but it was never upstream. > > Well the whole PC machine is exactly like this, isn't it? Sorry, I cannot parse. You proposed creating two versions of pcspk that only

Re: [Qemu-devel] [PATCH v2 4/4] hw/arm/boot: enable DTB support when booting ELF images

2014-09-10 Thread Ard Biesheuvel
On 10 September 2014 13:21, Peter Maydell wrote: > On 10 September 2014 11:59, Ard Biesheuvel wrote: >> Add support for loading DTB images when booting ELF images using >> -kernel. If there are no conflicts with the placement of the ELF >> segments, the DTB image is loaded at the base of RAM. >>

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

2014-09-10 Thread zhanghailiang
formated -> formatted gaurantee -> guarantee shear -> sheer Signed-off-by: zhanghailiang --- v2: The typos in epapr_hcalls.h should be fixed via the kernel (comment of PMM) --- hw/ppc/spapr.c | 2 +- libcacard/vcard_emul_nss.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletion

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

2014-09-10 Thread Christoffer Dall
On Wed, Sep 10, 2014 at 12:48 PM, Ard Biesheuvel wrote: > 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 incorrect

Re: [Qemu-devel] [PATCH v2 4/4] hw/arm/boot: enable DTB support when booting ELF images

2014-09-10 Thread Peter Maydell
On 10 September 2014 12:28, Ard Biesheuvel wrote: > On 10 September 2014 13:21, Peter Maydell wrote: >> The conditional means we won't try to load the DTB even if the >> ELF file fit into the address space entirely below loader_start, >> which doesn't look right. >> > > Ah right, I though loader_

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

2014-09-10 Thread Benoît Canet
The Wednesday 10 Sep 2014 à 10:13:31 (+0200), Markus Armbruster wrote : > 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 Bl

Re: [Qemu-devel] [PATCH 04/10] pcspk: adding vmstate for save/restore

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 14:02, Michael S. Tsirkin ha scritto: > That's not too hard: we need two types that only > differ in the vmstate. > Use the correct one to create the device depending > on the pc type. > > Put in that light, we definitely did create new > devices while keeping old ones around for > c

[Qemu-devel] [PATCH v2] hw/dma/i8257: Silence phony error message

2014-09-10 Thread Philipp Hahn
Convert into trace event. Otherwise the message dma: unregistered DMA channel used nchan=0 dma_pos=0 dma_len=1 gets printed every time and fills up the log-file with 50 MiB / minute. Signed-off-by: Philipp Hahn --- v2: Convert into trace event instead of tracking once per static bitma

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

2014-09-10 Thread Kevin Wolf
Am 10.09.2014 um 13:34 hat Benoît Canet geschrieben: > The Wednesday 10 Sep 2014 à 10:13:31 (+0200), Markus Armbruster wrote : > > 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

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

2014-09-10 Thread Benoît Canet
The Wednesday 10 Sep 2014 à 13:44:17 (+0200), Kevin Wolf wrote : > Am 10.09.2014 um 13:34 hat Benoît Canet geschrieben: > > The Wednesday 10 Sep 2014 à 10:13:31 (+0200), Markus Armbruster wrote : > > > A block device consists of a frontend device model and a backend. > > > > > > A block backend ha

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

2014-09-10 Thread Benoît Canet
The Wednesday 10 Sep 2014 à 10:13:32 (+0200), Markus Armbruster wrote : > 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

Re: [Qemu-devel] [RFC v1 4/6] target_arm: Update armv7_init to support more parameters

2014-09-10 Thread Peter Crosthwaite
On Wed, Sep 10, 2014 at 9:39 AM, Alistair Francis wrote: > On Tue, Sep 9, 2014 at 11:59 PM, Peter Maydell > wrote: >> On 9 September 2014 14:35, Peter Crosthwaite >> wrote: >>> Does ARMv7M actually mandate the existence of RAM and flash like this >>> at all? >> >> No. It does have a well define

[Qemu-devel] [PATCH v8 01/30] bootdevice: move bootdevice related code to new file bootdevice.c

2014-09-10 Thread arei.gonglei
From: Gonglei Signed-off-by: Gonglei --- Makefile.target | 2 +- bootdevice.c| 142 include/sysemu/sysemu.h | 1 + vl.c| 118 +--- 4 files changed, 145 insertions(+),

[Qemu-devel] [PATCH v8 08/30] virtio-net: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/virtio-net.c | 3 +++ 1 file changed, 3 inserti

[Qemu-devel] [PATCH v8 05/30] bootindex: rework add_boot_device_path function

2014-09-10 Thread arei.gonglei
From: Gonglei Add the function of updating bootindex about fw_boot_order list in add_boot_device_path(). We should delete the old one if a device has existed in global fw_boot_order list. Signed-off-by: Gonglei --- bootdevice.c | 21 + 1 file changed, 21 insertions(+) diff

[Qemu-devel] [PATCH v8 15/30] vmxnet3: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/spapr_llan.c | 22 -- hw/ne

[Qemu-devel] [PATCH v8 00/30] modify boot order of guest, and take effect after rebooting

2014-09-10 Thread arei.gonglei
From: Gonglei Sometimes, we want to modify boot order of a guest, but no need to shutdown it. We can call dynamic changing bootindex of a guest, which can be assured taking effect just after the guest rebooting. For example, in P2V scene, we boot a guest and then attach a new system disk, for co

[Qemu-devel] [PATCH v8 11/30] ne2000: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/ne2000.c | 12 1 file changed, 12

[Qemu-devel] [PATCH v8 09/30] e1000: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/e1000.c | 10 ++ 1 file changed, 10 ins

[Qemu-devel] [PATCH v8 03/30] bootindex: add del_boot_device_path function

2014-09-10 Thread arei.gonglei
From: Gonglei Introduce del_boot_device_path() to clean up fw_cfg content when hot-unplugging a device that refers to a bootindex. Signed-off-by: Gonglei Signed-off-by: Chenliang --- bootdevice.c| 21 + include/sysemu/sysemu.h | 1 + 2 files changed, 22 insert

[Qemu-devel] [PATCH v8 27/30] block: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/scsi/scsi-disk.c | 1 - hw/scsi/scsi-generic.c | 1 - include/hw/block/block.h | 1 - 3 f

[Qemu-devel] [PATCH v8 02/30] bootindex: add check bootindex function

2014-09-10 Thread arei.gonglei
From: Gonglei Determine whether a given bootindex exists or not. If exists, we report an error. Signed-off-by: Gonglei --- bootdevice.c| 15 +++ include/sysemu/sysemu.h | 1 + 2 files changed, 16 insertions(+) diff --git a/bootdevice.c b/bootdevice.c index d5b8789..f5

[Qemu-devel] [PATCH v8 10/30] eepro100: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/eepro100.c | 11 ++- 1 file changed, 10

[Qemu-devel] [PATCH v8 19/30] host-libusb: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/usb/host-libusb.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git

[Qemu-devel] [PATCH v8 16/30] usb-net: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/usb/dev-network.c | 11 +++ 1 file changed,

[Qemu-devel] [PATCH v8 28/30] ide: add calling add_boot_device_patch in bootindex setter function

2014-09-10 Thread arei.gonglei
From: Gonglei On this way, we can assure the new bootindex take effect during vm rebooting. Meanwhile set the initial value of bootindex to -1. Because ide devcies's unit property maybe do not initialize when set_bootindex function is called, so that we don't know its suffix. So we have to save

[Qemu-devel] [PATCH v8 04/30] fw_cfg: add fw_cfg_machine_reset function

2014-09-10 Thread arei.gonglei
From: Gonglei We must assure that the changed bootindex can take effect when guest is rebooted. So we introduce fw_cfg_machine_reset(), which change the fw_cfg file's bootindex data using the new global fw_boot_order list. Signed-off-by: Chenliang Signed-off-by: Gonglei --- hw/nvram/fw_cfg.c

[Qemu-devel] [PATCH v8 20/30] pci-assign: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/i386/kvm/pci-assign.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff -

[Qemu-devel] [PATCH v8 18/30] virtio-net: alias bootindex property explicitly for virt-net-pci/ccw/s390

2014-09-10 Thread arei.gonglei
From: Gonglei Since the "bootindex" property is a QOM property and not a qdev property now, we must alias it explicitly for virtio-net-pci, as well as CCW and s390-virtio. Signed-off-by: Gonglei --- hw/s390x/s390-virtio-bus.c | 2 ++ hw/s390x/virtio-ccw.c | 2 ++ hw/virtio/virtio-pci.c

[Qemu-devel] [PATCH v8 25/30] ide: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/ide/qdev.c | 42 +++

[Qemu-devel] [PATCH v8 06/30] bootindex: support to set a existent device's bootindex to -1

2014-09-10 Thread arei.gonglei
From: Gonglei When set a device's bootindex to -1, we remove it from global fw_boot_order list. Signed-off-by: Gonglei --- bootdevice.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bootdevice.c b/bootdevice.c index 628596d..d50ead8 100644 --- a/bootdevice.c +++ b/bootdevice.c @@ -97,6 +

[Qemu-devel] [PATCH v8 23/30] isa-fdc: remove bootindexA/B property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindexA/B form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/block/fdc.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --

Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/2] PPC: openpic_kvm: Filter region callbacks based on memory region offset

2014-09-10 Thread bogdan.purcare...@freescale.com
> -Original Message- > From: Wood Scott-B07421 > Sent: Friday, September 05, 2014 6:47 PM > To: Purcareata Bogdan-B43198 > Cc: qemu-...@nongnu.org; Caraman Mihai Claudiu-B02008; qemu-devel@nongnu.org > Subject: Re: [Qemu-ppc] [PATCH 2/2] PPC: openpic_kvm: Filter region callbacks > based on

[Qemu-devel] [PATCH v8 21/30] vfio: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/misc/vfio.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/hw/

[Qemu-devel] [PATCH v8 26/30] virtio-blk: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/block/virtio-blk.c | 3 +++ 1 file changed, 3 inser

[Qemu-devel] [PATCH v8 07/30] bootindex: add a setter/getter functions wrapper for bootindex property

2014-09-10 Thread arei.gonglei
From: Gonglei when we remove bootindex form qdev.property to qom.property, we can use those functions set/get bootindex property for all correlative devices. Meanwhile set the initial value of bootindex to -1. Signed-off-by: Gonglei --- bootdevice.c| 73

[Qemu-devel] [PATCH v8 29/30] bootindex: move calling add_boot_device_patch to bootindex setter function

2014-09-10 Thread arei.gonglei
From: Gonglei On this way, we can assure the new bootindex take effect during vm rebooting. Signed-off-by: Gonglei --- bootdevice.c | 2 ++ hw/block/fdc.c | 3 --- hw/block/virtio-blk.c| 2 -- hw/i386/kvm/pci-assign.c | 2 -- hw/misc/vfio.c | 1 - hw/net/e10

[Qemu-devel] [PATCH v8 30/30] bootindex: delete bootindex when device is removed

2014-09-10 Thread arei.gonglei
From: Gonglei Device should be removed from global boot list when it is hot-unplugged. Signed-off-by: Gonglei --- bootdevice.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bootdevice.c b/bootdevice.c index ae6ab4a..d69ab73 100644 --- a/bootdevice.c +++ b/bootdevice.c @@ -245,6 +245,8

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

2014-09-10 Thread Kevin Wolf
Am 10.09.2014 um 10:13 hat Markus Armbruster geschrieben: > 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 > BlockDriverS

[Qemu-devel] [PATCH v8 13/30] rtl8139: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/rtl8139.c | 10 ++ 1 file changed, 10 i

[Qemu-devel] [PATCH v8 12/30] pcnet: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/lance.c | 12 hw/net/pcnet-pci

Re: [Qemu-devel] [RFC PATCH v6 00/14] Reverse execution.

2014-09-10 Thread Frederic Konrad
On 09/09/2014 08:30, Pavel Dovgaluk wrote: From: Frederic Konrad [mailto:fred.kon...@greensocs.com] On 08/09/2014 10:29, Paolo Bonzini wrote: Il 08/09/2014 10:09, Frederic Konrad ha scritto: By the way how do you want to have this discussion? At the KVM forum? Or by phone on KVM phone call? O

[Qemu-devel] [PATCH] qapi: Fix crash with enum dealloc when kind is invalid

2014-09-10 Thread Fam Zheng
We shouldn't do anything in the switch block in enum's visit_type_ function, when the enum data's ->kind is not valid at all. This happens when the dealloc visitor is called, after qmp input visitor returned error. Now, the input visitor will set ->kind to _MAX if the value is not found, so that i

[Qemu-devel] [PATCH v9 02/30] bootindex: add check bootindex function

2014-09-10 Thread arei.gonglei
From: Gonglei Determine whether a given bootindex exists or not. If exists, we report an error. Signed-off-by: Gonglei --- bootdevice.c| 15 +++ include/sysemu/sysemu.h | 1 + 2 files changed, 16 insertions(+) diff --git a/bootdevice.c b/bootdevice.c index d5b8789..f5

[Qemu-devel] [PATCH v9 01/30] bootdevice: move bootdevice related code to new file bootdevice.c

2014-09-10 Thread arei.gonglei
From: Gonglei Signed-off-by: Gonglei --- Makefile.target | 2 +- bootdevice.c| 142 include/sysemu/sysemu.h | 1 + vl.c| 118 +--- 4 files changed, 145 insertions(+),

[Qemu-devel] [PATCH v9 07/30] bootindex: add a setter/getter functions wrapper for bootindex property

2014-09-10 Thread arei.gonglei
From: Gonglei when we remove bootindex form qdev.property to qom.property, we can use those functions set/get bootindex property for all correlative devices. Meanwhile set the initial value of bootindex to -1. Signed-off-by: Gonglei --- bootdevice.c| 73

[Qemu-devel] [PATCH v9 00/30] modify boot order of guest, and take effect after rebooting

2014-09-10 Thread arei.gonglei
From: Gonglei Sometimes, we want to modify boot order of a guest, but no need to shutdown it. We can call dynamic changing bootindex of a guest, which can be assured taking effect just after the guest rebooting. For example, in P2V scene, we boot a guest and then attach a new system disk, for co

[Qemu-devel] [PATCH v9 08/30] virtio-net: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/virtio-net.c | 3 +++ 1 file changed, 3 inserti

[Qemu-devel] [PATCH v9 03/30] bootindex: add del_boot_device_path function

2014-09-10 Thread arei.gonglei
From: Gonglei Introduce del_boot_device_path() to clean up fw_cfg content when hot-unplugging a device that refers to a bootindex. Signed-off-by: Gonglei Signed-off-by: Chenliang --- bootdevice.c| 21 + include/sysemu/sysemu.h | 1 + 2 files changed, 22 insert

[Qemu-devel] [PATCH v9 13/30] rtl8139: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/rtl8139.c | 10 ++ 1 file changed, 10 i

[Qemu-devel] [PATCH v9 14/30] spapr_lian: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/spapr_llan.c | 10 ++ 1 file changed, 1

[Qemu-devel] [PATCH v9 06/30] bootindex: support to set a existent device's bootindex to -1

2014-09-10 Thread arei.gonglei
From: Gonglei When set a device's bootindex to -1, we remove it from global fw_boot_order list. Signed-off-by: Gonglei --- bootdevice.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bootdevice.c b/bootdevice.c index 628596d..d50ead8 100644 --- a/bootdevice.c +++ b/bootdevice.c @@ -97,6 +

[Qemu-devel] [PATCH v9 12/30] pcnet: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/lance.c | 12 hw/net/pcnet-pci

[Qemu-devel] [PATCH v9 09/30] e1000: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/e1000.c | 10 ++ 1 file changed, 10 ins

[Qemu-devel] [PATCH v9 17/30] net: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- include/net/net.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/net

[Qemu-devel] [PATCH] kvm: ioapic: conditionally delay irq delivery during eoi broadcast

2014-09-10 Thread Zhang Haoyu
Currently, we call ioapic_service() immediately when we find the irq is still active during eoi broadcast. But for real hardware, there's some dealy between the EOI writing and irq delivery (system bus latency?). So we need to emulate this behavior. Otherwise, for a guest who haven't register a pro

[Qemu-devel] [PATCH v9 18/30] virtio-net: alias bootindex property explicitly for virt-net-pci/ccw/s390

2014-09-10 Thread arei.gonglei
From: Gonglei Since the "bootindex" property is a QOM property and not a qdev property now, we must alias it explicitly for virtio-net-pci, as well as CCW and s390-virtio. Signed-off-by: Gonglei --- hw/s390x/s390-virtio-bus.c | 2 ++ hw/s390x/virtio-ccw.c | 2 ++ hw/virtio/virtio-pci.c

[Qemu-devel] [PATCH v9 11/30] ne2000: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/net/ne2000.c | 12 1 file changed, 12

[Qemu-devel] [PATCH v9 24/30] scsi: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/scsi/scsi-bus.c | 11 +++ 1 file changed, 1

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

2014-09-10 Thread Benoît Canet
The Wednesday 10 Sep 2014 à 10:13:31 (+0200), Markus Armbruster wrote : > 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 Bl

[Qemu-devel] [PATCH v9 23/30] isa-fdc: remove bootindexA/B property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindexA/B form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/block/fdc.c | 15 +-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --gi

[Qemu-devel] [PATCH v9 16/30] usb-net: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/usb/dev-network.c | 11 +++ 1 file changed,

[Qemu-devel] [PATCH v9 28/30] ide: add calling add_boot_device_patch in bootindex setter function

2014-09-10 Thread arei.gonglei
From: Gonglei On this way, we can assure the new bootindex take effect during vm rebooting. Meanwhile set the initial value of bootindex to -1. Because ide devcies's unit property maybe do not initialize when set_bootindex function is called, so that we don't know its suffix. So we have to save

[Qemu-devel] [PATCH v9 19/30] host-libusb: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/usb/host-libusb.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git

[Qemu-devel] [PATCH v9 26/30] virtio-blk: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/block/virtio-blk.c | 3 +++ 1 file changed, 3 inser

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

2014-09-10 Thread Peter Crosthwaite
On Wed, Sep 10, 2014 at 9:32 PM, Christoffer Dall wrote: > On Wed, Sep 10, 2014 at 12:48 PM, Ard Biesheuvel > wrote: >> 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 trigge

[Qemu-devel] [PATCH v9 22/30] redirect: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/usb/redirect.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/

[Qemu-devel] [PATCH v9 29/30] bootindex: move calling add_boot_device_patch to bootindex setter function

2014-09-10 Thread arei.gonglei
From: Gonglei On this way, we can assure the new bootindex take effect during vm rebooting. Signed-off-by: Gonglei --- bootdevice.c | 2 ++ hw/block/fdc.c | 3 --- hw/block/virtio-blk.c| 2 -- hw/i386/kvm/pci-assign.c | 2 -- hw/misc/vfio.c | 1 - hw/net/e10

[Qemu-devel] [PATCH v9 25/30] ide: add bootindex to qom property

2014-09-10 Thread arei.gonglei
From: Gonglei Add a qom property with the same name 'bootindex', when we remove it form qdev property, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/ide/qdev.c | 42 +++

[Qemu-devel] [PATCH v9 30/30] bootindex: delete bootindex when device is removed

2014-09-10 Thread arei.gonglei
From: Gonglei Device should be removed from global boot list when it is hot-unplugged. Signed-off-by: Gonglei --- bootdevice.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bootdevice.c b/bootdevice.c index ae6ab4a..d69ab73 100644 --- a/bootdevice.c +++ b/bootdevice.c @@ -245,6 +245,8

Re: [Qemu-devel] [PATCH] kvm: ioapic: conditionally delay irq delivery during eoi broadcast

2014-09-10 Thread Zhang Haoyu
>+static void kvm_ioapic_eoi_inject_work(struct work_struct *work) >+{ >+ int i, ret; >+ struct kvm_ioapic *ioapic = container_of(work, struct kvm_ioapic, >+ eoi_inject.work); >+ spin_lock(&ioapic->lock); >+ for (i = 0; i < IOAPIC_NU

Re: [Qemu-devel] [Qemu-ppc] [PATCH 0/2] PPC: kvm: Fix incorrect remapping of in-kernel MPIC

2014-09-10 Thread Alexander Graf
On 05.09.14 16:31, mihai.cara...@freescale.com wrote: >> -Original Message- >> From: qemu-devel-bounces+mihai.caraman=freescale@nongnu.org >> [mailto:qemu-devel-bounces+mihai.caraman=freescale@nongnu.org] On >> Behalf Of Alexander Graf >> Sent: Friday, September 05, 2014 12:08 PM

[Qemu-devel] [PATCH v9 20/30] pci-assign: remove bootindex property from qdev to qom

2014-09-10 Thread arei.gonglei
From: Gonglei Remove bootindex form qdev property to qom, things will continue to work just fine, and we can use qom features which are not supported by qdev property. Signed-off-by: Gonglei --- hw/i386/kvm/pci-assign.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff -

Re: [Qemu-devel] [PATCH] qapi: Fix crash with enum dealloc when kind is invalid

2014-09-10 Thread Paolo Bonzini
Il 10/09/2014 14:30, Fam Zheng ha scritto: > We shouldn't do anything in the switch block in enum's visit_type_ > function, when the enum data's ->kind is not valid at all. This happens > when the dealloc visitor is called, after qmp input visitor returned > error. > > Now, the input visitor will

<    1   2   3   4   >