Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-09 Thread 858585 jemmy
On Fri, Apr 7, 2017 at 7:33 PM, Stefan Hajnoczi wrote: > On Fri, Apr 07, 2017 at 09:30:33AM +0800, 858585 jemmy wrote: >> On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: >> > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >> >> From: Lidong Chen >> >> >> >> when m

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-08 Thread 858585 jemmy
On Fri, Apr 7, 2017 at 7:34 PM, Stefan Hajnoczi wrote: > On Fri, Apr 07, 2017 at 09:30:33AM +0800, 858585 jemmy wrote: >> On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: >> > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >> > >> > A proper solution is to refactor

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-08 Thread Paolo Bonzini
On 07/04/2017 19:33, Stefan Hajnoczi wrote: > The migration thread is holding the QEMU global mutex, the AioContext, > and the qcow2 s->lock while the L2 table is read from disk. > > The QEMU global mutex is needed for block layer operations that touch > the global drives list. bdrv_is_allocate

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-07 Thread Stefan Hajnoczi
On Fri, Apr 07, 2017 at 09:30:33AM +0800, 858585 jemmy wrote: > On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: > > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: > > > > A proper solution is to refactor the synchronous code to make it > > asynchronous. This might

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-07 Thread Stefan Hajnoczi
On Fri, Apr 07, 2017 at 09:30:33AM +0800, 858585 jemmy wrote: > On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: > > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: > >> From: Lidong Chen > >> > >> when migration with high speed, mig_save_device_bulk invoke > >> bdrv

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-07 Thread 858585 jemmy
On Fri, Apr 7, 2017 at 9:30 AM, 858585 jemmy wrote: > On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: >> On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >>> From: Lidong Chen >>> >>> when migration with high speed, mig_save_device_bulk invoke >>> bdrv_is_allocated

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-06 Thread 858585 jemmy
On Thu, Apr 6, 2017 at 10:02 PM, Stefan Hajnoczi wrote: > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >> From: Lidong Chen >> >> when migration with high speed, mig_save_device_bulk invoke >> bdrv_is_allocated too frequently, and cause vnc reponse slowly. >> this patch

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-06 Thread Stefan Hajnoczi
On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: > From: Lidong Chen > > when migration with high speed, mig_save_device_bulk invoke > bdrv_is_allocated too frequently, and cause vnc reponse slowly. > this patch limit the time used for bdrv_is_allocated. bdrv_is_allocated()

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-05 Thread 858585 jemmy
On Wed, Apr 5, 2017 at 6:44 PM, 858585 jemmy wrote: > On Wed, Apr 5, 2017 at 5:34 PM, Daniel P. Berrange > wrote: >> On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >>> From: Lidong Chen >>> >>> when migration with high speed, mig_save_device_bulk invoke >>> bdrv_is_alloc

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-05 Thread 858585 jemmy
On Wed, Apr 5, 2017 at 5:34 PM, Daniel P. Berrange wrote: > On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: >> From: Lidong Chen >> >> when migration with high speed, mig_save_device_bulk invoke >> bdrv_is_allocated too frequently, and cause vnc reponse slowly. >> this patc

Re: [Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-05 Thread Daniel P. Berrange
On Wed, Apr 05, 2017 at 05:27:58PM +0800, jemmy858...@gmail.com wrote: > From: Lidong Chen > > when migration with high speed, mig_save_device_bulk invoke > bdrv_is_allocated too frequently, and cause vnc reponse slowly. > this patch limit the time used for bdrv_is_allocated. Can you explain why

[Qemu-devel] [PATCH v3] migration/block:limit the time used for block migration

2017-04-05 Thread jemmy858585
From: Lidong Chen when migration with high speed, mig_save_device_bulk invoke bdrv_is_allocated too frequently, and cause vnc reponse slowly. this patch limit the time used for bdrv_is_allocated. Signed-off-by: Lidong Chen --- migration/block.c | 35 ++- 1 file