Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Stefan Hajnoczi
On Mon, Feb 20, 2012 at 12:50:30PM +0800, zwu.ker...@gmail.com wrote: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining activities are done, some requests maybe are in the throttled queue; So we need

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Zhi Yong Wu
On Fri, Feb 24, 2012 at 4:49 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Feb 20, 2012 at 12:50:30PM +0800, zwu.ker...@gmail.com wrote: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Zhi Yong Wu
On Fri, Feb 24, 2012 at 4:49 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Feb 20, 2012 at 12:50:30PM +0800, zwu.ker...@gmail.com wrote: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Stefan Hajnoczi
On Fri, Feb 24, 2012 at 05:25:08PM +0800, Zhi Yong Wu wrote: On Fri, Feb 24, 2012 at 4:49 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Feb 20, 2012 at 12:50:30PM +0800, zwu.ker...@gmail.com wrote: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Paolo Bonzini
On 02/24/2012 09:49 AM, Stefan Hajnoczi wrote: +void bdrv_drain_request(BlockDriverState *throttled_bs) { BlockDriverState *bs; +QTAILQ_FOREACH(bs, bdrv_states, list) { +if (throttled_bs throttled_bs != bs) { +continue; +} +

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-24 Thread Zhi Yong Wu
On Fri, Feb 24, 2012 at 7:18 PM, Stefan Hajnoczi stefa...@linux.vnet.ibm.com wrote: On Fri, Feb 24, 2012 at 05:25:08PM +0800, Zhi Yong Wu wrote: On Fri, Feb 24, 2012 at 4:49 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Feb 20, 2012 at 12:50:30PM +0800, zwu.ker...@gmail.com wrote:

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-20 Thread Kevin Wolf
Am 20.02.2012 05:50, schrieb zwu.ker...@gmail.com: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining activities are done, some requests maybe are in the throttled queue; So we need to restart them at

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-20 Thread Zhi Yong Wu
On Mon, Feb 20, 2012 at 5:26 PM, Kevin Wolf kw...@redhat.com wrote: Am 20.02.2012 05:50, schrieb zwu.ker...@gmail.com: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining activities are done, some requests

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-20 Thread Zhi Yong Wu
For example, one disk of one guest is hot plugout, its other disks should not be affected if those disks also enable I/O throttling. But if one whole VM need to be stored, all throttled requests for all disks need to be drained. On Mon, Feb 20, 2012 at 5:26 PM, Kevin Wolf kw...@redhat.com wrote:

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-20 Thread Kevin Wolf
Am 20.02.2012 10:29, schrieb Zhi Yong Wu: On Mon, Feb 20, 2012 at 5:26 PM, Kevin Wolf kw...@redhat.com wrote: Am 20.02.2012 05:50, schrieb zwu.ker...@gmail.com: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when

Re: [Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-20 Thread Zhi Yong Wu
On Mon, Feb 20, 2012 at 5:39 PM, Kevin Wolf kw...@redhat.com wrote: Am 20.02.2012 10:29, schrieb Zhi Yong Wu: On Mon, Feb 20, 2012 at 5:26 PM, Kevin Wolf kw...@redhat.com wrote: Am 20.02.2012 05:50, schrieb zwu.ker...@gmail.com: From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has

[Qemu-devel] [PATCH 1/2] block: add the support for draining the throttled request queue

2012-02-19 Thread zwu . kernel
From: Zhi Yong Wu wu...@linux.vnet.ibm.com If one guest has multiple disks with enabling I/O throttling function separately, when draining activities are done, some requests maybe are in the throttled queue; So we need to restart them at first. Moreover, when only one disk need to be drained