Re: [Qemu-devel] [RFC qemu 0/4] A PV solution for live migration optimization

2016-03-09 Thread Amit Shah
On (Thu) 10 Mar 2016 [07:44:19], Li, Liang Z wrote: > > Hi Amit, > > Could provide more information on how to use virtio-serial to exchange data? > Thread , Wiki or code are all OK. > I have not find some useful information yet. See this commit in the Linux sources:

Re: [Qemu-devel] [PATCH] usb: fix unbounded stack warning for xhci_dma_write_u32s

2016-03-09 Thread Peter Xu
On Thu, Mar 10, 2016 at 08:34:13AM +0100, Gerd Hoffmann wrote: > On Do, 2016-03-10 at 10:11 +0800, Peter Xu wrote: > > Signed-off-by: Peter Xu > > --- > > hw/usb/hcd-xhci.c | 6 -- > > 1 file changed, 4 insertions(+), 2 deletions(-) > > > > diff --git a/hw/usb/hcd-xhci.c

Re: [Qemu-devel] [RFC qemu 0/4] A PV solution for live migration optimization

2016-03-09 Thread Li, Liang Z
> > This patch set is the QEMU side implementation. > > > > The virtio-balloon is extended so that QEMU can get the free pages > > information from the guest through virtio. > > > > After getting the free pages information (a bitmap), QEMU can use it > > to filter out the guest's free pages in the

Re: [Qemu-devel] [PATCH 2/2] usb: trivial cleanup for usb_mtp_add_str

2016-03-09 Thread Gerd Hoffmann
On Do, 2016-03-10 at 07:51 +0100, Markus Armbruster wrote: > Fam Zheng writes: > > > On Wed, 03/09 14:10, Peter Xu wrote: > >> Remove useless var "ret". > >> > >> Signed-off-by: Peter Xu > >> --- > >> hw/usb/dev-mtp.c | 4 +--- > >> 1 file changed, 1

Re: [Qemu-devel] [Qemu-ppc] [PATCH qemu v13 04/16] spapr_iommu: Introduce "enabled" state for TCE table

2016-03-09 Thread Alexey Kardashevskiy
On 03/03/2016 02:00 PM, David Gibson wrote: On Tue, Mar 01, 2016 at 08:10:29PM +1100, Alexey Kardashevskiy wrote: Currently TCE tables are created once at start and their sizes never change. We are going to change that by introducing a Dynamic DMA windows support where DMA configuration may

Re: [Qemu-devel] [PATCH] usb: fix unbounded stack warning for xhci_dma_write_u32s

2016-03-09 Thread Gerd Hoffmann
On Do, 2016-03-10 at 10:11 +0800, Peter Xu wrote: > Signed-off-by: Peter Xu > --- > hw/usb/hcd-xhci.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c > index 44b6f8c..d15918f 100644 > --- a/hw/usb/hcd-xhci.c

Re: [Qemu-devel] [PATCH 0/3] input: linux evdev support

2016-03-09 Thread Gerd Hoffmann
Hi, > However, instead of adding a new -input-linux option, could you make it > a QOM object which implements UserCreatable? Then you can add it with > something like "-object input-linux,path=/dev/input/input10" (perhaps > "input-evdev" would be more specific). This has three advantages:

Re: [Qemu-devel] [RFC kernel 0/2]A PV solution for KVM live migration optimization

2016-03-09 Thread Amit Shah
On (Thu) 10 Mar 2016 [12:31:32], Jitendra Kolhe wrote: > On 3/8/2016 4:44 PM, Amit Shah wrote: > Hi, > An interesting solution; I know a few different people have been > looking at > how to speed up ballooned VM migration. > > >>> > >>> Ooh, different solutions for the

[Qemu-devel] [Bug 1555452] Re: GDB server does not work in Windows

2016-03-09 Thread Yorkwar
It seems that someone is fixing this at https://www.mail-archive.com /qemu-devel@nongnu.org/msg358825.html -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1555452 Title: GDB server does not work in

[Qemu-devel] [Bug 1555452] [NEW] GDB server does not work in Windows

2016-03-09 Thread Yorkwar
Public bug reported: I build qemu with msys2, MINGW64. After fix the socket_error() problem, and manually specify to use IPv4, GDB server still does not work. The related qemu command is "-monitor none -nographic -gdb tcp::1234 -S" GDB reports "Timed out" There's a message at

Re: [Qemu-devel] [RFC kernel 0/2]A PV solution for KVM live migration optimization

2016-03-09 Thread Li, Liang Z
> On 3/8/2016 4:44 PM, Amit Shah wrote: > > On (Fri) 04 Mar 2016 [15:02:47], Jitendra Kolhe wrote: > > * Liang Li (liang.z...@intel.com) wrote: > > The current QEMU live migration implementation mark the all the > > guest's RAM pages as dirtied in the ram bulk stage, all these >

Re: [Qemu-devel] [RFC kernel 0/2]A PV solution for KVM live migration optimization

2016-03-09 Thread Jitendra Kolhe
On 3/8/2016 4:44 PM, Amit Shah wrote: > On (Fri) 04 Mar 2016 [15:02:47], Jitendra Kolhe wrote: * Liang Li (liang.z...@intel.com) wrote: > The current QEMU live migration implementation mark the all the > guest's RAM pages as dirtied in the ram bulk stage, all these pages >

