Skip to content

Commit

Permalink
UCP/WIREUP: do not enable KA on CM lane
Browse files Browse the repository at this point in the history
  • Loading branch information
evgeny-leksikov committed Jun 9, 2021
1 parent 5b4b7ef commit df2dead
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions src/ucp/core/ucp_proxy_ep.c
Original file line number Diff line number Diff line change
Expand Up @@ -214,22 +214,30 @@ static void ucp_proxy_ep_replace_if_owned(uct_ep_h uct_ep, uct_ep_h owned_ep,
void ucp_proxy_ep_replace(ucp_proxy_ep_t *proxy_ep)
{
ucp_ep_h ucp_ep = proxy_ep->ucp_ep;
uct_ep_h tl_ep = NULL;
ucp_lane_index_t lane;
uct_ep_h tl_ep = NULL;
ucs_status_t status;

ucs_assert(proxy_ep->uct_ep != NULL);
for (lane = 0; lane < ucp_ep_num_lanes(ucp_ep); ++lane) {
if (ucp_ep->uct_eps[lane] == &proxy_ep->super) {
ucs_assert(proxy_ep->uct_ep != NULL); /* make sure there is only one match */
ucp_ep->uct_eps[lane] = proxy_ep->uct_ep;
tl_ep = ucp_ep->uct_eps[lane];
proxy_ep->uct_ep = NULL;
status = uct_ep_enable_keep_alive(tl_ep, 1);
if (status != UCS_OK) {
ucs_diag("ep %p: uct_ep_enable_keep_alive(tl_ep=%p, 1) failed %s",
ucp_ep, tl_ep, ucs_status_string(status));
}
if (ucp_ep->uct_eps[lane] != &proxy_ep->super) {
continue;
}

/* make sure there is only one match */
ucs_assert(proxy_ep->uct_ep != NULL);
ucp_ep->uct_eps[lane] = proxy_ep->uct_ep;
tl_ep = ucp_ep->uct_eps[lane];
proxy_ep->uct_ep = NULL;

if (ucp_ep_get_cm_lane(ucp_ep) == lane) {
continue;
}

status = uct_ep_enable_keep_alive(tl_ep, 1);
if (status != UCS_OK) {
ucs_diag("ep %p: uct_ep_enable_keep_alive(tl_ep=%p, 1) failed %s",
ucp_ep, tl_ep, ucs_status_string(status));
}
}

Expand Down

0 comments on commit df2dead

Please sign in to comment.