[DPL] Dynamic EVD enlargement code removed as it caused
authorstansmith <stansmith@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Fri, 13 Apr 2007 22:35:53 +0000 (22:35 +0000)
committerstansmith <stansmith@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Fri, 13 Apr 2007 22:35:53 +0000 (22:35 +0000)
      more problems than it was worth.
[DAPL] Do not use ca_attr->max_sges
       for qp_create.rq_sge and qp_create.rq_sge.
       Use what caller supplied.
       Both changes allowed MPI testing to proceed
       without QP create errors. Sync with Linux src.

git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@630 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/dapl/dapl/ibal/dapl_ibal_qp.c

index 2d3ea96..c6a4574 100644 (file)
@@ -136,40 +136,6 @@ dapls_ib_qp_alloc (
     cq_recv = IB_INVALID_HANDLE;\r
     cq_send = IB_INVALID_HANDLE;\r
 \r
-       /* Dynamic EVD enlargement */\r
-       if ( recv_evd_ptr == request_evd_ptr ) \r
-       {\r
-               DAT_COUNT       min_qlen = attr->max_recv_dtos + attr->max_request_dtos;\r
-               if ( min_qlen > recv_evd_ptr->qlen )\r
-               {\r
-                       dat_status = dapl_evd_resize ((DAT_EVD_HANDLE)recv_evd_ptr, \r
-                                                                                       min_qlen);\r
-                       if ( dat_status != DAT_SUCCESS ) {\r
-                               dapl_dbg_log (DAPL_DBG_TYPE_ERR,"--> DsQA: failed to resize EVD(%p)\n",recv_evd_ptr);\r
-                               return dat_status;\r
-                       }\r
-               }\r
-       } else {\r
-               if (attr->max_recv_dtos > recv_evd_ptr->qlen)\r
-               {\r
-                       dat_status = dapl_evd_resize ((DAT_EVD_HANDLE)recv_evd_ptr, \r
-                                                                                       attr->max_recv_dtos);\r
-                       if ( dat_status != DAT_SUCCESS ) {\r
-                               dapl_dbg_log (DAPL_DBG_TYPE_ERR,"--> DsQA: failed to resize EVD(%p)\n",recv_evd_ptr);\r
-                               return dat_status;\r
-                       }\r
-               }\r
-               if (attr->max_request_dtos > request_evd_ptr->qlen)\r
-               {\r
-                       dat_status = dapl_evd_resize ((DAT_EVD_HANDLE)request_evd_ptr, \r
-                                                                                       attr->max_request_dtos);\r
-                       if ( dat_status != DAT_SUCCESS ) {\r
-                               dapl_dbg_log (DAPL_DBG_TYPE_ERR,"--> DsQA: failed to resize EVD(%p)\n",request_evd_ptr);\r
-                               return dat_status;\r
-                       }\r
-               }\r
-       }\r
-\r
     dapl_os_assert ( recv_evd_ptr != DAT_HANDLE_NULL );\r
     {\r
         cq_recv = (ib_cq_handle_t) recv_evd_ptr->ib_cq_handle;\r
@@ -236,17 +202,21 @@ dapls_ib_qp_alloc (
      */\r
     p_ca = (dapl_ibal_ca_t *) ia_ptr->hca_ptr->ib_hca_handle;\r
 \r
-\r
     dapl_os_memzero (&qp_create, sizeof (qp_create));\r
     qp_create.qp_type     = IB_QPT_RELIABLE_CONN;\r
     qp_create.sq_depth    = attr->max_request_dtos;\r
     qp_create.rq_depth    = attr->max_recv_dtos;\r
-    qp_create.sq_sge      = p_ca->p_ca_attr->max_sges;\r
-    qp_create.rq_sge      = p_ca->p_ca_attr->max_sges;\r
+    qp_create.sq_sge      = attr->max_recv_iov;\r
+    qp_create.rq_sge      = attr->max_request_iov;                       \r
     qp_create.h_sq_cq     = cq_send;\r
     qp_create.h_rq_cq     = cq_recv;\r
     qp_create.sq_signaled = FALSE;\r
 \r
+    dapl_dbg_log (DAPL_DBG_TYPE_EP, \r
+               "--> DsQA: sqd,iov=%d,%d rqd,iov=%d,%d\n", \r
+               attr->max_request_dtos, attr->max_request_iov,\r
+               attr->max_recv_dtos, attr->max_recv_iov); \r
+    \r
     ib_status = ib_create_qp ( \r
                        ib_pd_handle,\r
                        &qp_create,\r
@@ -256,7 +226,8 @@ dapls_ib_qp_alloc (
 \r
     if (ib_status != IB_SUCCESS)\r
     {\r
-       dapl_dbg_log (DAPL_DBG_TYPE_ERR, "--> DsQA: Create QP failed = %s\n", ib_get_err_str(ib_status));\r
+       dapl_dbg_log (DAPL_DBG_TYPE_ERR, \r
+               "--> DsQA: Create QP failed = %s\n", ib_get_err_str(ib_status));\r
        return (DAT_INSUFFICIENT_RESOURCES);\r
     }\r
 \r