Skip to content
  • Kevin Wolf's avatar
    73ac451f
    block: Reject writethrough mode except at the root · 73ac451f
    Kevin Wolf authored
    
    
    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: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    73ac451f
    block: Reject writethrough mode except at the root
    Kevin Wolf authored
    
    
    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: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
Loading