Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 41342
b: refs/heads/master
c: a1a733f
h: refs/heads/master
v: v3
  • Loading branch information
Krishna Kumar authored and Roland Dreier committed Nov 29, 2006
1 parent 94c194b commit 6528100
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 15 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: f115db4803effd8207c3169590fb3f13336a4093
refs/heads/master: a1a733f65b091fdad3d0783e648c92b491933ab6
27 changes: 13 additions & 14 deletions trunk/drivers/infiniband/core/cma.c
Original file line number Diff line number Diff line change
Expand Up @@ -935,13 +935,8 @@ static int cma_req_handler(struct ib_cm_id *cm_id, struct ib_cm_event *ib_event)
mutex_lock(&lock);
ret = cma_acquire_dev(conn_id);
mutex_unlock(&lock);
if (ret) {
ret = -ENODEV;
cma_exch(conn_id, CMA_DESTROYING);
cma_release_remove(conn_id);
rdma_destroy_id(&conn_id->id);
goto out;
}
if (ret)
goto release_conn_id;

conn_id->cm_id.ib = cm_id;
cm_id->context = conn_id;
Expand All @@ -951,13 +946,17 @@ static int cma_req_handler(struct ib_cm_id *cm_id, struct ib_cm_event *ib_event)
ret = cma_notify_user(conn_id, RDMA_CM_EVENT_CONNECT_REQUEST, 0,
ib_event->private_data + offset,
IB_CM_REQ_PRIVATE_DATA_SIZE - offset);
if (ret) {
/* Destroy the CM ID by returning a non-zero value. */
conn_id->cm_id.ib = NULL;
cma_exch(conn_id, CMA_DESTROYING);
cma_release_remove(conn_id);
rdma_destroy_id(&conn_id->id);
}
if (!ret)
goto out;

/* Destroy the CM ID by returning a non-zero value. */
conn_id->cm_id.ib = NULL;

release_conn_id:
cma_exch(conn_id, CMA_DESTROYING);
cma_release_remove(conn_id);
rdma_destroy_id(&conn_id->id);

out:
cma_release_remove(listen_id);
return ret;
Expand Down

0 comments on commit 6528100

Please sign in to comment.