Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 373369
b: refs/heads/master
c: dc4b870
h: refs/heads/master
i:
  373367: 3d7774b
v: v3
  • Loading branch information
Alex Elder authored and Sage Weil committed May 2, 2013
1 parent d962318 commit cf78e56
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e9966076cdd952e19f2dd4854cd719be0d7cbebc
refs/heads/master: dc4b870c97a5006871c259f7e61ea6c79038f731
11 changes: 1 addition & 10 deletions trunk/net/ceph/osd_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -831,14 +831,6 @@ static void __register_request(struct ceph_osd_client *osdc,
}
}

static void register_request(struct ceph_osd_client *osdc,
struct ceph_osd_request *req)
{
mutex_lock(&osdc->request_mutex);
__register_request(osdc, req);
mutex_unlock(&osdc->request_mutex);
}

/*
* called under osdc->request_mutex
*/
Expand Down Expand Up @@ -1785,15 +1777,14 @@ int ceph_osdc_start_request(struct ceph_osd_client *osdc,
ceph_osdc_msg_data_set(req->r_reply, &req->r_data_in);
ceph_osdc_msg_data_set(req->r_request, &req->r_data_out);

register_request(osdc, req);

down_read(&osdc->map_sem);
mutex_lock(&osdc->request_mutex);
/*
* a racing kick_requests() may have sent the message for us
* while we dropped request_mutex above, so only send now if
* the request still han't been touched yet.
*/
__register_request(osdc, req);
if (req->r_sent == 0) {
rc = __map_request(osdc, req, 0);
if (rc < 0) {
Expand Down

0 comments on commit cf78e56

Please sign in to comment.