]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
hammer: ObjectCacher: fix bh_read_finish offset logic 11618/head
authorGreg Farnum <gfarnum@redhat.com>
Mon, 23 May 2016 22:14:21 +0000 (15:14 -0700)
committerAlexey Sheplyakov <asheplyakov@mirantis.com>
Mon, 21 Nov 2016 15:37:26 +0000 (18:37 +0300)
commitece0ec60154d22bca7002cc308f3a0f4e36a053e
tree7e2ca63d690a8da994c901da27116faea0bed269
parent33f277e601199003fc226c84f67d1bbebb36ad2c
hammer: ObjectCacher: fix bh_read_finish offset logic

If we have an incoming read split across multiple BufferHeads, we want to
line up the BufferHead's bl with the incoming OSDOp's bl at the right offset. We
were erroneously using this nonsense calculation (always equal to zero!) when
a much simpler comparison of the BufferHead's logical object offset to the
incoming OSDOp's logical offset will do the trick nicely.

Fixes: http://tracker.ceph.com/issues/16002
Signed-off-by: Greg Farnum <gfarnum@redhat.com>
(cherry picked from commit 9ec6e7f608608088d51e449c9d375844631dcdde)
src/osdc/ObjectCacher.cc