Re: [Qemu-devel] [PATCH v2 05/42] ivshmem-server: Don't overload POSIX shmem and file name

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Wed, Mar 9, 2016 at 9:14 PM, Markus Armbruster wrote: >>> @@ -77,7 +77,7 @@ ivshmem_server_parse_args(IvshmemServerArgs *args, int >>> argc, char *argv[]) >>> "F" /* foreground */ >>>

Re: [Qemu-devel] [PATCH 2/2] usb: trivial cleanup for usb_mtp_add_str

2016-03-09 Thread Markus Armbruster
Fam Zheng writes: > On Wed, 03/09 14:10, Peter Xu wrote: >> Remove useless var "ret". >> >> Signed-off-by: Peter Xu >> --- >> hw/usb/dev-mtp.c | 4 +--- >> 1 file changed, 1 insertion(+), 3 deletions(-) >> >> diff --git a/hw/usb/dev-mtp.c

Re: [Qemu-devel] [PATCH v2 33/42] ivshmem: Implement shm=... with a memory backend

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Wed, Mar 9, 2016 at 9:59 PM, Markus Armbruster wrote: >> The integrated memory backend has to go. >> >> Yes, my desugaring to memory-backend-file assumes Linux and the >> conventional mount point /dev/shm. >>

Re: [Qemu-devel] [PATCH v2 28/42] ivshmem: Propagate errors through ivshmem_recv_setup()

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > On Wed, Mar 9, 2016 at 9:25 PM, Markus Armbruster wrote: >> Now let me explain *why* I want the assertion. The purpose of the >> previous patch and this one is to ensure that the realized device always >> has the shared

Re: [Qemu-devel] [PATCH v2 09/11] vfio: vote a device to do host bus reset

2016-03-09 Thread Chen Fan
On 03/10/2016 12:37 AM, Alex Williamson wrote: On Mon, 7 Mar 2016 11:23:02 +0800 Cao jin wrote: From: Chen Fan Signed-off-by: Chen Fan --- hw/vfio/pci.c | 57

Re: [Qemu-devel] [PATCH v3 5/5] replay: introduce block devices record/replay

2016-03-09 Thread Pavel Dovgalyuk
> From: Kevin Wolf [mailto:kw...@redhat.com] > Am 01.03.2016 um 12:08 hat Pavel Dovgalyuk geschrieben: > > This patch introduces block driver that implement recording > > and replaying of block devices' operations. > > All block completion operations are added to the queue. > > Queue is flushed at

Re: [Qemu-devel] [PATCH v2 4/5] spapr: check if cpu core is already present

2016-03-09 Thread Bharata B Rao
On Thu, Mar 10, 2016 at 04:22:43PM +1100, David Gibson wrote: > On Wed, Mar 09, 2016 at 11:07:40AM +0100, Igor Mammedov wrote: > > On Tue, 8 Mar 2016 20:04:12 +0530 > > Bharata B Rao wrote: > > > > > On Tue, Mar 08, 2016 at 02:18:14PM +0100, Igor Mammedov wrote: > > >

Re: [Qemu-devel] [PATCH v4 2/8] pc: move igd support code to igd.c

