From: Mike Marciniszyn Date: Tue, 11 Jan 2011 01:42:19 +0000 (-0800) Subject: IB/qib: Generate completion callback on errors X-Git-Tag: upstream/snapshot3+hdmi~12071^2^7~19 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a377acd15188cf11e47a67af5feea098cd8b25d2;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git IB/qib: Generate completion callback on errors According to IBTA vol. 1, C11-30.1.1, a notification callback is invoked if the CQ is armed for the next solicited completion event or an error completion. The error case wasn't being generated correctly. Signed-off-by: Mike Marciniszyn Signed-off-by: Roland Dreier --- diff --git a/drivers/infiniband/hw/qib/qib_cq.c b/drivers/infiniband/hw/qib/qib_cq.c index a86cbf8..5246aa4 100644 --- a/drivers/infiniband/hw/qib/qib_cq.c +++ b/drivers/infiniband/hw/qib/qib_cq.c @@ -100,7 +100,8 @@ void qib_cq_enter(struct qib_cq *cq, struct ib_wc *entry, int solicited) wc->head = next; if (cq->notify == IB_CQ_NEXT_COMP || - (cq->notify == IB_CQ_SOLICITED && solicited)) { + (cq->notify == IB_CQ_SOLICITED && + (solicited || entry->status != IB_WC_SUCCESS))) { cq->notify = IB_CQ_NONE; cq->triggered++; /*