Skip to content
  • Hanna Reitz's avatar
    9c83625b
    block/mirror: Revive dead yielding code · 9c83625b
    Hanna Reitz authored
    
    
    mirror_iteration() is supposed to wait if the current chunk is subject
    to a still in-flight mirroring operation. However, it mixed checking
    this conflict situation with checking the dirty status of a chunk. A
    simplification for the latter condition (the first chunk encountered is
    always dirty) led to neglecting the former: We just skip the first chunk
    and thus never test whether it conflicts with an in-flight operation.
    
    To fix this, pull out the code which waits for in-flight operations on
    the first chunk of the range to be mirrored to settle.
    
    Signed-off-by: default avatarMax Reitz <mreitz@redhat.com>
    Reviewed-by: default avatarFam Zheng <famz@redhat.com>
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    9c83625b
    block/mirror: Revive dead yielding code
    Hanna Reitz authored
    
    
    mirror_iteration() is supposed to wait if the current chunk is subject
    to a still in-flight mirroring operation. However, it mixed checking
    this conflict situation with checking the dirty status of a chunk. A
    simplification for the latter condition (the first chunk encountered is
    always dirty) led to neglecting the former: We just skip the first chunk
    and thus never test whether it conflicts with an in-flight operation.
    
    To fix this, pull out the code which waits for in-flight operations on
    the first chunk of the range to be mirrored to settle.
    
    Signed-off-by: default avatarMax Reitz <mreitz@redhat.com>
    Reviewed-by: default avatarFam Zheng <famz@redhat.com>
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
Loading