qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 1/6] block: Support byte-based aio callbacks


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH 1/6] block: Support byte-based aio callbacks
Date: Tue, 24 Apr 2018 14:16:05 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0

On 04/24/2018 12:15 PM, Kevin Wolf wrote:

>>> Hm, this is kind of ugly. Previously, we handled everything byte-aligned
>>> in the first section, now we mix both in the second section.
>>>
>>> I can see that you do this so you don't have to duplicate the acb and
>>> coroutine yielding code below, but can we move things into the right
>>> place in the final patch at least? That is, calculate sector_num and
>>> nb_sectors only if all the byte-based interfaces weren't available.
>>
>> Yeah, that's easy enough to squash into patch 6:
>>

> 
> Ah, yes. I thought of moving the code in the else block, but this works,
> too. Maybe it's even a bit nicer.

Moving the code into the 'if' works for bdrv_co_readv, but not so nicely
for the bdrv_co_writev vs. bdrv_co_writev_flags.  So for v2, I'll just
hoist the aio code first; and I guess I smell another round of cleanups
coming...

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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