Re: [Qemu-block] [PATCH] block: Move away from anglo-centricity

2016-04-01 Thread John Snow
On 04/01/2016 10:50 AM, Max Reitz wrote: > In its organizational structure, the qemu project is rather > decentralized: Many different maintainers manage their own more or less > secluded subsystems. However, regarding languages, it is still rather > anglo-centric. > > This issue has been brough

Re: [Qemu-block] [Qemu-devel] [PATCH] block: Move away from anglo-centricity

2016-04-01 Thread Christian Borntraeger
On 04/01/2016 04:50 PM, Max Reitz wrote: > In its organizational structure, the qemu project is rather > decentralized: Many different maintainers manage their own more or less > secluded subsystems. However, regarding languages, it is still rather > anglo-centric. > > This issue has been brought

Re: [Qemu-block] [PATCH] block: split large discard requests from block frontend

2016-04-01 Thread Olaf Hering
On Fri, Apr 01, Max Reitz wrote: > In any case, do you have a test case where a guest was able to submit a > request that led to the overflow error you described in the commit message? mkfs -t ext4 /dev/sdb1 in a xen guest with qcow2 as backing device. When I added discard support to libxl I work

Re: [Qemu-block] [PATCH] block: split large discard requests from block frontend

2016-04-01 Thread Max Reitz
On 01.04.2016 14:22, Olaf Hering wrote: > Large discard requests lead to sign expansion errors in qemu. > Since there is no API to tell a guest about the limitations qmeu > has to split a large request itself. > > Signed-off-by: Olaf Hering > Cc: Stefan Hajnoczi > Cc: Kevin Wolf > --- > block/

Re: [Qemu-block] [PATCH for-2.6] crypto: Avoid memory leak on failure

2016-04-01 Thread Max Reitz
On 01.04.2016 17:57, Eric Blake wrote: > Commit 7836857 introduced a memory leak due to invalid use of > Error vs. visit_type_end(). If visiting the intermediate > members fails, we clear the error and unconditionally use > visit_end_struct() on the same error object; but if that > cleanup succeed

[Qemu-block] [PATCH for-2.6] nbd: don't request FUA on FLUSH

