diff options
author | Roland Dreier <roland@topspin.com> | 2005-04-16 22:26:21 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-16 22:26:21 (GMT) |
commit | b635fa215192a02e58e8e30d5d927435aa108192 (patch) | |
tree | 5f116d661f6dfa54f20c1d8ea1b9c88204d7bb2d /drivers/infiniband | |
parent | 4ad81174edfc22528b845a27620db7542c1ce9a6 (diff) | |
download | linux-fsl-qoriq-b635fa215192a02e58e8e30d5d927435aa108192.tar.xz |
[PATCH] IB/mthca: only free doorbell records in mem-free mode
On error path, only free doorbell records if we're in mem-free mode.
Signed-off-by: Roland Dreier <roland@topspin.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/mthca/mthca_cq.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_cq.c b/drivers/infiniband/hw/mthca/mthca_cq.c index 5dead2d..8b3ffd2 100644 --- a/drivers/infiniband/hw/mthca/mthca_cq.c +++ b/drivers/infiniband/hw/mthca/mthca_cq.c @@ -817,10 +817,12 @@ err_out_free_mr: err_out_mailbox: kfree(mailbox); - mthca_free_db(dev, MTHCA_DB_TYPE_CQ_ARM, cq->arm_db_index); + if (dev->hca_type == ARBEL_NATIVE) + mthca_free_db(dev, MTHCA_DB_TYPE_CQ_ARM, cq->arm_db_index); err_out_ci: - mthca_free_db(dev, MTHCA_DB_TYPE_CQ_SET_CI, cq->set_ci_db_index); + if (dev->hca_type == ARBEL_NATIVE) + mthca_free_db(dev, MTHCA_DB_TYPE_CQ_SET_CI, cq->set_ci_db_index); err_out_icm: mthca_table_put(dev, dev->cq_table.table, cq->cqn); |