From: Alex Elder Date: Thu, 6 Dec 2012 13:22:04 +0000 (-0600) Subject: libceph: register request before unregister linger X-Git-Tag: v3.8-rc2~7^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c89ce05e0c5a01a256100ac6a6019f276bdd1ca6;p=profile%2Fcommon%2Fkernel-common.git libceph: register request before unregister linger In kick_requests(), we need to register the request before we unregister the linger request. Otherwise the unregister will reset the request's osd pointer to NULL. Signed-off-by: Alex Elder Reviewed-by: Sage Weil --- diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index 7cd0a7f..780caf6 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c @@ -1328,8 +1328,8 @@ static void kick_requests(struct ceph_osd_client *osdc, int force_resend) dout("kicking lingering %p tid %llu osd%d\n", req, req->r_tid, req->r_osd ? req->r_osd->o_osd : -1); - __unregister_linger_request(osdc, req); __register_request(osdc, req); + __unregister_linger_request(osdc, req); } mutex_unlock(&osdc->request_mutex);