@@ -420,14 +420,14 @@ sshmem_mkey_t *mca_spml_ucx_register(void* addr,
420420 int * count )
421421{
422422 sshmem_mkey_t * mkeys ;
423- ucs_status_t err ;
423+ ucs_status_t status ;
424424 spml_ucx_mkey_t * ucx_mkey ;
425425 size_t len ;
426- int my_pe = oshmem_my_proc_id ();
427426 ucp_mem_map_params_t mem_map_params ;
428427 int segno ;
429428 map_segment_t * mem_seg ;
430429 unsigned flags ;
430+ int my_pe = oshmem_my_proc_id ();
431431
432432 * count = 0 ;
433433 mkeys = (sshmem_mkey_t * ) calloc (1 , sizeof (* mkeys ));
@@ -455,17 +455,18 @@ sshmem_mkey_t *mca_spml_ucx_register(void* addr,
455455 mem_map_params .length = size ;
456456 mem_map_params .flags = flags ;
457457
458- err = ucp_mem_map (mca_spml_ucx .ucp_context , & mem_map_params , & ucx_mkey -> mem_h );
459- if (UCS_OK != err ) {
458+ status = ucp_mem_map (mca_spml_ucx .ucp_context , & mem_map_params , & ucx_mkey -> mem_h );
459+ if (UCS_OK != status ) {
460460 goto error_out ;
461461 }
462+
462463 } else {
463464 ucx_mkey -> mem_h = (ucp_mem_h )mem_seg -> context ;
464465 }
465466
466- err = ucp_rkey_pack (mca_spml_ucx .ucp_context , ucx_mkey -> mem_h ,
467- & mkeys [0 ].u .data , & len );
468- if (UCS_OK != err ) {
467+ status = ucp_rkey_pack (mca_spml_ucx .ucp_context , ucx_mkey -> mem_h ,
468+ & mkeys [0 ].u .data , & len );
469+ if (UCS_OK != status ) {
469470 goto error_unmap ;
470471 }
471472 if (len >= 0xffff ) {
@@ -475,10 +476,10 @@ sshmem_mkey_t *mca_spml_ucx_register(void* addr,
475476 oshmem_shmem_abort (-1 );
476477 }
477478
478- err = ucp_ep_rkey_unpack (mca_spml_ucx .ucp_peers [oshmem_group_self -> my_pe ].ucp_conn ,
479- mkeys [0 ].u .data ,
480- & ucx_mkey -> rkey );
481- if (UCS_OK != err ) {
479+ status = ucp_ep_rkey_unpack (mca_spml_ucx .ucp_peers [oshmem_group_self -> my_pe ].ucp_conn ,
480+ mkeys [0 ].u .data ,
481+ & ucx_mkey -> rkey );
482+ if (UCS_OK != status ) {
482483 SPML_ERROR ("failed to unpack rkey" );
483484 goto error_unmap ;
484485 }
0 commit comments