diff options
| -rw-r--r-- | drivers/infiniband/hw/mlx4/cq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/mlx4/cq.c b/drivers/infiniband/hw/mlx4/cq.c index 2f199c5c4a72..4521319b1406 100644 --- a/drivers/infiniband/hw/mlx4/cq.c +++ b/drivers/infiniband/hw/mlx4/cq.c | |||
| @@ -246,7 +246,7 @@ err_mtt: | |||
| 246 | if (context) | 246 | if (context) |
| 247 | ib_umem_release(cq->umem); | 247 | ib_umem_release(cq->umem); |
| 248 | else | 248 | else |
| 249 | mlx4_ib_free_cq_buf(dev, &cq->buf, entries); | 249 | mlx4_ib_free_cq_buf(dev, &cq->buf, cq->ibcq.cqe); |
| 250 | 250 | ||
| 251 | err_db: | 251 | err_db: |
| 252 | if (!context) | 252 | if (!context) |
| @@ -434,7 +434,7 @@ int mlx4_ib_destroy_cq(struct ib_cq *cq) | |||
| 434 | mlx4_ib_db_unmap_user(to_mucontext(cq->uobject->context), &mcq->db); | 434 | mlx4_ib_db_unmap_user(to_mucontext(cq->uobject->context), &mcq->db); |
| 435 | ib_umem_release(mcq->umem); | 435 | ib_umem_release(mcq->umem); |
| 436 | } else { | 436 | } else { |
| 437 | mlx4_ib_free_cq_buf(dev, &mcq->buf, cq->cqe + 1); | 437 | mlx4_ib_free_cq_buf(dev, &mcq->buf, cq->cqe); |
| 438 | mlx4_db_free(dev->dev, &mcq->db); | 438 | mlx4_db_free(dev->dev, &mcq->db); |
| 439 | } | 439 | } |
| 440 | 440 | ||
