qemu-block
[Top][All Lists]
Advanced

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

Re: [Qemu-block] [PATCH 5/5] block: Reject writethrough mode except at t


From: Eric Blake
Subject: Re: [Qemu-block] [PATCH 5/5] block: Reject writethrough mode except at the root
Date: Mon, 14 Mar 2016 10:50:56 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0

On 03/14/2016 09:44 AM, Kevin Wolf wrote:
> Writethrough mode is going to become a BlockBackend feature rather than
> a BDS one, so forbid it in places where we won't be able to support it
> when the code finally matches the envisioned design.
> 
> We only allowed setting the cache mode of non-root nodes after the 2.5
> release, so we're still free to make this change.
> 
> The target of block jobs is now always opened in a writeback mode
> because it doesn't have a BlockBackend attached. This makes more sense
> anyway because block jobs know when to flush. If the graph is modified
> on job completion, the original cache mode moves to the new root, so
> for the guest device writethough always stays enabled if it was
> configured this way.
> 
> Signed-off-by: Kevin Wolf <address@hidden>
> ---
>  block.c                    |  7 ++++
>  blockdev.c                 | 19 ++++++++-
>  tests/qemu-iotests/142     | 50 +++++++++++------------
>  tests/qemu-iotests/142.out | 98 
> +++++++++-------------------------------------
>  4 files changed, 68 insertions(+), 106 deletions(-)
> 

Reviewed-by: Eric Blake <address@hidden>

> +++ b/tests/qemu-iotests/142
> @@ -96,36 +96,36 @@ function check_cache_all()
>      # bs->backing
>  
>      echo -e "cache.direct=on on none0"

Pre-existing, but 'echo -e' is non-portable (even in bash, you can set
options such that it changes behavior).  printf is better, if we're
worried about it.

-- 
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]