Re: [Qemu-devel] [PATCH 1/1] migration: qemu_savevm_state_cleanup becomes mandatory operation

2015-11-09 Thread Li, Liang Z
> >>> Yes, you are right. Thanks a lot. > >>> > >>> BTW, can this patch fix the regression you reported? > >>> > >>> Reviewed-by: Liang Li > >>> > >> yes > > Great. You'd better change the commit message to make it more clear. > > > > Liang > argh.. you are right... > > This problem has appeared

Re: [Qemu-devel] [PATCH v2] virtio-blk: trivial code optimization

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 04:19, arei.gong...@huawei.com wrote: > + * 1. requests are not sequential > + * 2. merge would exceed maximum number of IOVs > + * 3. merge would exceed maximum transfer length of backend > device > + */ > +if (sector_num

Re: [Qemu-devel] [PATCH for-2.5 1/1] spapr: Handle failure of KVM_PPC_ALLOCATE_HTAB ioctl

2015-11-09 Thread David Gibson
On Mon, Nov 09, 2015 at 03:24:15PM +1100, David Gibson wrote: > On Tue, Nov 03, 2015 at 03:38:19PM +0530, Bharata B Rao wrote: > > KVM_PPC_ALLOCATE_HTAB ioctl can return -ENOMEM for KVM guests and QEMU > > never handled this correctly. But this didn't cause any problems till > > now as KVM_PPC_ALLO

Re: [Qemu-devel] [PATCH qemu] spapr: Add /system-id

2015-11-09 Thread David Gibson
On Mon, Nov 09, 2015 at 05:47:17PM +1100, Alexey Kardashevskiy wrote: > Section B.6.2.1 Root Node Properties of PAPR specification defines > a set of properties which shall be present in the device tree root, > one of these properties is "system-id" which "should be unique across > all systems and

Re: [Qemu-devel] [PATCH v2] virtio-blk: trivial code optimization

2015-11-09 Thread Gonglei
On 2015/11/9 16:41, Paolo Bonzini wrote: > > > On 09/11/2015 04:19, arei.gong...@huawei.com wrote: >> + * 1. requests are not sequential >> + * 2. merge would exceed maximum number of IOVs >> + * 3. merge would exceed maximum transfer length of backend >> devi

Re: [Qemu-devel] [PATCH COLO-Frame v10 11/38] QEMUSizedBuffer: Introduce two help functions for qsb

2015-11-09 Thread zhanghailiang
On 2015/11/7 2:30, Dr. David Alan Gilbert wrote: * zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: Introduce two new QEMUSizedBuffer APIs which will be used by COLO to buffer VM state: One is qsb_put_buffer(), which put the content of a given QEMUSizedBuffer into QEMUFile, this is used to

Re: [Qemu-devel] [PATCH v9 00/56] Postcopy implementation

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 05:13, David Gibson wrote: > Which makes me think it's a bit odd that we're not already getting > most of the htab data across during the precopy phase. Don't we > already delay entering the postcopy phase until precopy is > "complete" in the sense that the remaining non-postcopi

Re: [Qemu-devel] [PATCH v9 00/56] Postcopy implementation

2015-11-09 Thread Dr. David Alan Gilbert
* Bharata B Rao (bhar...@linux.vnet.ibm.com) wrote: > On Fri, Nov 06, 2015 at 03:48:11PM +, Dr. David Alan Gilbert wrote: > > * Bharata B Rao (bhar...@linux.vnet.ibm.com) wrote: > > > > > > Where we have iterable, but non-postcopiable devices (e.g. htab > > > > or block migration), complete th

Re: [Qemu-devel] Qemu: Guest Linux hangs on Mac OS X 10.11

2015-11-09 Thread Paolo Bonzini
On 08/11/2015 23:55, Peter Maydell wrote: > So the good news is that on mainline this doesn't happen any more. > The bad news is that something weird is going on such that git > bisect doesn't give helpful answers. Specifically if I start by > compiling older versions and work forwards, then > 0

Re: [Qemu-devel] [PATCH COLO-Frame v10 12/38] COLO: Save PVM state to secondary side when do checkpoint

2015-11-09 Thread zhanghailiang
On 2015/11/7 2:59, Dr. David Alan Gilbert wrote: * zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: The main process of checkpoint is to synchronize SVM with PVM. VM's state includes ram and device state. So we will migrate PVM's state to SVM when do checkpoint, just like migration does. W

Re: [Qemu-devel] [PATCH v9 04/56] Move page_size_init earlier

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > The HOST_PAGE_ALIGN macros don't work until the page size variables > have been set up; later in postcopy I use those macros in the RAM > code, and it can be triggered using -object. > > Fix this by initialising page_size_

Re: [Qemu-devel] [PATCH v9 06/56] qemu_ram_block_by_name

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Add a function to find a RAMBlock by name; use it in two > of the places that already open code that loop; we've > got another use later in postcopy. > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela

Re: [Qemu-devel] [PATCH v3 8/9] block: Introduce BlockDriver.bdrv_drain callback

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 03:56, Fam Zheng wrote: > +if (bs->drv && bs->drv->bdrv_drain) { > +bs->drv->bdrv_drain(bs); > +} > +QLIST_FOREACH(child, &bs->children, next) { > +BlockDriverState *cbs = child->bs; > +if (cbs->drv && cbs->drv->bdrv_drain) { > +cbs->d

Re: [Qemu-devel] [PATCH v9 08/56] Add qemu_get_buffer_in_place to avoid copies some of the time

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > qemu_get_buffer always copies the data it reads to a users buffer, > however in many cases the file buffer inside qemu_file could be given > back to the caller, avoiding the copy. This isn't always possible > depending on

Re: [Qemu-devel] [PATCH v9 12/56] ram_load: Factor out host_from_stream_offset call and check

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > The main RAM load loop has a call to host_from_stream_offset for > each page type that actually loads data with the same test; > factor it out before the switch. > > The host = NULL is to silence a bogus gcc warning of > a

Re: [Qemu-devel] [PATCH v9 15/56] Add Linux userfaultfd.h header

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Postcopy uses the userfaultfd.h feature in the Linux kernel; include > the header. > > (In early versions of the patch series we had this, and then we dropped > this by only including it if the kernel headers defined the s

Re: [Qemu-devel] [PATCH RFC 3/5] qapi: Use common name mangling for enumeration constants

2015-11-09 Thread Markus Armbruster
"Daniel P. Berrange" writes: > On Thu, Nov 05, 2015 at 04:30:00PM +0100, Markus Armbruster wrote: >> QAPI names needn't be valid C identifiers, so we mangle them with >> c_name(). Except for enumeration constants, which we mangle with >> camel_to_upper(). >> >> c_name() is easy enough to unders

Re: [Qemu-devel] [PATCH v3 8/9] block: Introduce BlockDriver.bdrv_drain callback

2015-11-09 Thread Fam Zheng
On Mon, 11/09 10:24, Paolo Bonzini wrote: > > > On 09/11/2015 03:56, Fam Zheng wrote: > > +if (bs->drv && bs->drv->bdrv_drain) { > > +bs->drv->bdrv_drain(bs); > > +} > > +QLIST_FOREACH(child, &bs->children, next) { > > +BlockDriverState *cbs = child->bs; > > +i

Re: [Qemu-devel] [PATCH 3/3] block/gluster: add support for multiple gluster servers

2015-11-09 Thread Prasanna Kumar Kalever
On Monday, November 9, 2015 12:34:45 PM, Peter Krempa wrote: > On Thu, Nov 05, 2015 at 07:45:50 -0500, Prasanna Kumar Kalever wrote: > > On Thursday, November 5, 2015 6:07:06 PM, Prasanna Kumar Kalever wrote: > > > This patch adds a way to specify multiple volfile servers to the gluster > > > block

Re: [Qemu-devel] [PATCH 0/2] memory: Eliminate qemu_ram_free_from_ptr() & memory_region_destructor_ram_from_ptr()

2015-11-09 Thread Paolo Bonzini
On 06/11/2015 22:20, Eduardo Habkost wrote: > This series eliminates two functions that are not needed anymore: > qemu_ram_free_from_ptr(), and memory_region_destructor_ram_from_ptr(). > > Eduardo Habkost (2): > exec: Eliminate qemu_ram_free_from_ptr() > memory: Eliminate memory_region_destr

Re: [Qemu-devel] [PATCH] exec: Remove unnecessary RAM_FILE flag

2015-11-09 Thread Paolo Bonzini
On 06/11/2015 23:11, Eduardo Habkost wrote: > The only code that sets RAMBlock.fd is file_ram_alloc(), and the only > code that calls file_ram_alloc() sets the RAM_FILE flag. That means the > flag is always set when RAMBlock.fd >= 0, and the munmap() call at > reclaim_ramblock() is dead code that

Re: [Qemu-devel] [PATCH v10 00/30] qapi member collision (post-introspection cleanups, subset C')

2015-11-09 Thread Markus Armbruster
Eric Blake writes: > On 11/06/2015 09:03 AM, Markus Armbruster wrote: >> Eric Blake writes: [...] >>> Hopefully, we are converging on something that will be ready >>> for a pull request, especially for the earlier patches of this >>> subset. >> >> I guess you mean PATCH 01-12. I had a few ques

Re: [Qemu-devel] [PULL 0/7] Block patches

2015-11-09 Thread Stefan Hajnoczi
On Mon, Nov 09, 2015 at 08:35:56AM +0100, Markus Armbruster wrote: > Fam Zheng writes: > > > On Fri, 11/06 18:07, Peter Maydell wrote: > >> On 6 November 2015 at 17:52, Stefan Hajnoczi wrote: > >> > The following changes since commit > >> > 4b59f39bc9a03afcc74b2fa28da7c3189fca507c: > >> > > >>

[Qemu-devel] [PATCH v3] virtio-blk: trivial code optimization

2015-11-09 Thread arei.gonglei
From: Gonglei 1. avoid possible superflous checking 2. make code more robustness Signed-off-by: Gonglei Reviewed-by: Fam Zheng --- v3: change the third condition too [Paolo] add Fam's R-by --- hw/block/virtio-blk.c | 27 +-- 1 file changed, 9 insertions(+), 18 dele

Re: [Qemu-devel] [PATCH] hw/arm/virt: error_report cleanups

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 07:44, Markus Armbruster wrote: > For consistency, error messages should be a phrase, not a full sentence, > let alone a paraphraph. This is in direct conflict with wanting them to be actually useful to users :-( thanks -- PMM

[Qemu-devel] [PATCH v12 3/3] block/gluster: add support for multiple gluster servers

2015-11-09 Thread Prasanna Kumar Kalever
This patch adds a way to specify multiple volfile servers to the gluster block backend of QEMU with tcp|rdma transport types and their port numbers. Problem: Currently VM Image on gluster volume is specified like this: file=gluster[+tcp]://host[:port]/testvol/a.img Assuming we have three hosts

[Qemu-devel] [PATCH 0/3] block/gluster: add support for multiple gluster servers

2015-11-09 Thread Prasanna Kumar Kalever
Prasanna Kumar Kalever (3): block/gluster: rename [server, volname, image] -> [host, volume, path] block/gluster: code cleanup block/gluster: add support for multiple gluster servers block/gluster.c | 589 --- qapi/block-core.json | 64 +

Re: [Qemu-devel] Qemu: Guest Linux hangs on Mac OS X 10.11

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 09:10, Paolo Bonzini wrote: > > > On 08/11/2015 23:55, Peter Maydell wrote: >> So the good news is that on mainline this doesn't happen any more. >> The bad news is that something weird is going on such that git >> bisect doesn't give helpful answers. Specifically if I start

[Qemu-devel] [PULL v2 5/7] aio: Introduce aio-epoll.c

2015-11-09 Thread Stefan Hajnoczi
From: Fam Zheng To minimize code duplication, epoll is hooked into aio-posix's aio_poll() instead of rolling its own. This approach also has both compile-time and run-time switchability. 1) When QEMU starts with a small number of fds in the event loop, ppoll is used. 2) When QEMU starts with a

[Qemu-devel] [PULL v2 4/7] aio: Introduce aio_context_setup

2015-11-09 Thread Stefan Hajnoczi
From: Fam Zheng This is the place to initialize platform specific bits of AioContext. Signed-off-by: Fam Zheng Message-id: 1446177989-6702-3-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi --- aio-posix.c | 4 aio-win32.c | 4 async.c | 13

[Qemu-devel] [PULL v2 0/7] Block patches

2015-11-09 Thread Stefan Hajnoczi
The following changes since commit c4a7bf54e588ff2de9fba0898b686156251b2063: Merge remote-tracking branch 'remotes/jnsnow/tags/ide-pull-request' into staging (2015-11-07 19:55:15 +) are available in the git repository at: git://github.com/stefanha/qemu.git tags/block-pull-request for y

[Qemu-devel] [PULL v2 1/7] dataplane: simplify indirect descriptor read

2015-11-09 Thread Stefan Hajnoczi
From: "Michael S. Tsirkin" Use address_space_read to make sure we handle the case of an indirect descriptor crossing DIMM boundary correctly. Signed-off-by: Michael S. Tsirkin Reviewed-by: Stefan Hajnoczi Tested-by: Igor Mammedov Message-id: 1446047243-3221-1-git-send-email-...@redhat.com Sig

[Qemu-devel] [PULL v2 2/7] dataplane: support non-contigious s/g

2015-11-09 Thread Stefan Hajnoczi
From: "Michael S. Tsirkin" bring_map currently fails if one of the entries it's mapping is contigious in GPA but not HVA address space. Introduce a mapped_len parameter so it can handle this, returning the actual mapped length. This will still fail if there's no space left in the sg, but luckil

[Qemu-devel] [PULL v2 7/7] blockdev: acquire AioContext in hmp_commit()

2015-11-09 Thread Stefan Hajnoczi
This one slipped through. Although we acquire AioContext when committing all devices we don't for just a single device. AioContext must be acquired before calling bdrv_*() functions to synchronize access with other threads that may be using the AioContext. Signed-off-by: Stefan Hajnoczi Signed-

[Qemu-devel] [PULL v2 3/7] aio: Introduce aio_external_disabled

2015-11-09 Thread Stefan Hajnoczi
From: Fam Zheng This allows AioContext users to check the enable/disable state of external clients. Signed-off-by: Fam Zheng Message-id: 1446177989-6702-2-git-send-email-f...@redhat.com Signed-off-by: Stefan Hajnoczi --- include/block/aio.h | 11 +++ 1 file changed, 11 insertions(+)

[Qemu-devel] [PULL v2 6/7] monitor: add missed aio_context_acquire into vm_completion call

2015-11-09 Thread Stefan Hajnoczi
From: "Denis V. Lunev" Signed-off-by: Denis V. Lunev CC: Stefan Hajnoczi CC: Kevin Wolf CC: Luiz Capitulino CC: Markus Armbruster Signed-off-by: Stefan Hajnoczi --- monitor.c | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/monitor.c b/monitor.c index 6cd747f

Re: [Qemu-devel] [PATCH v6 09/33] exec: allow file_ram_alloc to work on file

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:03PM +0800, Xiao Guangrong wrote: > Currently, file_ram_alloc() only works on directory - it creates a file > under @path and do mmap on it > > This patch tries to allow it to work on file directly, if @path is a > directory it works as before, otherwise it treats @pa

[Qemu-devel] [PATCH v4 0/9] block: Fixes for bdrv_drain

2015-11-09 Thread Fam Zheng
v4: Don't miss children's children. [Paolo] v3: Don't reuse coroutine in bdrv_aio_ioctl. [Stefan] Recursely call .bdrv_drain callback only. [Stefan, Paolo] Added Kevin's reviewed-by in other patches. v2: Add Kevin's reviewed-by in patches 1, 2, 5-7, 9. Address Kevin's reviewing commen

[Qemu-devel] [PATCH v4 1/9] block: Add more types for tracked request

2015-11-09 Thread Fam Zheng
We'll track more request types besides read and write, change the boolean field to an enum. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- block/io.c| 9 + include/block/block_int.h | 10 +- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/b

[Qemu-devel] [PATCH v4 6/9] block: Emulate bdrv_ioctl with bdrv_aio_ioctl and track both

2015-11-09 Thread Fam Zheng
Currently all drivers that support .bdrv_aio_ioctl also implement .bdrv_ioctl redundantly. To track ioctl requests in block layer it is easier if we unify the two paths, because we'll need to run it in a coroutine, as required by tracked_request_begin. While we're at it, use .bdrv_aio_ioctl plus a

[Qemu-devel] [PATCH v4 3/9] block: Track discard requests

2015-11-09 Thread Fam Zheng
Both bdrv_discard and bdrv_aio_discard will call into bdrv_co_discard, so add tracked_request_begin/end calls around the loop. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- block/io.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/block/io.c b/block/io

[Qemu-devel] [PATCH v4 2/9] block: Track flush requests

2015-11-09 Thread Fam Zheng
Both bdrv_flush and bdrv_aio_flush eventually call bdrv_co_flush, add tracked_request_begin and tracked_request_end pair in that function so that all flush requests are now tracked. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- block/io.c | 11 --- 1 file changed, 8 insertions(+)

Re: [Qemu-devel] [PATCH v6 11/33] hostmem-file: use whole file size if possible

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:05PM +0800, Xiao Guangrong wrote: > Use the whole file size if @size is not specified which is useful > if we want to directly pass a file to guest > > Signed-off-by: Xiao Guangrong Better split these simplifications off from the series. > --- > backends/hostmem-f

[Qemu-devel] [PATCH v4 9/9] qed: Implement .bdrv_drain

2015-11-09 Thread Fam Zheng
The "need_check_timer" is used to clear the "NEED_CHECK" flag in the image header after a grace period once metadata update has finished. In compliance to the bdrv_drain semantics we should make sure it remains deleted once .bdrv_drain is called. We cannot reuse qed_need_check_timer_cb because her

[Qemu-devel] [PATCH v4 7/9] block: Drop BlockDriver.bdrv_ioctl

2015-11-09 Thread Fam Zheng
Now the callback is not used any more, drop the field along with all implementations in block drivers, which are iscsi and raw. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- block/iscsi.c | 33 - block/raw-posix.c | 8 block/r

[Qemu-devel] [PATCH v4 8/9] block: Introduce BlockDriver.bdrv_drain callback

2015-11-09 Thread Fam Zheng
Drivers can have internal request sources that generate IO, like the need_check_timer in QED. Since we want quiesced periods that contain nested event loops in block layer, we need to have a way to disable such event sources. Block drivers must implement the "bdrv_drain" callback if it has any int

[Qemu-devel] [PATCH v4 4/9] iscsi: Emulate commands in iscsi_aio_ioctl as iscsi_ioctl

2015-11-09 Thread Fam Zheng
iscsi_ioctl emulates SG_GET_VERSION_NUM and SG_GET_SCSI_ID. Now that bdrv_ioctl() will be emulated with .bdrv_aio_ioctl, replicate the logic into iscsi_aio_ioctl to make them consistent. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- block/iscsi.c | 40

Re: [Qemu-devel] Qemu: Guest Linux hangs on Mac OS X 10.11

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 11:02, Peter Maydell wrote: > On 9 November 2015 at 09:10, Paolo Bonzini wrote: >> >> >> On 08/11/2015 23:55, Peter Maydell wrote: >>> So the good news is that on mainline this doesn't happen any more. >>> The bad news is that something weird is going on such that git >>> bisect do

[Qemu-devel] [PATCH v4 5/9] block: Add ioctl parameter fields to BlockRequest

2015-11-09 Thread Fam Zheng
The two fields that will be used by ioctl handling code later are added as union, because it's used exclusively by ioctl code which dosn't need the four fields in the other struct of the union. Signed-off-by: Fam Zheng Reviewed-by: Kevin Wolf --- include/block/block.h | 16 1 f

Re: [Qemu-devel] [PATCH] hw/arm/virt: error_report cleanups

2015-11-09 Thread Markus Armbruster
Peter Maydell writes: > On 9 November 2015 at 07:44, Markus Armbruster wrote: >> For consistency, error messages should be a phrase, not a full sentence, >> let alone a paraphraph. > > This is in direct conflict with wanting them to be actually useful > to users :-( I appreciate your drive for

Re: [Qemu-devel] [PATCH v4 8/9] block: Introduce BlockDriver.bdrv_drain callback

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 11:16, Fam Zheng wrote: > Drivers can have internal request sources that generate IO, like the > need_check_timer in QED. Since we want quiesced periods that contain > nested event loops in block layer, we need to have a way to disable such > event sources. > > Block drivers must i

Re: [Qemu-devel] [PATCH 02/16] exec.c: Allow target CPUs to define multiple AddressSpaces

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > Allow multiple calls to cpu_address_space_init(); each > call adds an entry to the cpu->ases array at the specified > index. It is up to the target-specific CPU code to actually use > these extra address spaces. > > Since this multiple AddressSpace sup

Re: [Qemu-devel] [PATCH 02/16] exec.c: Allow target CPUs to define multiple AddressSpaces

2015-11-09 Thread Paolo Bonzini
On 06/11/2015 14:34, Peter Maydell wrote: >> > IIUC, g_renew may move the entire cpu_ases area. The internals of >> > memory_listener_register (called below) seem to put away the pointers to >> > listeners >> > so a renew+move would leave invalid pointers to listeners in memory.c >> > wouldn't

Re: [Qemu-devel] [PATCH v6 07/33] util: introduce qemu_file_get_page_size()

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:01PM +0800, Xiao Guangrong wrote: > There are three places use the some logic to get the page size on > the file path or file fd > > This patch introduces qemu_file_get_page_size() to unify the code > > Signed-off-by: Xiao Guangrong > --- > include/qemu/osdep.h |

Re: [Qemu-devel] [PATCH v6 08/33] exec: allow memory to be allocated from any kind of path

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:02PM +0800, Xiao Guangrong wrote: > Currently file_ram_alloc() is designed for hugetlbfs, however, the memory > of nvdimm can come from either raw pmem device eg, /dev/pmem, or the file > locates at DAX enabled filesystem > > So this patch let it work on any kind of p

Re: [Qemu-devel] [PATCH v6 12/33] pc-dimm: remove DEFAULT_PC_DIMMSIZE

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:06PM +0800, Xiao Guangrong wrote: > It's not used any more > > Signed-off-by: Xiao Guangrong You should leave the renames and cleanups off for later. This patchset is large enough as it is. > --- > include/hw/mem/pc-dimm.h | 2 -- > 1 file changed, 2 deletions(-)

Re: [Qemu-devel] [PATCH 03/16] tlb_set_page_with_attrs: Take argument specifying AddressSpace to use

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > Add an argument to tlb_set_page_with_attrs which allows the target CPU code > to tell the core code which AddressSpace to use. > > The AddressSpace is specified by the index into the array of ASes which > were registered with cpu_address_space_init().

Re: [Qemu-devel] qemu : rbd block driver internal snapshot and vm_stop is hanging forever

2015-11-09 Thread Alexandre DERUMIER
adding to ceph.conf [client] rbd_non_blocking_aio = false fix the problem for me (with rbd_cache=false) (@cc jdur...@redhat.com) - Mail original - De: "Denis V. Lunev" À: "aderumier" , "ceph-devel" , "qemu-devel" Envoyé: Lundi 9 Novembre 2015 08:22:34 Objet: Re: [Qemu-dev

Re: [Qemu-devel] [PATCH 08/16] exec.c: Have one io_mem_watch per AddressSpace

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > The io_mem_watch MemoryRegion's read and write callbacks pass the > accesses through to an underlying address space. Now that that > might be something other than address_space_memory, we need to > pass the correct AddressSpace in via the opaque pointer

Re: [Qemu-devel] [PATCH 03/16] tlb_set_page_with_attrs: Take argument specifying AddressSpace to use

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 10:44, Paolo Bonzini wrote: > > > On 05/11/2015 19:15, Peter Maydell wrote: >> Add an argument to tlb_set_page_with_attrs which allows the target CPU code >> to tell the core code which AddressSpace to use. >> >> The AddressSpace is specified by the index into the array of AS

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > If we have a secure address space, use it in page table walks: > * when doing the physical accesses to read descriptors, >make them through the correct address space > * when the final result indicates a secure access, pass the >correct addres

Re: [Qemu-devel] [PATCH RFC 3/5] qapi: Use common name mangling for enumeration constants

2015-11-09 Thread Daniel P. Berrange
On Mon, Nov 09, 2015 at 10:34:41AM +0100, Markus Armbruster wrote: > "Daniel P. Berrange" writes: > > > On Thu, Nov 05, 2015 at 04:30:00PM +0100, Markus Armbruster wrote: > >> QAPI names needn't be valid C identifiers, so we mangle them with > >> c_name(). Except for enumeration constants, which

Re: [Qemu-devel] [PATCH 08/16] exec.c: Have one io_mem_watch per AddressSpace

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 10:49, Paolo Bonzini wrote: > > > On 05/11/2015 19:15, Peter Maydell wrote: >> @@ -2045,17 +2037,18 @@ static MemTxResult watch_mem_read(void *opaque, >> hwaddr addr, uint64_t *pdata, >> { >> MemTxResult res; >> uint64_t data; >> +AddressSpace *as = opaque; >>

Re: [Qemu-devel] [PATCH v6 09/33] exec: allow file_ram_alloc to work on file

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 06:13 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:03PM +0800, Xiao Guangrong wrote: Currently, file_ram_alloc() only works on directory - it creates a file under @path and do mmap on it This patch tries to allow it to work on file directly, if @path is a director

Re: [Qemu-devel] [PATCH v9 21/56] migration_is_setup_or_active

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Add 'migration_is_setup_or_active' utility function to check state. > (It gets postcopy added to it's list later on in the series) > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela

Re: [Qemu-devel] [PATCH 11/16] memory: Add address_space_init_shareable()

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > +AddressSpace *address_space_init_shareable(MemoryRegion *root, const char > *name) > +{ > +AddressSpace *as; > + > +QTAILQ_FOREACH(as, &address_spaces, address_spaces_link) { > +if (root == as->root) { > +as->ref_count++; >

Re: [Qemu-devel] [PATCH v6 11/33] hostmem-file: use whole file size if possible

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 06:17 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:05PM +0800, Xiao Guangrong wrote: Use the whole file size if @size is not specified which is useful if we want to directly pass a file to guest Signed-off-by: Xiao Guangrong Better split these simplifications o

Re: [Qemu-devel] [PATCH v9 20/56] Return path: Send responses from destination to source

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Add migrate_send_rp_message to send a message from destination to source > along the return path. > (It uses a mutex to let it be called from multiple threads) > Add migrate_send_rp_shut to send a 'shut' message to indi

Re: [Qemu-devel] [PATCH v9 30/56] migration_completion: Take current state

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Soon we'll be in either ACTIVE or POSTCOPY_ACTIVE when we > complete migration, and we need to know which we expect to be > in to change state safely. > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela

Re: [Qemu-devel] [PATCH 12/16] qom/cpu: Add MemoryRegion property

2015-11-09 Thread Paolo Bonzini
On 05/11/2015 19:15, Peter Maydell wrote: > + > +/* This is a softmmu CPU object, so create a property for it > + * so users can wire up its memory. (This can't go in qom/cpu.c > + * because that file is compiled only once for both user-mode > + * and system builds.) The default i

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 10:51, Paolo Bonzini wrote: > > > On 05/11/2015 19:15, Peter Maydell wrote: >> If we have a secure address space, use it in page table walks: >> * when doing the physical accesses to read descriptors, >>make them through the correct address space >> * when the final res

Re: [Qemu-devel] [PATCH 11/16] memory: Add address_space_init_shareable()

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 10:55, Paolo Bonzini wrote: > > > On 05/11/2015 19:15, Peter Maydell wrote: >> +AddressSpace *address_space_init_shareable(MemoryRegion *root, const char >> *name) >> +{ >> +AddressSpace *as; >> + >> +QTAILQ_FOREACH(as, &address_spaces, address_spaces_link) { >> +

Re: [Qemu-devel] [PATCH 08/16] exec.c: Have one io_mem_watch per AddressSpace

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 11:54, Peter Maydell wrote: > > current_cpu is available here, so it should be possible to have only one > > io_mem_watch per CPU address space index (i.e. two). > > So the opaque gives you the asidx and then you look at current_cpu's > cpu_ases[asidx]? Yeah, that works and is simp

Re: [Qemu-devel] [PATCH v6 07/33] util: introduce qemu_file_get_page_size()

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 06:33 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:01PM +0800, Xiao Guangrong wrote: There are three places use the some logic to get the page size on the file path or file fd This patch introduces qemu_file_get_page_size() to unify the code Signed-off-by: Xiao G

Re: [Qemu-devel] [PATCH v9 34/56] Postcopy: Maintain unsentmap

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Maintain an 'unsentmap' of pages that have yet to be sent. > This is used in the following patches to discard some set of > the pages already sent as we enter postcopy mode. > > Signed-off-by: Dr. David Alan Gilbert Revi

Re: [Qemu-devel] [PATCH 11/16] memory: Add address_space_init_shareable()

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 11:59, Peter Maydell wrote: >>> >> +as = g_malloc0(sizeof *as); >>> >> +address_space_init(as, root, name); >>> >> +as->malloced = true; >>> >> +return as; >>> >> } >> > >> > You shouldn't return a non-shareable address space here, I think, >> > because it might be

Re: [Qemu-devel] [PATCH v9 00/56] Postcopy implementation

2015-11-09 Thread Dr. David Alan Gilbert
* Bharata B Rao (bhar...@linux.vnet.ibm.com) wrote: > On Mon, Nov 09, 2015 at 09:08:33AM +, Dr. David Alan Gilbert wrote: > > * Bharata B Rao (bhar...@linux.vnet.ibm.com) wrote: > > > On Fri, Nov 06, 2015 at 03:48:11PM +, Dr. David Alan Gilbert wrote: > > > > * Bharata B Rao (bhar...@linux.

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 11:58, Peter Maydell wrote: > On 9 November 2015 at 10:51, Paolo Bonzini wrote: >> >> >> On 05/11/2015 19:15, Peter Maydell wrote: >>> If we have a secure address space, use it in page table walks: >>> * when doing the physical accesses to read descriptors, >>>make them throug

Re: [Qemu-devel] [PATCH v2] configure: disable FORTIFY_SOURCE under clang

2015-11-09 Thread Peter Maydell
On 3 November 2015 at 20:43, John Snow wrote: > Some versions of clang may have difficulty compiling glibc headers when > -D_FORTIFY_SOURCE is used. For example, Clang++ 3.5.0-9.fc22 cannot > compile glibc's stdio headers when -D_FORTIFY_SOURCE=2 is used. This > manifests currently as build failur

Re: [Qemu-devel] Qemu: Guest Linux hangs on Mac OS X 10.11

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 10:21, Paolo Bonzini wrote: > Hmm, so the list is pretty short: The good news is that my second bisect conclusively fingered the culprit for why the bug went away... > configure: disable FORTIFY_SOURCE under clang ...the bad news is it's because this patch inadverten

Re: [Qemu-devel] [PATCH v6 19/33] dimm: keep the state of the whole backend memory

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:13PM +0800, Xiao Guangrong wrote: > QEMU keeps the state of memory of dimm device during live migration, > however, it is not enough for nvdimm device as its memory does not > contain its label data, so that we should protect the whole backend > memory instead > > Sig

Re: [Qemu-devel] [PATCH v6 08/33] exec: allow memory to be allocated from any kind of path

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 06:39 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:02PM +0800, Xiao Guangrong wrote: Currently file_ram_alloc() is designed for hugetlbfs, however, the memory of nvdimm can come from either raw pmem device eg, /dev/pmem, or the file locates at DAX enabled filesyste

Re: [Qemu-devel] [PATCH v9 35/56] Postcopy: Calculate discard

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Where postcopy is preceeded by a period of precopy, the destination will > have received pages that may have been dirtied on the source after the > page was sent. The destination must throw these pages away before > start

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 11:03, Paolo Bonzini wrote: > > > On 09/11/2015 11:58, Peter Maydell wrote: >> You mean "what is the case where is_secure but cpu->num_ases == 1" ? >> That happens if you have a TrustZone CPU but the board has only >> connected up one address space, because there is no differ

Re: [Qemu-devel] [PATCH v6 12/33] pc-dimm: remove DEFAULT_PC_DIMMSIZE

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 06:40 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:06PM +0800, Xiao Guangrong wrote: It's not used any more Signed-off-by: Xiao Guangrong You should leave the renames and cleanups off for later. This patchset is large enough as it is. Okay.

Re: [Qemu-devel] [PATCH v9 36/56] postcopy: Incoming initialisation

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Signed-off-by: Dr. David Alan Gilbert > Reviewed-by: David Gibson > Reviewed-by: Amit Shah Reviewed-by: Juan Quintela

Re: [Qemu-devel] [PATCH v7 25/35] nvdimm acpi: init the resource used by NVDIMM ACPI

2015-11-09 Thread Igor Mammedov
On Fri, 6 Nov 2015 16:31:43 +0800 Xiao Guangrong wrote: > > > On 11/05/2015 10:49 PM, Igor Mammedov wrote: > > On Thu, 5 Nov 2015 21:33:39 +0800 > > Xiao Guangrong wrote: > > > >> > >> > >> On 11/05/2015 09:03 PM, Igor Mammedov wrote: > >>> On Thu, 5 Nov 2015 18:15:31 +0800 > >>> Xiao Guangron

Re: [Qemu-devel] [PATCH v6 06/33] acpi: add aml_method_serialized

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:56:00PM +0800, Xiao Guangrong wrote: > It avoid explicit Mutex and will be used by NVDIMM ACPI > > Signed-off-by: Xiao Guangrong I'd rather you squashed these utility patches in with where the code is used. This is just making it harder to review as I have to jump back

Re: [Qemu-devel] [PATCH v9 42/56] Page request: Consume pages off the post-copy queue

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > When transmitting RAM pages, consume pages that have been queued by > MIG_RPCOMM_REQPAGE commands and send them ahead of normal page scanning. > > Note: > a) After a queued page the linear walk carries on from after the

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Paolo Bonzini
On 09/11/2015 12:09, Peter Maydell wrote: >>> >> I could have handled that by making the CPU init code always >>> >> register two ASes (using the same one twice if the board code >>> >> only passes one or using system_address_space twice if the >>> >> board code doesn't pass one at all), but that

Re: [Qemu-devel] [PATCH v6 19/33] dimm: keep the state of the whole backend memory

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 07:04 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:13PM +0800, Xiao Guangrong wrote: QEMU keeps the state of memory of dimm device during live migration, however, it is not enough for nvdimm device as its memory does not contain its label data, so that we should pr

Re: [Qemu-devel] [PATCH v9 44/56] Postcopy: Use helpers to map pages during migration

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > In postcopy, the destination guest is running at the same time > as it's receiving pages; as we receive new pages we must put > them into the guests address space atomically to avoid a running > CPU accessing a partially w

Re: [Qemu-devel] [PULL 0/3] target-i386: tcg: Handle clflushopt/clwb/pcommit instructions

2015-11-09 Thread Peter Maydell
On 7 November 2015 at 14:54, Eduardo Habkost wrote: > The following changes since commit 4b59f39bc9a03afcc74b2fa28da7c3189fca507c: > > Merge remote-tracking branch > 'remotes/mjt/tags/pull-trivial-patches-2015-11-06' into staging (2015-11-06 > 12:50:24 +) > > are available in the git repos

Re: [Qemu-devel] [PATCH 09/16] target-arm: Support multiple address spaces in page table walks

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 11:19, Paolo Bonzini wrote: > > > On 09/11/2015 12:09, Peter Maydell wrote: >> I could have handled that by making the CPU init code always >> register two ASes (using the same one twice if the board code >> only passes one or using system_address_space twice i

Re: [Qemu-devel] [PATCH v9 48/56] Host page!=target page: Cleanup bitmaps

2015-11-09 Thread Juan Quintela
"Dr. David Alan Gilbert (git)" wrote: > From: "Dr. David Alan Gilbert" > > Prior to the start of postcopy, ensure that everything that will > be transferred later is a whole host-page in size. > > This is accomplished by discarding partially transferred host pages > and marking any that are parti

Re: [Qemu-devel] [PATCH v6 06/33] acpi: add aml_method_serialized

2015-11-09 Thread Xiao Guangrong
On 11/09/2015 07:14 PM, Michael S. Tsirkin wrote: On Fri, Oct 30, 2015 at 01:56:00PM +0800, Xiao Guangrong wrote: It avoid explicit Mutex and will be used by NVDIMM ACPI Signed-off-by: Xiao Guangrong I'd rather you squashed these utility patches in with where the code is used. This is just

Re: [Qemu-devel] [PATCH v6 05/33] acpi: add aml_object_type

2015-11-09 Thread Michael S. Tsirkin
On Fri, Oct 30, 2015 at 01:55:59PM +0800, Xiao Guangrong wrote: > Implement ObjectType which is used by NVDIMM _DSM method in > later patch > > Signed-off-by: Xiao Guangrong I had to go dig in the _DSM patch to see how it's used. And sure enough, callers have to know AML to make sense of it. So

Re: [Qemu-devel] [PATCH v3 0/9] block: Fixes for bdrv_drain

2015-11-09 Thread Stefan Hajnoczi
On Mon, Nov 09, 2015 at 10:56:39AM +0800, Fam Zheng wrote: > v3: Don't reuse coroutine in bdrv_aio_ioctl. [Stefan] > Recursely call .bdrv_drain callback only. [Stefan, Paolo] I don't understand this change. I thought you want .bdrv_drain() to be called on the whole tree, but the latest code s

Re: [Qemu-devel] Qemu: Guest Linux hangs on Mac OS X 10.11

2015-11-09 Thread Peter Maydell
On 9 November 2015 at 11:06, Peter Maydell wrote: > On 9 November 2015 at 10:21, Paolo Bonzini wrote: >> Hmm, so the list is pretty short: > > The good news is that my second bisect conclusively fingered > the culprit for why the bug went away... > >> configure: disable FORTIFY_SOURCE under

[Qemu-devel] [Minios-devel] [PATCH v4 0/] Begin to disentangle libxenctrl and provide some stable libraries

2015-11-09 Thread Ian Campbell
In <1431963008.4944.80.ca...@citrix.com> I proposed stabilising some parts of the libxenctrl API/ABI by disaggregating into separate libraries. This is v5 of that set of series against: xen qemu-xen qemu-xen-traditional mini-os NB: Samuel+minios-devel will only get the mini-os sid

  1   2   3   4   5   >