summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormajianpeng <majianpeng@gmail.com>2013-07-16 15:45:48 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-03-11 16:10:05 -0700
commitb3f19e7fb89f09ca56324a06b4ef7caf6745259b (patch)
treea9558a7968bc9432cd96ffe98a712b17a1ece57e
parentfe17c202b59ee36cff6ac87ca7ed31a9e9ea5f73 (diff)
libceph: unregister request in __map_request failed and nofail == false
commit 73d9f7eef3d98c3920e144797cc1894c6b005a1e upstream. For nofail == false request, if __map_request failed, the caller does cleanup work, like releasing the relative pages. It doesn't make any sense to retry this request. Signed-off-by: Jianpeng Ma <majianpeng@gmail.com> Reviewed-by: Sage Weil <sage@inktank.com> [bwh: Backported to 3.2: adjust indentation] Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Cc: Rui Xiang <rui.xiang@huawei.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--net/ceph/osd_client.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c
index 8e3aa4dc5bec..d8f031a762ae 100644
--- a/net/ceph/osd_client.c
+++ b/net/ceph/osd_client.c
@@ -1721,6 +1721,8 @@ int ceph_osdc_start_request(struct ceph_osd_client *osdc,
dout("osdc_start_request failed map, "
" will retry %lld\n", req->r_tid);
rc = 0;
+ } else {
+ __unregister_request(osdc, req);
}
goto out_unlock;
}