2016-03-09 Thread Tian, Kevin
> From: Gerd Hoffmann [mailto:kra...@redhat.com] > Sent: Wednesday, March 09, 2016 11:08 PM > > Hi, > > > +/* Here we just expose minimal host bridge offset subset. */ > > +static const IGDHostInfo igd_host_bridge_infos[] = { > > +{0x08, 2}, /* revision id */ > > +{0x2c, 2}, /*

Re: [Qemu-devel] chardev: vhost-user: reconnect issue when QEMU as server

2016-03-09 Thread Yuanhan Liu
On Wed, Mar 09, 2016 at 04:04:45PM +0100, Marc-André Lureau wrote: > Hi > > On Wed, Mar 9, 2016 at 2:29 PM, Yuanhan Liu > wrote: > > I could spend more time to dig it. But before that, I want to know > > how you guys think about it? Does that proposal makes sense

Re: [Qemu-devel] [iGVT-g] [PATCH v2] vfio/igd: handle q35 machine type

2016-03-09 Thread Tian, Kevin
> From: Gerd Hoffmann > Sent: Wednesday, March 09, 2016 11:01 PM > > Hi, > > [ context for igvt list: how do we deal with the ich9 lpc emulated by > q35 machine type best, when pci-assigning a igd? ] > > > > It seems > > > quite limiting of igd assignment on q35 VMs if we're going to remove

Re: [Qemu-devel] [Qemu-ppc] [PATCH qemu v13 02/16] spapr_pci: Move DMA window enablement to a helper

2016-03-09 Thread Alexey Kardashevskiy
On 03/03/2016 12:40 PM, David Gibson wrote: On Tue, Mar 01, 2016 at 08:10:27PM +1100, Alexey Kardashevskiy wrote: We are going to have multiple DMA windows soon so let's start preparing. This adds a new helper to create a DMA window and makes use of it in sPAPRPHBState::realize().

Re: [Qemu-devel] [PATCH 2/2] i386: Interrupt remapping support for VT-d

2016-03-09 Thread Peter Xu
On Wed, Mar 09, 2016 at 12:58:17AM +0530, Rita Sinha wrote: > From: Jan Kiszka > > Still a bit hacky, unconditionally enabled (must become opt-in, not > available with in-kernel irqchip), not reporting faults properly - but > it works! And revealed a Linux bug [1] If the

Re: [Qemu-devel] [PATCH v2 4/5] spapr: check if cpu core is already present

2016-03-09 Thread David Gibson
On Wed, Mar 09, 2016 at 11:07:40AM +0100, Igor Mammedov wrote: > On Tue, 8 Mar 2016 20:04:12 +0530 > Bharata B Rao wrote: > > > On Tue, Mar 08, 2016 at 02:18:14PM +0100, Igor Mammedov wrote: > > > Signed-off-by: Igor Mammedov > > > --- > > >

Re: [Qemu-devel] [PATCH 1/2] i386: Prepare for interrupt remapping

2016-03-09 Thread Peter Xu
Hi, Jan/Rita, Have not gone deeper... Got several comments and questions inline. On Wed, Mar 09, 2016 at 12:58:41AM +0530, Rita Sinha wrote: [...] > +static AddressSpace *get_dma_address_space(void) > +{ > +return _MACHINE(qdev_get_machine())->dma_address_space; > +} > + > /* Given the

Re: [Qemu-devel] [PULL 0/8] VFIO updates 2016-03-09

2016-03-09 Thread Peter Maydell
On 10 March 2016 at 12:03, Peter Maydell wrote: > On 10 March 2016 at 02:53, Alex Williamson wrote: >> The following changes since commit 4ba364b47275fe428723442987b57b260b215dba: >> >> Merge remote-tracking branch

Re: [Qemu-devel] [RFC PATCH v1 05/10] cpu: Abstract CPU core type

2016-03-09 Thread David Gibson
On Wed, Mar 09, 2016 at 11:32:28AM +0100, Igor Mammedov wrote: > On Wed, 9 Mar 2016 13:55:51 +1100 > David Gibson wrote: > > > On Tue, Mar 08, 2016 at 10:11:17AM +0100, Igor Mammedov wrote: > > > On Tue, 8 Mar 2016 14:57:10 +1100 > > > David Gibson

Re: [Qemu-devel] [Qemu-ppc] Migrating decrementer

2016-03-09 Thread David Gibson
On Mon, Feb 29, 2016 at 08:21:39PM +, Mark Cave-Ayland wrote: > On 29/02/16 03:57, David Gibson wrote: > > > On Fri, Feb 26, 2016 at 12:29:51PM +, Mark Cave-Ayland wrote: > >> On 26/02/16 04:35, David Gibson wrote: > >> > Sign. And let me try that again, this time after caffeine: >

Re: [Qemu-devel] [PULL 0/8] VFIO updates 2016-03-09

2016-03-09 Thread Peter Maydell
On 10 March 2016 at 02:53, Alex Williamson wrote: > The following changes since commit 4ba364b47275fe428723442987b57b260b215dba: > > Merge remote-tracking branch 'remotes/thibault/tags/samuel-thibault' into > staging (2016-03-09 05:14:55 +) > > are available in

Re: [Qemu-devel] [PULL 0/5] ui: add linux evdev support, vnc and console fixes

2016-03-09 Thread Peter Maydell
5cd6cdeb0b5c1a54d3d3791396e47e52f: > > Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2016-03-04' > into staging (2016-03-06 11:53:27 +) > > are available in the git repository at: > > > git://git.kraxel.org/qemu tags/pull-ui-20160309-1 > > for you

Re: [Qemu-devel] [PULL 00/14] Net patches

2016-03-09 Thread Li Zhijian
On 03/10/2016 10:28 AM, Jason Wang wrote: On 03/08/2016 05:54 PM, Peter Maydell wrote: On 8 March 2016 at 16:06, Zhang Chen wrote: I found the reason for this problem is that unix_connect() have not connect to sock_path before iov_send(). It need time to

Re: [Qemu-devel] [RFC PATCH v2 3/3] VFIO: Type1 IOMMU mapping support for vGPU

2016-03-09 Thread Jike Song
On 03/08/2016 08:31 AM, Neo Jia wrote: > On Mon, Mar 07, 2016 at 02:07:15PM +0800, Jike Song wrote: >> Hi Neo, >> >> On Fri, Mar 4, 2016 at 3:00 PM, Neo Jia wrote: >>> On Wed, Mar 02, 2016 at 04:38:34PM +0800, Jike Song wrote: On 02/24/2016 12:24 AM, Kirti Wankhede wrote:

Re: [Qemu-devel] [PATCH 1/1] MAINTAINERS: Fix typo, block/stream.h -> block/stream.c

2016-03-09 Thread Fam Zheng
On Wed, 03/09 21:54, Jeff Cody wrote: > There is no block/stream.h, the intended filename is block/stream.c > instead. > > Signed-off-by: Jeff Cody > --- > MAINTAINERS | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/MAINTAINERS b/MAINTAINERS > index

[Qemu-devel] [PATCH 1/1] MAINTAINERS: Fix typo, block/stream.h -> block/stream.c

2016-03-09 Thread Jeff Cody
There is no block/stream.h, the intended filename is block/stream.c instead. Signed-off-by: Jeff Cody --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index dc0aa54..e04e9e9 100644 --- a/MAINTAINERS +++ b/MAINTAINERS

[Qemu-devel] [PATCH v12 3/3] qmp: add monitor command to add/remove a child

2016-03-09 Thread Changlong Xie
From: Wen Congyang The new QMP command name is x-blockdev-change. It's just for adding/removing quorum's child now, and doesn't support all kinds of children, all kinds of operations, nor all block drivers. So it is experimental now. Signed-off-by: Wen Congyang

[Qemu-devel] [PATCH v12 1/3] Add new block driver interface to add/delete a BDS's child

2016-03-09 Thread Changlong Xie
From: Wen Congyang In some cases, we want to take a quorum child offline, and take another child online. Signed-off-by: Wen Congyang Signed-off-by: zhanghailiang Signed-off-by: Gonglei

[Qemu-devel] [PATCH v12 2/3] quorum: implement bdrv_add_child() and bdrv_del_child()

2016-03-09 Thread Changlong Xie
From: Wen Congyang Signed-off-by: Wen Congyang Signed-off-by: zhanghailiang Signed-off-by: Gonglei Signed-off-by: Changlong Xie Reviewed-by: Max Reitz

[Qemu-devel] [PATCH v12 0/3] qapi: child add/delete support

2016-03-09 Thread Changlong Xie
ChangLog: v11~v12: 1. Address comments from Max p1. Add R-B p2. Add R-B, remove unnecessary "endptr" "value" p3. Add R-B v10~v11: 1. Rebase to the newest codes 2. Address comment from Max Don't use contractions in error messages, p1: Remove R-Bs, and use "BdrvChild *child" in bdrv_del_child p2:

[Qemu-devel] [PATCH v2 2/2] usb: trivial cleanup for usb_mtp_add_str

2016-03-09 Thread Peter Xu
Remove useless var "ret". Signed-off-by: Peter Xu --- hw/usb/dev-mtp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c index 62fb7cd..3c11148 100644 --- a/hw/usb/dev-mtp.c +++ b/hw/usb/dev-mtp.c @@ -719,10 +719,8 @@

[Qemu-devel] [PATCH v2 1/2] usb: fix unbound stack usage for usb_mtp_add_str

2016-03-09 Thread Peter Xu
Use heap instead of stack. Signed-off-by: Peter Xu --- hw/usb/dev-mtp.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c index 7391783..62fb7cd 100644 --- a/hw/usb/dev-mtp.c +++ b/hw/usb/dev-mtp.c @@ -718,7 +718,7 @@

Re: [Qemu-devel] [PATCH v3 1/1] block/sheepdog: fix argument passed to qemu_strtoul()

2016-03-09 Thread Jeff Cody
On Wed, Mar 02, 2016 at 11:24:42AM -0500, Jeff Cody wrote: > The function qemu_strtoul() reads 'unsigned long' sized data, > which is larger than uint32_t on 64-bit machines. > > Even though the snap_id field in the header is 32-bits, we must > accomodate the full size in qemu_strtoul(). > >

[Qemu-devel] [PATCH v2 0/2] usb: trivial fixes

2016-03-09 Thread Peter Xu
Patch 1 fixes one unbounded stack warning case. Sending patch 2 again for convenience, please just drop it if we do not need it. Thanks. Peter Xu (2): usb: fix unbound stack usage for usb_mtp_add_str usb: trivial cleanup for usb_mtp_add_str hw/usb/dev-mtp.c | 8 1 file changed, 4

Re: [Qemu-devel] [PULL 00/14] Net patches

2016-03-09 Thread Jason Wang
On 03/08/2016 05:54 PM, Peter Maydell wrote: > On 8 March 2016 at 16:06, Zhang Chen wrote: >> I found the reason for this problem is that >> unix_connect() have not connect to sock_path before iov_send(). >> It need time to establish connection. so can we fix it

Re: [Qemu-devel] [PATCH 1/2] usb: fix unbound stack usage for usb_mtp_add_str

2016-03-09 Thread Peter Xu
On Thu, Mar 10, 2016 at 09:54:41AM +0800, Fam Zheng wrote: > On Wed, 03/09 14:10, Peter Xu wrote: > > +wchar_t *wstr = g_malloc(sizeof(wchar_t) * len); > > I think it is better to use g_new() in this case. Okay. Will re-send this one. Thanks. Peter

[Qemu-devel] [PATCH] usb: fix unbounded stack warning for xhci_dma_write_u32s

2016-03-09 Thread Peter Xu
Signed-off-by: Peter Xu --- hw/usb/hcd-xhci.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index 44b6f8c..d15918f 100644 --- a/hw/usb/hcd-xhci.c +++ b/hw/usb/hcd-xhci.c @@ -698,11 +698,13 @@ static inline void

Re: [Qemu-devel] [PATCH 4/8] usb: fix unbounded stack for xhci_dma_write_u32s

2016-03-09 Thread Peter Xu
On Wed, Mar 09, 2016 at 01:59:03PM +0100, Paolo Bonzini wrote: > If you look at users, they only write about 20 bytes at most. My > suggestion is to use your patch, and replace > > assert(__BUF_SIZE >= n); > > with > > assert(n < ARRAY_SIZE(tmp)); > > Then you don't need the #define.

Re: [Qemu-devel] [PATCH v2 06/11] pci: add a is_valid_func callback to check device if complete

2016-03-09 Thread Chen Fan
On 03/10/2016 01:14 AM, Michael S. Tsirkin wrote: On Wed, Mar 09, 2016 at 09:50:31AM -0700, Alex Williamson wrote: On Wed, 9 Mar 2016 18:22:24 +0200 "Michael S. Tsirkin" wrote: On Mon, Mar 07, 2016 at 11:22:59AM +0800, Cao jin wrote: From: Chen Fan

Re: [Qemu-devel] [PATCH v11 2/3] quorum: implement bdrv_add_child() and bdrv_del_child()

2016-03-09 Thread Changlong Xie
On 03/10/2016 02:11 AM, Max Reitz wrote: On 09.03.2016 04:51, Changlong Xie wrote: From: Wen Congyang Signed-off-by: Wen Congyang Signed-off-by: zhanghailiang Signed-off-by: Gonglei

Re: [Qemu-devel] [PATCH 2/2] usb: trivial cleanup for usb_mtp_add_str

2016-03-09 Thread Fam Zheng
On Wed, 03/09 14:10, Peter Xu wrote: > Remove useless var "ret". > > Signed-off-by: Peter Xu > --- > hw/usb/dev-mtp.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c > index cf63fd0..38cc4fc 100644 > ---

Re: [Qemu-devel] Memory on stellaris board

2016-03-09 Thread Peter Maydell
On 10 March 2016 at 07:23, Aurelio Remonda wrote: > > El 9 mar. 2016 8:25 PM, "Peter Maydell" escribió: >> You should reject unworkable ram sizes rather than silently >> changing what the user asked for; this matches our preferred

Re: [Qemu-devel] [PATCH 1/2] usb: fix unbound stack usage for usb_mtp_add_str

2016-03-09 Thread Fam Zheng
On Wed, 03/09 14:10, Peter Xu wrote: > Use heap instead of stack. > > Signed-off-by: Peter Xu > --- > hw/usb/dev-mtp.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c > index 7391783..cf63fd0 100644 > ---

Re: [Qemu-devel] [PATCH v2 3/3] vmdk: Switch to heap arrays for vmdk_parent_open

2016-03-09 Thread Fam Zheng
On Wed, 03/09 10:50, Kevin Wolf wrote: > Am 09.03.2016 um 01:43 hat Fam Zheng geschrieben: > > On Tue, 03/08 16:24, Fam Zheng wrote: > > > Signed-off-by: Fam Zheng > > > --- > > > block/vmdk.c | 17 +++-- > > > 1 file changed, 11 insertions(+), 6 deletions(-) > > >

Re: [Qemu-devel] [PATCH 5/8] virtio-blk: fix "disabled data plane" mode

2016-03-09 Thread Fam Zheng
On Wed, 03/09 17:17, Paolo Bonzini wrote: > > > On 09/03/2016 15:29, Christian Borntraeger wrote: > > FWIW, it seems that this patch triggers this error, the > > "tracked_request_begin" > > that I reported yesterday and / or some early read issues from the > > bootloader > > in a random

Re: [Qemu-devel] [PATCH 1/2] block/qapi: make two printf() formats literal

2016-03-09 Thread Peter Xu
On Wed, Mar 09, 2016 at 03:14:03PM -0700, Eric Blake wrote: > > +func_fprintf(f, "%*s[%i]:%c", indentation * 4, "", i, > > + composite ? '\n' : ' '); > > [The nerd in me wants to point out that you could avoid the ternary by > writing '"\n "[composite]', but that's too

Re: [Qemu-devel] [RFC qemu 0/4] A PV solution for live migration optimization

2016-03-09 Thread Li, Liang Z
> > > > > Yes, we really can teach qemu to skip these pages and it's not hard. > > > > > The problem is the poor performance, this PV solution > > > > > > > > Balloon is always PV. And do not call patches solutions please. > > > > > > > > > is aimed to make it more > > > > > efficient and reduce

Re: [Qemu-devel] [PATCH] qdict: fix unbounded stack for qdict_array_entries

2016-03-09 Thread Peter Xu
Sorry to forgot CCing Eric/Markus/Kevin. This patch title is not correct, which should be: "Fix unbounded stack warning for qdict_array_entries" Do I need to re-send with the same content? I'm using g_strdup_printf() here, considering it's most convenient, safe, and as long as it's called

Re: [Qemu-devel] [PATCH 1/8] qdict: fix unbounded stack for qdict_array_entries

2016-03-09 Thread Peter Xu
On Wed, Mar 09, 2016 at 10:03:51PM +0100, Markus Armbruster wrote: > Kevin Wolf writes: > > I think it's unnecessary, but fine with me. I'm just trying to say that > > making it a fixed 128 byte array on the stack certainly doesn't improve > > anything. > > It trades a few

Re: [Qemu-devel] [PATCH] exec;fix early return from ram_block_add

2016-03-09 Thread Fam Zheng
On Wed, 03/09 18:16, Paolo Bonzini wrote: In the subject: s/;/: / > After reporting an error, ram_block_add was going on with the registration > of the RAMBlock. The visible effect is that it unlocked the ramlist > mutex twice. > > Fixes: 528f46af6ecd1e300db18684969104d4067b867b Yes, this

[Qemu-devel] [PATCH v5 13/14] qapi: Allow anonymous base for flat union

2016-03-09 Thread Eric Blake
Rather than requiring all flat unions to explicitly create a separate base struct, we can allow the qapi schema to specify the common members via an inline dictionary. This is similar to how commands can specify an inline anonymous type for its 'data'. We already have several struct types that

[Qemu-devel] [PATCH v5 05/14] qapi: Emit implicit structs in generated C

2016-03-09 Thread Eric Blake
We already have several places that want to visit all the members of an implicit object within a larger context (simple union variant, event with anonymous data, command with anonymous arguments struct); and will be adding another one soon (the ability to declare an anonymous base for a flat

[Qemu-devel] [PATCH v5 11/14] qapi: Don't special-case simple union wrappers

2016-03-09 Thread Eric Blake
Simple unions were carrying a special case that hid their 'data' QMP member from the resulting C struct, via the hack method QAPISchemaObjectTypeVariant.simple_union_type(). But by using the work we started by unboxing flat union and alternate branches, coupled with the ability to visit the

[Qemu-devel] [PATCH v5 10/14] qapi: Drop unused c_null()

2016-03-09 Thread Eric Blake
Now that we are always bulk-initializing a QAPI C struct to 0 (whether by g_malloc0() or by 'Type qapi = {0};'), we no longer have any clients of c_null() in the generator for per-element initialization. This patch is easy enough to revert if we find a use in the future, but in the present, get

[Qemu-devel] [PATCH v5 12/14] qapi: Make BlockdevOptions doc example closer to reality

2016-03-09 Thread Eric Blake
Although we don't want to repeat the entire BlockdevOptions QMP command in the example, it helps if we aren't needlessly diverging (the initial example was written before we had committed the actual QMP interface). Use names that match what is found in qapi/block-core.json, such as '*read-only'

Re: [Qemu-devel] [PULL 3/8] vfio: Generalize region support

2016-03-09 Thread Eric Auger
Hi Alex, On 03/09/2016 08:53 PM, Alex Williamson wrote: > Both platform and PCI vfio drivers create a "slow", I/O memory region > with one or more mmap memory regions overlayed when supported by the > device. Generalize this to a set of common helpers in the core that > pulls the region info from

[Qemu-devel] [PATCH v5 14/14] qapi: Use anonymous bases in QMP flat unions

2016-03-09 Thread Eric Blake
Now that the generator supports it, we might as well use an anonymous base rather than breaking out a single-use Base structure, for all three of our current QMP flat unions. Oddly enough, this change does not affect the resulting introspection output (because we already inline the members of a

[Qemu-devel] [PATCH v5 08/14] qapi-commands: Inline single-use helpers of gen_marshal()

2016-03-09 Thread Eric Blake
Originally, gen_marshal_input_visit() (or gen_visitor_input_block() before commit f1538019) was factored out to make it easy to do two passes of a visit to each member of a (possibly-implicit) object, without duplicating lots of code. But after recent changes, those visits now occupy a single

[Qemu-devel] [PATCH v5 00/14] easier unboxed visits/qapi implicit types

2016-03-09 Thread Eric Blake
Addresses Markus' comments on v4; the series was pretty close, and most of the changes here are a new naming scheme ('q_obj' rather than ':obj') and additional cleanups (for example, c_null() is unused). I dropped patch 10, but the new patches make the series a bit longer. Built directly on

[Qemu-devel] [PATCH v5 04/14] qapi: Adjust names of implicit types

2016-03-09 Thread Eric Blake
The original choice of ':obj-' as the prefix for implicit types made it obvious that we weren't going to clash with any user-defined names. But now we want to create structs for implicit types. We could transliterate ':' to '_', except that C99 says that a leading underscore and lower-case

[Qemu-devel] [PATCH v5 09/14] qapi: Inline gen_visit_members() into lone caller

2016-03-09 Thread Eric Blake
Commit 82ca8e46 noticed that we had multiple implementations of visiting every member of a struct, and consolidated it into gen_visit_fields() (now gen_visit_members()) with enough parameters to cater to slight differences between the clients. But recent exposure of implicit types has meant that

[Qemu-devel] [PATCH v5 02/14] qapi: Fix command with named empty argument type

2016-03-09 Thread Eric Blake
The generator special-cased { 'command':'foo', 'data': {} } to avoid emitting a visitor variable, but failed to see that { 'struct':'NamedEmptyType, 'data': {} } { 'command':'foo', 'data':'NamedEmptyType' } needs the same treatment. There, the generator happily generates a visitor to get

[Qemu-devel] [PATCH v5 07/14] qapi: Utilize implicit struct visits

2016-03-09 Thread Eric Blake
Rather than generate inline per-member visits, take advantage of the 'visit_type_FOO_members()' function for both event and command marshalling. This is possible now that implicit structs can be visited like any other. Generated code shrinks accordingly; events initialize a struct based on

[Qemu-devel] [PATCH v5 01/14] qapi: Assert in places where variants are not handled

2016-03-09 Thread Eric Blake
We are getting closer to the point where we could use one union as the base or variant type within another union type (as long as there are no collisions between any possible combination of member names allowed across all discriminator choices). But until we get to that point, it is worth

[Qemu-devel] [PATCH v5 03/14] qapi: Make c_type() more OO-like

2016-03-09 Thread Eric Blake
QAPISchemaType.c_type() is a bit awkward: it takes two optional boolean flags is_param and is_unboxed, and they should never both be True. Add a new method for each of the flags, and drop the flags from c_type(). Most callers pass no flags; they remain unchanged. One caller passes

[Qemu-devel] [PATCH v5 06/14] qapi-event: Slightly shrink generated code

2016-03-09 Thread Eric Blake
Slightly rearrange the code in gen_event_send() for less generated output, by initializing 'emit' sooner, deferring an assertion to qdict_put_obj, and dropping a now-unused 'obj' local variable. While at it, document a FIXME related to the potential for a compiler naming collision - if the user

Re: [Qemu-devel] [PATCH v2 33/42] ivshmem: Implement shm=... with a memory backend

2016-03-09 Thread Marc-André Lureau
Hi On Wed, Mar 9, 2016 at 9:59 PM, Markus Armbruster wrote: > I didn't do this now, because one, I'm not aware of a system that needs > it, and two, ivshmem is Linux-specific anyway. ivshmem-plain could be > made more portable, and once that's done, memory-backend-shm might >

Re: [Qemu-devel] [PATCH v2 05/42] ivshmem-server: Don't overload POSIX shmem and file name

2016-03-09 Thread Marc-André Lureau
Hi On Wed, Mar 9, 2016 at 9:14 PM, Markus Armbruster wrote: >> @@ -77,7 +77,7 @@ ivshmem_server_parse_args(IvshmemServerArgs *args, int >> argc, char *argv[]) >> "F" /* foreground */ >> "p:" /* pid_file */ >>

Re: [Qemu-devel] [PATCH v2 28/42] ivshmem: Propagate errors through ivshmem_recv_setup()

2016-03-09 Thread Marc-André Lureau
On Wed, Mar 9, 2016 at 9:25 PM, Markus Armbruster wrote: > Now let me explain *why* I want the assertion. The purpose of the > previous patch and this one is to ensure that the realized device always > has the shared memory mapped. The loop does that, but it's not 100% >

Re: [Qemu-devel] Memory on stellaris board

2016-03-09 Thread Aurelio Remonda
El 9 mar. 2016 8:25 PM, "Peter Maydell" escribió: > > On 10 March 2016 at 03:56, Aurelio Remonda > wrote: > > > > > > On Mon, Mar 7, 2016 at 8:37 PM, Peter Maydell > > wrote: > >> > >> On 8 March 2016 at

Re: [Qemu-devel] [RFC PATCH v1 05/10] cpu: Abstract CPU core type

2016-03-09 Thread David Gibson
On Wed, Mar 09, 2016 at 11:40:53AM +0100, Igor Mammedov wrote: > On Tue, 8 Mar 2016 15:26:27 +1100 > David Gibson wrote: > > On Mon, Mar 07, 2016 at 11:29:29AM +0100, Igor Mammedov wrote: > > > On Mon, 7 Mar 2016 14:36:55 +1100 > > > David Gibson

Re: [Qemu-devel] [PATCH v4 05/10] qapi: Utilize implicit struct visits

2016-03-09 Thread Eric Blake
On 03/08/2016 09:11 AM, Eric Blake wrote: >>> >>> -ret += gen_visit_members(arg_type.members, skiperr=dealloc) >> >> Unless I'm mistaken, this is the only use of skiperr. Follow up with a >> patch to drop the parameter and simplify? > > Oh, nice. I noticed some cleanups in patch 6/10, but

Re: [Qemu-devel] [RFC] [tcg] Idea on refactoring target code generation loop (gen_intermediate_code)

2016-03-09 Thread Peter Maydell
On 10 March 2016 at 05:29, Lluís Vilanova wrote: > Richard Henderson writes: >> Alternately... can we broach the subject of C++? Honestly, it >> seems we work too hard sometimes to re-implement templates and >> classes in C. > > Whooo, I'd really *love* to switch to C++ just

Re: [Qemu-devel] Memory on stellaris board

2016-03-09 Thread Peter Maydell
On 10 March 2016 at 03:56, Aurelio Remonda wrote: > > > On Mon, Mar 7, 2016 at 8:37 PM, Peter Maydell > wrote: >> >> On 8 March 2016 at 02:58, Aurelio Remonda >> wrote: >> > Hello, sorry

Re: [Qemu-devel] [RFC] [tcg] Idea on refactoring target code generation loop (gen_intermediate_code)

2016-03-09 Thread Lluís Vilanova
Richard Henderson writes: > On 03/09/2016 01:16 PM, Lluís Vilanova wrote: >> Richard Henderson writes: >> >>> On 03/09/2016 09:38 AM, Lluís Vilanova wrote: Hi, NOTE: I won't be throwing patches anytime soon, I just want to know if there's interest in this for the

Re: [Qemu-devel] [PATCH v2] block/gluster: add support for SEEK_DATA/SEEK_HOLE

2016-03-09 Thread Jeff Cody
On Wed, Mar 09, 2016 at 07:12:41PM +0100, Niels de Vos wrote: > On Wed, Mar 09, 2016 at 10:46:02AM -0500, Jeff Cody wrote: > > On Wed, Mar 09, 2016 at 01:30:14PM +0100, Niels de Vos wrote: > > > GlusterFS 3.8 contains support for SEEK_DATA and SEEK_HOLE. This makes > > > it possible to detect

Re: [Qemu-devel] [PATCH 2/2] block/qapi: fix unbounded stack for dump_qdict

2016-03-09 Thread Eric Blake
On 03/08/2016 10:56 PM, Peter Xu wrote: > Using heap instead of stack for better safety. > > Signed-off-by: Peter Xu > --- > block/qapi.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by: Eric Blake > > diff --git a/block/qapi.c

Re: [Qemu-devel] [PATCH 1/2] block/qapi: make two printf() formats literal

2016-03-09 Thread Eric Blake
On 03/08/2016 10:56 PM, Peter Xu wrote: > Fix two places to use literal printf format when possible. > > Signed-off-by: Peter Xu > --- > block/qapi.c | 10 -- > 1 file changed, 4 insertions(+), 6 deletions(-) Reviewed-by: Eric Blake > > diff

Re: [Qemu-devel] [PATCH for-2.6 04/10] s390x/cpu: Tolerate max_cpus

2016-03-09 Thread Thomas Huth
On 09.03.2016 18:28, Cornelia Huck wrote: > From: Matthew Rosato > > Once hotplug is enabled, interrupts may come in for CPUs > with an address > smp_cpus. Allocate for this and allow > search routines to look beyond smp_cpus. > > Signed-off-by: Matthew Rosato

Re: [Qemu-devel] [PATCH v1 12/21] io: implement socket watch for win32 using WSAEventSelect+select

2016-03-09 Thread Paolo Bonzini
On 09/03/2016 20:59, Eric Blake wrote: > On 03/09/2016 10:47 AM, Paolo Bonzini wrote: >> > On 09/03/2016 18:28, Daniel P. Berrange wrote: >>> >> From: Paolo Bonzini >> > >> > Reviewing my own patch looks weird. :) >> > >>> >> On Win32 we cannot directly poll on socket

