Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b635fa21 authored by Roland Dreier's avatar Roland Dreier Committed by Linus Torvalds
Browse files

[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: default avatarRoland Dreier <roland@topspin.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 4ad81174
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -817,9 +817,11 @@ int mthca_init_cq(struct mthca_dev *dev, int nent,
err_out_mailbox:
	kfree(mailbox);

	if (dev->hca_type == ARBEL_NATIVE)
		mthca_free_db(dev, MTHCA_DB_TYPE_CQ_ARM, cq->arm_db_index);

err_out_ci:
	if (dev->hca_type == ARBEL_NATIVE)
		mthca_free_db(dev, MTHCA_DB_TYPE_CQ_SET_CI, cq->set_ci_db_index);

err_out_icm: