If a FINI operation fails, then we need to ABORT instead
of CLOSE.  Also, if we ABORT due to unexpected STREAMING
data, then wake up anybody blocked in FINI...

Signed-off-by: Vipul Pandya <[email protected]>
---
 drivers/infiniband/hw/cxgb4/cm.c |    1 +
 drivers/infiniband/hw/cxgb4/qp.c |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/infiniband/hw/cxgb4/cm.c b/drivers/infiniband/hw/cxgb4/cm.c
index 9cab6a6..3dce47a 100644
--- a/drivers/infiniband/hw/cxgb4/cm.c
+++ b/drivers/infiniband/hw/cxgb4/cm.c
@@ -1438,6 +1438,7 @@ static int abort_rpl(struct c4iw_dev *dev, struct sk_buff 
*skb)
        mutex_lock(&ep->com.mutex);
        switch (ep->com.state) {
        case ABORTING:
+               c4iw_wake_up(&ep->com.wr_wait, -ECONNRESET);
                __state_set(&ep->com, DEAD);
                release = 1;
                break;
diff --git a/drivers/infiniband/hw/cxgb4/qp.c b/drivers/infiniband/hw/cxgb4/qp.c
index 05bfe53..17ba4f8 100644
--- a/drivers/infiniband/hw/cxgb4/qp.c
+++ b/drivers/infiniband/hw/cxgb4/qp.c
@@ -1383,6 +1383,7 @@ err:
        qhp->ep = NULL;
        set_state(qhp, C4IW_QP_STATE_ERROR);
        free = 1;
+       abort = 1;
        wake_up(&qhp->wait);
        BUG_ON(!ep);
        flush_qp(qhp);
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to