Skip to content

Commit 32606ad

Browse files
committed
btl/tcp: fix heterogeneous support for put / large messages
Signed-off-by: Gilles Gouaillardet <[email protected]>
1 parent 626e94b commit 32606ad

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

opal/mca/btl/tcp/btl_tcp.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* All rights reserved.
1313
* Copyright (c) 2006-2015 Los Alamos National Security, LLC. All rights
1414
* reserved.
15-
* Copyright (c) 2016 Research Organization for Information Science
15+
* Copyright (c) 2016-2017 Research Organization for Information Science
1616
* and Technology (RIST). All rights reserved.
1717
* Copyright (c) 2016 Intel, Inc. All rights reserved.
1818
*
@@ -381,6 +381,7 @@ int mca_btl_tcp_put (mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t
381381

382382
frag->segments[1].seg_addr.lval = remote_address;
383383
frag->segments[1].seg_len = size;
384+
if (endpoint->endpoint_nbo) MCA_BTL_BASE_SEGMENT_HTON(frag->segments[1]);
384385

385386
frag->base.des_flags = MCA_BTL_DES_FLAGS_BTL_OWNERSHIP | MCA_BTL_DES_SEND_ALWAYS_CALLBACK;
386387
frag->base.des_cbfunc = fake_rdma_complete;

opal/mca/btl/tcp/btl_tcp_frag.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* All rights reserved.
1313
* Copyright (c) 2014 Los Alamos National Security, LLC. All rights
1414
* reserved.
15-
* Copyright (c) 2015-2016 Research Organization for Information Science
15+
* Copyright (c) 2015-2017 Research Organization for Information Science
1616
* and Technology (RIST). All rights reserved.
1717
* Copyright (c) 2015-2016 Cisco Systems, Inc. All rights reserved.
1818
* $COPYRIGHT$
@@ -291,6 +291,7 @@ bool mca_btl_tcp_frag_recv(mca_btl_tcp_frag_t* frag, int sd)
291291
goto repeat;
292292
} else if (frag->iov_idx == 2) {
293293
for( i = 0; i < frag->hdr.count; i++ ) {
294+
if (btl_endpoint->endpoint_nbo) MCA_BTL_BASE_SEGMENT_NTOH(frag->segments[i]);
294295
frag->iov[i+2].iov_base = (IOVBASE_TYPE*)frag->segments[i].seg_addr.pval;
295296
frag->iov[i+2].iov_len = frag->segments[i].seg_len;
296297
}

0 commit comments

Comments
 (0)