diff options
author | Alex Elder <elder@inktank.com> | 2013-03-27 09:16:30 -0500 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-03-29 11:32:07 -0700 |
commit | 6e2a4505dba0cae8faa701426185dfb7b49f537c (patch) | |
tree | 7421cf34fea522ab761138d48be05aec06f4f635 /drivers/ata/pata_of_platform.c | |
parent | d6c0dd6b0c196979fa7b34c1d99432fcb1b7e1df (diff) | |
download | linux-6e2a4505dba0cae8faa701426185dfb7b49f537c.tar.gz linux-6e2a4505dba0cae8faa701426185dfb7b49f537c.tar.bz2 linux-6e2a4505dba0cae8faa701426185dfb7b49f537c.zip |
rbd: don't zero-fill non-image object requests
A result of ENOENT from a read request for an object that's part of
an rbd image indicates that there is a hole in that portion of the
image. Similarly, a short read for such an object indicates that
the remainder of the read should be interpreted a full read with
zeros filling out the end of the request.
This behavior is not correct for objects that are not backing rbd
image data. Currently rbd_img_obj_request_callback() assumes it
should be done for all objects.
Change rbd_img_obj_request_callback() so it only does this zeroing
for image objects. Encapsulate that special handling in its own
function. Add an assertion that the image object request is a bio
request, since we assume that (and we currently don't support any
other types).
This resolves a problem identified here:
http://tracker.ceph.com/issues/4559
The regression was introduced by bf0d5f503dc11d6314c0503591d258d60ee9c944.
Reported-by: Dan van der Ster <dan@vanderster.com>
Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-off-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'drivers/ata/pata_of_platform.c')
0 files changed, 0 insertions, 0 deletions