qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 08/23] block: Eliminate BlockDriverState member


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH 08/23] block: Eliminate BlockDriverState member device_name[]
Date: Wed, 10 Sep 2014 10:09:04 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.7.0

On 09/10/2014 02:13 AM, Markus Armbruster wrote:
> device_name[] is can become non-empty only in bdrv_new_named() and

s/is //

> bdrv_move_feature_fields().  The latter is used only to undo damage
> done by bdrv_swap().  The former is called only by blk_new_with_bs().
> Therefore, when a BlockDriverState's device_name[] is non-empty, then
> it's owned by a BlockBackend.
> 
> The converse is also true, because blk_attach_bs() is called only by
> blk_new_with_bs() so far.
> 
> Furthermore, blk_new_with_bs() keeps the two names equal.
> 
> Therefore, device_name[] is redundant.  Eliminate it.
> 
> Signed-off-by: Markus Armbruster <address@hidden>
> ---


-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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