]> git.openfabrics.org - ~shefty/rdma-win.git/commitdiff
[MTHCA] (continues patch 251) remaps RDD/EEC WC status values to IB_WCS_GENERIC_ERR...
authortzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 26 Mar 2006 13:13:48 +0000 (13:13 +0000)
committertzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 26 Mar 2006 13:13:48 +0000 (13:13 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1@253 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

trunk/hw/mthca/kernel/mthca_cmd.c
trunk/hw/mthca/kernel/mthca_cq.c
trunk/hw/mthca/user/mlnx_uvp_cq.c

index 0820e9770fdfbed505e1b45dffd8af30bac4fdf7..3913691ec81e9fdf8ae8291f728d858229127f75 100644 (file)
@@ -1707,6 +1707,9 @@ int mthca_MAD_IFC(struct mthca_dev *dev, int ignore_mkey, int ignore_bkey,
        u32 in_modifier = port;
        u8 op_modifier = 0;
 
+       ASSERT( !in_wc );
+       UNREFERENCED_PARAMETER( in_grh );
+
 #define MAD_IFC_BOX_SIZE      0x400
 #define MAD_IFC_MY_QPN_OFFSET 0x100
 #define MAD_IFC_RQPN_OFFSET   0x104
@@ -1738,32 +1741,6 @@ int mthca_MAD_IFC(struct mthca_dev *dev, int ignore_mkey, int ignore_bkey,
        if (ignore_bkey || !in_wc)
                op_modifier |= 0x2;
 
-       if (in_wc) {
-               u8 val;
-
-               RtlZeroMemory(inbox + 256, 256);
-
-               MTHCA_PUT(inbox, in_wc->qp_num,     MAD_IFC_MY_QPN_OFFSET);
-               MTHCA_PUT(inbox, in_wc->recv.ud.remote_qp,     MAD_IFC_RQPN_OFFSET);
-
-               val = in_wc->recv.ud.remote_sl << 4;
-               MTHCA_PUT(inbox, val,               MAD_IFC_SL_OFFSET);
-
-               val = in_wc->recv.ud.path_bits |
-                       (in_wc->recv.ud.recv_opt & IB_RECV_OPT_GRH_VALID ? 0x80 : 0);
-               MTHCA_PUT(inbox, val,               MAD_IFC_GRH_OFFSET);
-
-               MTHCA_PUT(inbox, in_wc->recv.ud.remote_lid,       MAD_IFC_RLID_OFFSET);
-               MTHCA_PUT(inbox, in_wc->recv.ud.pkey_index, MAD_IFC_PKEY_OFFSET);
-
-               if (in_grh)
-                       memcpy(inbox + MAD_IFC_GRH_OFFSET, in_grh, 40);
-
-               op_modifier |= 0x10;
-
-               in_modifier |= in_wc->recv.ud.remote_lid << 16;
-       }
-
        err = mthca_cmd_box(dev, inmailbox->dma, outmailbox->dma,
                            in_modifier, op_modifier,
                            CMD_MAD_IFC, CMD_TIME_CLASS_C, status);
index 6f01ac1a2ad899f960795a88b1cf3dffef6c27d4..e9b210ca5de19dd8366212fa7ece248135309eed 100644 (file)
@@ -362,9 +362,6 @@ static int handle_error_cqe(struct mthca_dev *dev, struct mthca_cq *cq,
        case SYNDROME_LOCAL_QP_OP_ERR:
                entry->status = IB_WCS_LOCAL_OP_ERR;
                break;
-       case SYNDROME_LOCAL_EEC_OP_ERR:
-               entry->status = IB_WCS_LOCAL_EEC_OP_ERR;
-               break;
        case SYNDROME_LOCAL_PROT_ERR:
                entry->status = IB_WCS_LOCAL_PROTECTION_ERR;
                break;
@@ -381,7 +378,7 @@ static int handle_error_cqe(struct mthca_dev *dev, struct mthca_cq *cq,
                entry->status = IB_WCS_LOCAL_ACCESS_ERR;
                break;
        case SYNDROME_REMOTE_INVAL_REQ_ERR:
-               entry->status = IB_WCS_REM_INV_REQ_ERR;
+               entry->status = IB_WCS_REM_INVALID_REQ_ERR;
                break;
        case SYNDROME_REMOTE_ACCESS_ERR:
                entry->status = IB_WCS_REM_ACCESS_ERR;
@@ -395,21 +392,14 @@ static int handle_error_cqe(struct mthca_dev *dev, struct mthca_cq *cq,
        case SYNDROME_RNR_RETRY_EXC_ERR:
                entry->status = IB_WCS_RNR_RETRY_ERR;
                break;
-       case SYNDROME_LOCAL_RDD_VIOL_ERR:
-               entry->status = IB_WCS_LOCAL_RDD_VIOL_ERR;
-               break;
        case SYNDROME_REMOTE_INVAL_RD_REQ_ERR:
                entry->status = IB_WCS_REM_INVALID_REQ_ERR;
                break;
        case SYNDROME_REMOTE_ABORTED_ERR:
-               entry->status = IB_WCS_REM_ABORT_ERR;
-               break;
+       case SYNDROME_LOCAL_EEC_OP_ERR:
+       case SYNDROME_LOCAL_RDD_VIOL_ERR:
        case SYNDROME_INVAL_EECN_ERR:
-               entry->status = IB_WCS_INV_EECN_ERR;
-               break;
        case SYNDROME_INVAL_EEC_STATE_ERR:
-               entry->status = IB_WCS_INV_EEC_STATE_ERR;
-               break;
        default:
                entry->status = IB_WCS_GENERAL_ERR;
                break;
@@ -500,8 +490,6 @@ static inline int mthca_poll_one(struct mthca_dev *dev,
                }
        }
 
-       entry->qp_num = (*cur_qp)->qpn;
-
        if (is_send) {
                wq = &(*cur_qp)->sq;
                wqe_index = ((cl_ntoh32(cqe->wqe) - (*cur_qp)->send_wqe_offset)
index d1b80d4f0766480eac82be3edb076e2c22978926..26776ecdb455a29b5eafad1067ef64d340f435ec 100644 (file)
@@ -203,9 +203,6 @@ static int handle_error_cqe(struct mthca_cq *cq,
        case SYNDROME_LOCAL_QP_OP_ERR:
                entry->status = IB_WCS_LOCAL_OP_ERR;
                break;
-       case SYNDROME_LOCAL_EEC_OP_ERR:
-               entry->status = IB_WCS_LOCAL_EEC_OP_ERR;
-               break;
        case SYNDROME_LOCAL_PROT_ERR:
                entry->status = IB_WCS_LOCAL_PROTECTION_ERR;
                break;
@@ -222,7 +219,7 @@ static int handle_error_cqe(struct mthca_cq *cq,
                entry->status = IB_WCS_LOCAL_ACCESS_ERR;
                break;
        case SYNDROME_REMOTE_INVAL_REQ_ERR:
-               entry->status = IB_WCS_REM_INV_REQ_ERR;
+               entry->status = IB_WCS_REM_INVALID_REQ_ERR;
                break;
        case SYNDROME_REMOTE_ACCESS_ERR:
                entry->status = IB_WCS_REM_ACCESS_ERR;
@@ -236,21 +233,12 @@ static int handle_error_cqe(struct mthca_cq *cq,
        case SYNDROME_RNR_RETRY_EXC_ERR:
                entry->status = IB_WCS_RNR_RETRY_ERR;
                break;
+       case SYNDROME_LOCAL_EEC_OP_ERR:
        case SYNDROME_LOCAL_RDD_VIOL_ERR:
-               entry->status = IB_WCS_LOCAL_RDD_VIOL_ERR;
-               break;
        case SYNDROME_REMOTE_INVAL_RD_REQ_ERR:
-               entry->status = IB_WCS_REM_INVALID_REQ_ERR;
-               break;
        case SYNDROME_REMOTE_ABORTED_ERR:
-               entry->status = IB_WCS_REM_ABORT_ERR;
-               break;
        case SYNDROME_INVAL_EECN_ERR:
-               entry->status = IB_WCS_INV_EECN_ERR;
-               break;
        case SYNDROME_INVAL_EEC_STATE_ERR:
-               entry->status = IB_WCS_INV_EEC_STATE_ERR;
-               break;
        default:
                entry->status = IB_WCS_GENERAL_ERR;
                break;
@@ -344,8 +332,6 @@ static inline int mthca_poll_one(struct mthca_cq *cq,
                }
        }
 
-       entry->qp_num = (*cur_qp)->ibv_qp.qp_num;
-
        if (is_send) {
                wq = &(*cur_qp)->sq;
                wqe_index = ((cl_ntoh32(cqe->wqe) - (*cur_qp)->send_wqe_offset) >> wq->wqe_shift);