Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 73809
b: refs/heads/master
c: a6e7550
h: refs/heads/master
i:
  73807: 5775044
v: v3
  • Loading branch information
Ralph Campbell authored and Roland Dreier committed Nov 13, 2007
1 parent 4c7a31c commit 6c873a0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 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: 3bba11e5c47dfc1d381a1ece26464fb7eea2d79c
refs/heads/master: a6e7550d8f73d6b75c20afff321f0f06fe144775
11 changes: 7 additions & 4 deletions trunk/drivers/infiniband/hw/ipath/ipath_cq.c
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ int ipath_resize_cq(struct ib_cq *ibcq, int cqe, struct ib_udata *udata)

ret = ib_copy_to_udata(udata, &offset, sizeof(offset));
if (ret)
goto bail;
goto bail_free;
}

spin_lock_irq(&cq->lock);
Expand All @@ -424,10 +424,8 @@ int ipath_resize_cq(struct ib_cq *ibcq, int cqe, struct ib_udata *udata)
else
n = head - tail;
if (unlikely((u32)cqe < n)) {
spin_unlock_irq(&cq->lock);
vfree(wc);
ret = -EOVERFLOW;
goto bail;
goto bail_unlock;
}
for (n = 0; tail != head; n++) {
if (cq->ip)
Expand Down Expand Up @@ -459,7 +457,12 @@ int ipath_resize_cq(struct ib_cq *ibcq, int cqe, struct ib_udata *udata)
}

ret = 0;
goto bail;

bail_unlock:
spin_unlock_irq(&cq->lock);
bail_free:
vfree(wc);
bail:
return ret;
}

0 comments on commit 6c873a0

Please sign in to comment.