Re: [Qemu-devel] [PATCH 0/3] input: linux evdev support

2016-03-09 Thread Paolo Bonzini
On 04/03/2016 11:25, Gerd Hoffmann wrote: > Hi, > > This patch series adds support for reading input events directly from > linux input devices instead of getting them from the UI (gtk/spice/...). > This is useful if you pci passthrough your vga, because you don't need > some otherwise dummy

Re: [Qemu-devel] [Qemu-ppc] [PATCH 72/77] ppc: A couple more dummy POWER8 Book4 regs

2016-03-09 Thread Thomas Huth
On 09.03.2016 21:04, Cédric Le Goater wrote: > On 03/02/2016 09:30 PM, Thomas Huth wrote: >> On 11.11.2015 01:28, Benjamin Herrenschmidt wrote: >>> WORT and PID this time >>> ... >> AFAICT all patches where you define new SPRs with spr_register_kvm[_hv] >> are also important independently of the

Re: [Qemu-devel] [PATCH 1/8] qdict: fix unbounded stack for qdict_array_entries

2016-03-09 Thread Markus Armbruster
Kevin Wolf writes: > Am 09.03.2016 um 14:23 hat Markus Armbruster geschrieben: >> Kevin Wolf writes: >> >> > Am 09.03.2016 um 04:04 hat Eric Blake geschrieben: >> >> On 03/08/2016 07:57 PM, Peter Xu wrote: >> >> > On Tue, Mar 08, 2016 at 11:19:44AM +0100,

