ceph: Add necessary clean up if invalid reply received in handle_reply()

Wake up possible waiters, invoke the call back if any, unregister the request

Signed-off-by: Li Wang <[email protected]>
Signed-off-by: Yunchuan Wen <[email protected]>
Signed-off-by: Sage Weil <[email protected]>
This commit is contained in:
Li Wang 2013-11-27 22:28:14 +08:00 • committed by Sage Weil
commit 37c89bde5d

View file

@ -1581,6 +1581,13 @@ done:
return;
bad_put:
req->r_result = -EIO;
__unregister_request(osdc, req);
if (req->r_callback)
req->r_callback(req, msg);
else
complete_all(&req->r_completion);
complete_request(req);
ceph_osdc_put_request(req);
bad_mutex:
mutex_unlock(&osdc->request_mutex);