2016-04-01 Thread Eric Blake
The NBD protocol does not clearly document what will happen if a client sends NBD_CMD_FLAG_FUA on NBD_CMD_FLUSH. Historically, both the qemu and upstream NBD servers silently ignored that flag, but that feels a bit risky. Meanwhile, the qemu NBD client unconditionally sends the flag (without even

Re: [Qemu-block] [PATCH] block: Move away from anglo-centricity

2016-04-01 Thread Paolo Bonzini
On 01/04/2016 16:50, Max Reitz wrote: > Signed-off-by: Max Reitz Du hast zu viel freie Zeit. Paolo ps: given the latest news about AI, I hope Google Translate is not insulting any family member of yours, or worse. pps: the LibreOffice is looking for people translating comments from German to

[Qemu-block] [PATCH for-2.6] crypto: Avoid memory leak on failure

2016-04-01 Thread Eric Blake
Commit 7836857 introduced a memory leak due to invalid use of Error vs. visit_type_end(). If visiting the intermediate members fails, we clear the error and unconditionally use visit_end_struct() on the same error object; but if that cleanup succeeds, we then skip the qapi_free call. Until a late

Re: [Qemu-block] [PATCH] qemu-iotests: 149: Use "/usr/bin/env python"

2016-04-01 Thread Max Reitz
On 01.04.2016 11:56, Fam Zheng wrote: > Do the same as other scripts, to pick the correct interpreter between > python2 and python3 from the environment. > > Signed-off-by: Fam Zheng > --- > tests/qemu-iotests/149 | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Thanks, applied to my blo

Re: [Qemu-block] [RFC for-2.7 0/1] block/qapi: Add query-block-node-tree

2016-04-01 Thread Max Reitz
On 31.03.2016 11:49, Stefan Hajnoczi wrote: > On Thu, Mar 24, 2016 at 08:07:17PM +0100, Max Reitz wrote: >> As I responded to: >> - http://lists.nongnu.org/archive/html/qemu-devel/2016-03/msg04464.html >> - http://lists.nongnu.org/archive/html/qemu-devel/2016-03/msg05680.html >> >> I think a genera

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

2016-04-01 Thread Max Reitz
On 31.03.2016 13:42, Alberto Garcia wrote: > On Wed 30 Mar 2016 05:07:15 PM CEST, Max Reitz wrote: >>> I also have another (not directly related) question: why not simply >>> use the node name when removing children? I understood that the idea >>> was that it's possible to have the same node attach

Re: [Qemu-block] [PATCH v2] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Laurent Vivier
On 01/04/2016 15:57, Fam Zheng wrote: > Using the nested aio_poll() in coroutine is a bad idea. This patch > replaces the aio_poll loop in bdrv_drain with a BH, if called in > coroutine. > > For example, the bdrv_drain() in mirror.c can hang when a guest issued > request is pending on it in qemu

[Qemu-block] [PATCH v2] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Fam Zheng
Using the nested aio_poll() in coroutine is a bad idea. This patch replaces the aio_poll loop in bdrv_drain with a BH, if called in coroutine. For example, the bdrv_drain() in mirror.c can hang when a guest issued request is pending on it in qemu_co_mutex_lock(). Mirror coroutine in this case has

[Qemu-block] [PATCH] block: split large discard requests from block frontend

2016-04-01 Thread Olaf Hering
Large discard requests lead to sign expansion errors in qemu. Since there is no API to tell a guest about the limitations qmeu has to split a large request itself. Signed-off-by: Olaf Hering Cc: Stefan Hajnoczi Cc: Kevin Wolf --- block/io.c | 22 +- 1 file changed, 21 inser

Re: [Qemu-block] [PATCH] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Laurent Vivier
On 01/04/2016 11:46, Fam Zheng wrote: > Using the nested aio_poll() in coroutine is a bad idea. This patch > replaces the aio_poll loop in bdrv_drain with a BH, if called in > coroutine. > > For example, the bdrv_drain() in mirror.c can hang when a guest issued > request is pending on it in qemu

Re: [Qemu-block] [PATCH] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Fam Zheng
On Fri, 04/01 11:49, Paolo Bonzini wrote: > > > On 01/04/2016 11:46, Fam Zheng wrote: > > + > > +static void bdrv_co_drain_bh_cb(void *opaque) > > +{ > > +BdrvCoDrainData *data = opaque; > > +Coroutine *co = data->co; > > + > > +bdrv_drain(data->bs); > > +data->done = true; > > +

[Qemu-block] [PATCH] qemu-iotests: 149: Use "/usr/bin/env python"

2016-04-01 Thread Fam Zheng
Do the same as other scripts, to pick the correct interpreter between python2 and python3 from the environment. Signed-off-by: Fam Zheng --- tests/qemu-iotests/149 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/149 b/tests/qemu-iotests/149 index bb5811d..5

Re: [Qemu-block] [PATCH] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Paolo Bonzini
On 01/04/2016 11:46, Fam Zheng wrote: > + > +static void bdrv_co_drain_bh_cb(void *opaque) > +{ > +BdrvCoDrainData *data = opaque; > +Coroutine *co = data->co; > + > +bdrv_drain(data->bs); > +data->done = true; > +qemu_coroutine_enter(co, NULL); > +} > + > +static void corouti

[Qemu-block] [PATCH] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Fam Zheng
Using the nested aio_poll() in coroutine is a bad idea. This patch replaces the aio_poll loop in bdrv_drain with a BH, if called in coroutine. For example, the bdrv_drain() in mirror.c can hang when a guest issued request is pending on it in qemu_co_mutex_lock(). Mirror coroutine in this case has