OpenMPI  0.1.1
base.h
1 /*
2  * Copyright (c) 2007-2008 Cisco Systems, Inc. All rights reserved.
3  * Copyright (c) 2009 Mellanox Technologies. All rights reserved.
4  *
5  * $COPYRIGHT$
6  *
7  * Additional copyrights may follow
8  *
9  * $HEADER$
10  */
11 
12 #ifndef BTL_OPENIB_CONNECT_BASE_H
13 #define BTL_OPENIB_CONNECT_BASE_H
14 
15 #include "connect/connect.h"
16 
17 #ifdef OMPI_HAVE_RDMAOE
18 #define BTL_OPENIB_CONNECT_BASE_CHECK_IF_NOT_IB(btl) \
19  (((IBV_TRANSPORT_IB != ((btl)->device->ib_dev->transport_type)) || \
20  (IBV_LINK_LAYER_ETHERNET == ((btl)->ib_port_attr.link_layer))) ? \
21  true : false)
22 #else
23 #define BTL_OPENIB_CONNECT_BASE_CHECK_IF_NOT_IB(btl) \
24  ((IBV_TRANSPORT_IB != ((btl)->device->ib_dev->transport_type)) ? \
25  true : false)
26 #endif
27 
28 BEGIN_C_DECLS
29 
30 /*
31  * Forward declaration to resolve circular dependency
32  */
34 
35 /*
36  * Open function
37  */
38 int ompi_btl_openib_connect_base_register(void);
39 
40 /*
41  * Component-wide CPC init
42  */
43 int ompi_btl_openib_connect_base_init(void);
44 
45 /*
46  * Query CPCs to see if they want to run on a specific module
47  */
48 int ompi_btl_openib_connect_base_select_for_local_port
50 
51 /*
52  * Forward reference to avoid an include file loop
53  */
55 
56 /*
57  * Select function
58  */
59 int ompi_btl_openib_connect_base_find_match
61  struct mca_btl_openib_proc_modex_t *peer_port,
64 
65 /*
66  * Find a CPC's index so that we can send it in the modex
67  */
68 int ompi_btl_openib_connect_base_get_cpc_index
70 
71 /*
72  * Lookup a CPC by its index (received from the modex)
73  */
75  ompi_btl_openib_connect_base_get_cpc_byindex(uint8_t index);
76 
77 /*
78  * Allocate a CTS frag
79  */
80 int ompi_btl_openib_connect_base_alloc_cts(
81  struct mca_btl_base_endpoint_t *endpoint);
82 
83 /*
84  * Free a CTS frag
85  */
86 int ompi_btl_openib_connect_base_free_cts(
87  struct mca_btl_base_endpoint_t *endpoint);
88 
89 /*
90  * Start a new connection to an endpoint
91  */
92 int ompi_btl_openib_connect_base_start(
94  struct mca_btl_base_endpoint_t *endpoint);
95 
96 
97 /*
98  * Component-wide CPC finalize
99  */
100 void ompi_btl_openib_connect_base_finalize(void);
101 
102 END_C_DECLS
103 
104 #endif
IB BTL Interface.
Definition: btl_openib.h:432
Struct for holding CPC module and associated meta data.
Definition: connect.h:328
State of ELAN endpoint connection.
Definition: btl_elan_endpoint.h:33
Meta data about a CPC module.
Definition: connect.h:303
Data received from the modex.
Definition: btl_openib_proc.h:44
CPC component struct.
Definition: connect.h:245