[WSD] Rename some structures to make the code more readable.
authortzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 23 Sep 2007 08:51:48 +0000 (08:51 +0000)
committertzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 23 Sep 2007 08:51:48 +0000 (08:51 +0000)
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@827 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/wsd/user/extensions.c
ulp/wsd/user/ibsp_mem.c
ulp/wsd/user/ibspdll.c
ulp/wsd/user/ibspstruct.h

index 2839ce8..c548691 100644 (file)
@@ -245,8 +245,8 @@ IBSPRegisterRdmaMemory(
        desc = lpRdmaBufferDescriptor;\r
 \r
        desc->iova = (uint64_t) (uintptr_t) lpBuffer;\r
-       desc->lkey = node2->p_reg->lkey;\r
-       desc->rkey = node2->p_reg->rkey;\r
+       desc->lkey = node2->p_reg1->lkey;\r
+       desc->rkey = node2->p_reg1->rkey;\r
        desc->node1 = node2;\r
 \r
        *lpErrno = 0;\r
@@ -417,7 +417,7 @@ do_rdma_op(
                local_ds[ds_idx].vaddr = (uint64_t)(void* __ptr64)lpBuffers[ds_idx].buf;\r
                local_ds[ds_idx].length = lpBuffers[ds_idx].len;\r
                local_ds[ds_idx].lkey =\r
-                       ((struct memory_node*)lpBuffers[ds_idx].handle)->p_reg->lkey;\r
+                       ((struct memory_node*)lpBuffers[ds_idx].handle)->p_reg1->lkey;\r
 \r
                lpOverlapped->InternalHigh += lpBuffers[ds_idx].len;\r
        }\r
index 375bbe9..30782b1 100644 (file)
@@ -78,8 +78,8 @@ lookup_partial_mr(
                p_item = cl_qlist_next( p_item ) )\r
        {\r
                p_node = PARENT_STRUCT( p_item, struct memory_node, socket_item );\r
-               if(p_node->p_reg &&\r
-                       __check_mr( p_node->p_reg, acl_mask, start, len ) )\r
+               if(p_node->p_reg1 &&\r
+                       __check_mr( p_node->p_reg1, acl_mask, start, len ) )\r
                {\r
                        cl_spinlock_release( &s->port->hca->rdma_mem_list.mutex );\r
                        IBSP_EXIT( IBSP_DBG_MEM );\r
@@ -140,7 +140,7 @@ ibsp_reg_mem(
 \r
                if( __check_mr( p_reg, access_ctrl, start, len ) )\r
                {\r
-                       p_node->p_reg = p_reg;\r
+                       p_node->p_reg1 = p_reg;\r
                        p_node->s = s;\r
                        cl_qlist_insert_tail( &p_reg->node_list, &p_node->mr_item );\r
                        cl_qlist_insert_head(\r
@@ -189,7 +189,7 @@ ibsp_reg_mem(
 \r
        STAT_INC( mr_num );\r
 \r
-       p_node->p_reg = p_reg;\r
+       p_node->p_reg1 = p_reg;\r
        p_node->s = s;\r
 \r
        /* Link to the list of nodes. */\r
@@ -211,8 +211,8 @@ static inline int __ibsp_dereg_mem_mr(
        IBSP_ENTER( IBSP_DBG_MEM );\r
 \r
        // Underlying registration could be freed before the node.\r
-       if( node->p_reg )\r
-               cl_qlist_remove_item( &node->p_reg->node_list, &node->mr_item );\r
+       if( node->p_reg1 )\r
+               cl_qlist_remove_item( &node->p_reg1->node_list, &node->mr_item );\r
 \r
        cl_qlist_remove_item( &node->s->mr_list, &node->socket_item );\r
 \r
@@ -278,7 +278,7 @@ ibsp_dereg_hca(
                {\r
                        struct memory_node *p_node =\r
                                PARENT_STRUCT( item1, struct memory_node, mr_item );\r
-                       p_node->p_reg = NULL;\r
+                       p_node->p_reg1 = NULL;\r
                }\r
 \r
                IBSP_PRINT(TRACE_LEVEL_INFORMATION, IBSP_DBG_MEM, ("unpinning ,memory reg %p\n", p_reg) );\r
@@ -379,7 +379,7 @@ ibsp_hca_flush_mr_cache(
                        struct memory_node *p_node =\r
                                PARENT_STRUCT( p_item1, struct memory_node, mr_item );\r
 \r
-                       p_node->p_reg = NULL;\r
+                       p_node->p_reg1 = NULL;\r
                }\r
 \r
                cl_qlist_remove_item( &p_hca->rdma_mem_list.list, &p_reg->item );\r
index ae42764..1843e20 100644 (file)
@@ -1645,7 +1645,7 @@ IBSPRecv(
                wr->ds_array[ds_idx].vaddr =\r
                        (uint64_t)(void* __ptr64)lpBuffers[ds_idx].buf;\r
                wr->ds_array[ds_idx].length = lpBuffers[ds_idx].len;\r
-               wr->ds_array[ds_idx].lkey = node->p_reg->lkey;\r
+               wr->ds_array[ds_idx].lkey = node->p_reg1->lkey;\r
        }\r
 \r
        /*\r
@@ -1876,7 +1876,7 @@ IBSPSend(
                                return SOCKET_ERROR;\r
                        }\r
 \r
-                       local_ds[ds_idx].lkey = node->p_reg->lkey;\r
+                       local_ds[ds_idx].lkey = node->p_reg1->lkey;\r
                }\r
        }\r
 \r
index 867267d..46fb0e5 100644 (file)
@@ -184,7 +184,7 @@ struct memory_node
        struct ibsp_socket_info *s;\r
        /* List item to track within the registration structure. */\r
        cl_list_item_t                  mr_item;\r
-       struct memory_reg               *p_reg;\r
+       struct memory_reg               *p_reg1;\r
 };\r
 \r
 \r