Re: [Qemu-devel] [PATCH v2 33/42] ivshmem: Implement shm=... with a memory backend

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Mon, Mar 7, 2016 at 8:25 PM, Markus Armbruster wrote: >> ivshmem has its very own code to create and map shared memory. >> Replace that with an implicitly created memory backend. Reduces the >> number of ways

Re: [Qemu-devel] Memory on stellaris board

2016-03-09 Thread Aurelio Remonda
On Mon, Mar 7, 2016 at 8:37 PM, Peter Maydell wrote: > > On 8 March 2016 at 02:58, Aurelio Remonda > wrote: > > Hello, sorry for taking so long, I am working on this again. > > About your last response, I was looking at the struct

Re: [Qemu-devel] [PATCH v2 28/42] ivshmem: Propagate errors through ivshmem_recv_setup()

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Mon, Mar 7, 2016 at 8:25 PM, Markus Armbruster wrote: >> This kills off the funny state described in the previous commit. >> >> Simplify ivshmem_io_read() accordingly, and update documentation. >> >>

Re: [Qemu-devel] [PATCH v2 22/42] ivshmem: Leave INTx alone when using MSI-X

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Mon, Mar 7, 2016 at 8:25 PM, Markus Armbruster wrote: >> The ivshmem device can either use MSI-X or legacy INTx for interrupts. >> >> With MSI-X enabled, peer interrupt events trigger an MSI as they >> should.

