qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [Qemu-block] [PATCH 6/7] qcow2: aio support for compres


From: Alberto Garcia
Subject: Re: [Qemu-devel] [Qemu-block] [PATCH 6/7] qcow2: aio support for compressed cluster read
Date: Fri, 09 Nov 2018 14:51:42 +0100
User-agent: Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu)

On Tue 06 Nov 2018 05:24:36 PM CET, Vladimir Sementsov-Ogievskiy wrote:
>> Is there any reason why some parts of the QEMU code use qemu_blockalign
>> and others qemu_try_blockalign() ? From what I can see it seems to be up
>> to whoever wrote it...
>
> As I understand, the good reason to use _try_ versions, is when we are
> allocating some size, taken from user input, so it may be
> unpredictable large (hm, or just any really large allocation), so, I
> use try_malloc for compressed size, which may be very large in somehow
> corrupted image.

Ah right, the value of the compressed size field can be up to 8192
sectors, or 4MB.

I realized that you should add the coroutine_fn annotation to
qcow2_co_preadv_compressed(). Other than that the patch looks good so,
with that changed,

Reviewed-by: Alberto Garcia <address@hidden>

Berto



reply via email to

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