]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
os/bluestore: fix dirty_range on _do_clone_range 16738/head
authorSage Weil <sage@redhat.com>
Tue, 1 Aug 2017 19:47:28 +0000 (15:47 -0400)
committerSage Weil <sage@redhat.com>
Tue, 1 Aug 2017 19:47:37 +0000 (15:47 -0400)
commit41cff36e66871522aac91f2d987cef244077047a
treedcee83000b13eb53e4bfe8ea4244462eba96c2e6
parent69c6402bbdd46a8159a906aea25b5bfc4c2c43ec
os/bluestore: fix dirty_range on _do_clone_range

If we are cloning several extents that start from logical offset 0, we may
need to dirty those extents on the source object if they are being made
shared.  However, if there are two or more such extents, and the first
starts at 0, the current code will adjust dirty_range_start to the
second extent because the second time around the loop dirty_range_begin
is still 0.

Fix by adjusting the condition to be dirty_range_begin and dirty_range_end
== 0 so that it only triggers on the first pass.

Fixes: http://tracker.ceph.com/issues/20810
Signed-off-by: Sage Weil <sage@redhat.com>
src/os/bluestore/BlueStore.cc