Re: [Qemu-devel] [PATCH 2/2] postcopy: Remove the x-

2016-03-09 Thread Dr. David Alan Gilbert
* Eric Blake (ebl...@redhat.com) wrote: > On 03/09/2016 12:50 PM, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Postcopy seems to have survived a cycle with only a few fixes, > > and Jiri has the current libvirt wired up and working > > (

Re: [Qemu-devel] [PATCH v2 21/42] ivshmem: Clean up MSI-X conditions

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Mon, Mar 7, 2016 at 8:25 PM, Markus Armbruster wrote: >> There are three predicates related to MSI-X: >> >> * ivshmem_has_feature(s, IVSHMEM_MSI) is true unless the non-MSI-X >> variant of the device is

Re: [Qemu-devel] [PATCH v2 05/42] ivshmem-server: Don't overload POSIX shmem and file name

2016-03-09 Thread Markus Armbruster
Marc-André Lureau writes: > Hi > > On Mon, Mar 7, 2016 at 8:25 PM, Markus Armbruster wrote: >> Option -m NAME is interpreted as directory name if we can statfs() it >> and its on hugetlbfs. Else it's interpreted as POSIX shared memory >> object

Re: [Qemu-devel] [PATCH 2/2] postcopy: Remove the x-

2016-03-09 Thread Eric Blake
On 03/09/2016 12:50 PM, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Postcopy seems to have survived a cycle with only a few fixes, > and Jiri has the current libvirt wired up and working > (

  1   2   3   4   >