IB/ipath: Fix RC and UC error handling

When errors are detected in RC, the QP should transition to the
IB_QPS_ERR state, not the IB_QPS_SQE state. Also, when the error is on
the responder side, the receive work completion error was incorrect
(remote vs. local).

Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
这个提交包含在:
Ralph Campbell
2008-05-13 11:40:25 -07:00
提交者 Roland Dreier
父节点 dd37818dbd
当前提交 53dc1ca194
修改 5 个文件,包含 132 行新增224 行删除

查看文件

@@ -744,12 +744,10 @@ static void ipath_ib_timer(struct ipath_ibdev *dev)
/* XXX What if timer fires again while this is running? */
for (qp = resend; qp != NULL; qp = qp->timer_next) {
struct ib_wc wc;
spin_lock_irqsave(&qp->s_lock, flags);
if (qp->s_last != qp->s_tail && qp->state == IB_QPS_RTS) {
dev->n_timeouts++;
ipath_restart_rc(qp, qp->s_last_psn + 1, &wc);
ipath_restart_rc(qp, qp->s_last_psn + 1);
}
spin_unlock_irqrestore(&qp->s_lock, flags);