@@ -684,12 +684,18 @@ ucs_status_t ucp_worker_mem_type_eps_create(ucp_worker_h worker)
684684 ucs_status_t status ;
685685 void * address_buffer ;
686686 size_t address_length ;
687- ucp_tl_bitmap_t mem_access_tls ;
687+ ucp_tl_bitmap_t mem_access_tls , host_mem_access_tls ;
688688 char ep_name [UCP_WORKER_ADDRESS_NAME_MAX ];
689689 unsigned addr_indices [UCP_MAX_LANES ];
690+ ucp_lane_index_t num_lanes ;
690691
691692 ucs_memory_type_for_each (mem_type ) {
692693 ucp_context_memaccess_tl_bitmap (context , mem_type , 0 , & mem_access_tls );
694+ /* Mem type EP requires host memory support */
695+ ucp_context_memaccess_tl_bitmap (context , UCS_MEMORY_TYPE_HOST , 0 ,
696+ & host_mem_access_tls );
697+ UCS_STATIC_BITMAP_AND_INPLACE (& mem_access_tls , host_mem_access_tls );
698+
693699 if (UCP_MEM_IS_HOST (mem_type ) ||
694700 UCS_STATIC_BITMAP_IS_ZERO (mem_access_tls )) {
695701 continue ;
@@ -725,6 +731,9 @@ ucs_status_t ucp_worker_mem_type_eps_create(ucp_worker_h worker)
725731 goto err_free_address_list ;
726732 }
727733
734+ /* Mem type EP cannot have more than one lane */
735+ num_lanes = ucp_ep_num_lanes (worker -> mem_type_ep [mem_type ]);
736+ ucs_assertv_always (num_lanes == 1 , "num_lanes=%u" , num_lanes );
728737 UCS_ASYNC_UNBLOCK (& worker -> async );
729738
730739 ucs_free (local_address .address_list );
0 commit comments