qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH] qcow2: always initialize specific image info


From: Denis V. Lunev
Subject: Re: [Qemu-block] [PATCH] qcow2: always initialize specific image info
Date: Wed, 23 Dec 2015 01:05:35 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0

On 12/22/2015 11:28 PM, Eric Blake wrote:
On 12/21/2015 04:05 PM, Max Reitz wrote:

The situation is even worse than I have feared.

Thanks for finding this!

Well, if qcow2_get_specific_info() is the only place that can actually
cause issues in that case (i.e. calling some QMP function which uses the
qcow2 image while the incoming_migration coroutine yields before the
image has been fully reopened), I think the simplest way to fix this
would be to just return NULL from qcow2_get_specific_info() in the else
branch (which currently aborts), adding a comment how we can end up there.

However, it seems hard to believe this is the only problematic path...
If the coroutine can yield between the BDRVQcow2State getting memset()
to 0 and qcow2_open() having initialized it again, then any QMP command
which makes use of the qcow2 image should fail (not necessarily
gracefully) at that point.
I wonder if Kevin's patch will help us pinpoint culprits:

https://lists.gnu.org/archive/html/qemu-devel/2015-12/msg04096.html

not all places. There is one more instance of qcow2_invalidate_cache()
in NBD code.

Den



reply via email to

[Prev in Thread] Current Thread [Next in Thread]