22 #ifndef MCA_BTL_SCTP_H
23 #define MCA_BTL_SCTP_H
25 #include "ompi_config.h"
26 #ifdef HAVE_SYS_TYPES_H
27 #include <sys/types.h>
29 #ifdef HAVE_SYS_SOCKET_H
30 #include <sys/socket.h>
32 #ifdef HAVE_NETINET_IN_H
33 #include <netinet/in.h>
37 #include "opal/mca/event/event.h"
38 #include "ompi/class/ompi_free_list.h"
48 #define MCA_BTL_SCTP_DONT_USE_HASH 1
52 #define SCTP_BTL_ERROR(args)
54 #define SCTP_BTL_ERROR(args) BTL_ERROR(args)
57 #define MCA_BTL_SCTP_STATISTICS 0
75 #if MCA_BTL_SCTP_DONT_USE_HASH
109 #if MCA_BTL_SCTP_STATISTICS
110 size_t sctp_bytes_sent;
111 size_t sctp_bytes_recv;
112 size_t sctp_send_handler;
118 #if defined(__WINDOWS__)
119 #define CLOSE_THE_SOCKET(socket) closesocket(socket)
121 #define CLOSE_THE_SOCKET(socket) close(socket)
132 int *num_btl_modules,
133 bool allow_multi_user_threads,
134 bool have_hidden_threads
210 mca_btl_base_tag_t tag
int mca_btl_sctp_get(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *btl_peer, struct mca_btl_base_descriptor_t *decriptor)
Initiate an asynchronous get.
Definition: btl_sctp.c:450
unsigned short sctp_listen_port
listen port
Definition: btl_sctp.h:83
struct mca_btl_sctp_proc_t * sctp_local
local proc struct
Definition: btl_sctp.h:69
Definition: opal_hash_table.h:42
int mca_btl_sctp_finalize(struct mca_btl_base_module_t *btl)
Cleanup any resources held by the BTL.
Definition: btl_sctp.c:481
A descriptor that holds the parameters to a send/put/get operation along w/ a callback routine that i...
Definition: btl.h:275
int sctp_ifindex
PTL interface index.
Definition: btl_sctp.h:105
int sctp_free_list_inc
number of elements to alloc when growing free lists
Definition: btl_sctp.h:72
mca_btl_base_descriptor_t * mca_btl_sctp_prepare_dst(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *peer, struct mca_mpool_base_registration_t *, struct opal_convertor_t *convertor, uint8_t order, size_t reserve, size_t *size, uint32_t flags)
Prepare a descriptor for send/rdma using the supplied convertor.
Definition: btl_sctp.c:321
int sctp_endpoint_cache
amount of cache on each endpoint
Definition: btl_sctp.h:73
Definition: opal_bitmap.h:53
int sctp_use_nodelay
SCTP_NODELAY value.
Definition: btl_sctp.h:88
int sctp_sndbuf
socket sndbuf size
Definition: btl_sctp.h:86
Structure to represent a single event.
Definition: event_struct.h:87
Definition: mutex_unix.h:53
uint32_t sctp_num_btls
number of hcas available to the SCTP component
Definition: btl_sctp.h:67
int mca_btl_sctp_put(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *btl_peer, struct mca_btl_base_descriptor_t *decriptor)
Initiate an asynchronous put.
Definition: btl_sctp.c:405
char * sctp_if_include
comma seperated list of interface to include
Definition: btl_sctp.h:84
opal_list_t sctp_events
list of pending sctp events
Definition: btl_sctp.h:79
mca_btl_base_component_2_0_0_t super
base BTL component
Definition: btl_sctp.h:66
Remote Open MPI process structure.
Definition: proc.h:56
int sctp_if_11
Are we going 1 to 1? 1 to many is default.
Definition: btl_sctp.h:89
mca_btl_base_module_t super
base BTL interface
Definition: btl_sctp.h:104
mca_btl_base_module_t ** mca_btl_sctp_component_init(int *num_btl_modules, bool allow_multi_user_threads, bool have_hidden_threads)
SCTP component initialization.
Definition: btl_sctp_component.c:718
int mca_btl_sctp_component_progress(void)
SCTP component progress.
struct mca_btl_sctp_module_t ** sctp_btls
array of available BTL modules
Definition: btl_sctp.h:68
int mca_btl_sctp_free(struct mca_btl_base_module_t *btl, mca_btl_base_descriptor_t *des)
Return a segment allocated by this BTL.
Definition: btl_sctp.c:204
opal_event_t sctp_recv_event
recv event for listen socket
Definition: btl_sctp.h:81
int sctp_free_list_max
maximum size of free lists
Definition: btl_sctp.h:71
int mca_btl_sctp_send(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *btl_peer, struct mca_btl_base_descriptor_t *descriptor, mca_btl_base_tag_t tag)
Initiate an asynchronous send.
Definition: btl_sctp.c:362
Byte Transfer Layer (BTL)
opal_mutex_t sctp_lock
lock for accessing module state
Definition: btl_sctp.h:80
mca_btl_base_descriptor_t * mca_btl_sctp_prepare_src(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *peer, struct mca_mpool_base_registration_t *, struct opal_convertor_t *convertor, uint8_t order, size_t reserve, size_t *size, uint32_t flags)
Prepare a descriptor for send/rdma using the supplied convertor.
Definition: btl_sctp.c:220
Definition: ompi_free_list.h:39
A hash table that may be indexed with either fixed length (e.g.
int mca_btl_sctp_add_procs(struct mca_btl_base_module_t *btl, size_t nprocs, struct ompi_proc_t **procs, struct mca_btl_base_endpoint_t **peers, opal_bitmap_t *reachable)
PML->BTL notification of change in the process list.
Definition: btl_sctp.c:69
State of ELAN endpoint connection.
Definition: btl_elan_endpoint.h:33
BTL component descriptor.
Definition: btl.h:411
Copyright (c) 2004-2007 The Trustees of Indiana University and Indiana University Research and Techno...
int sctp_listen_sd
listen socket for incoming connection requests
Definition: btl_sctp.h:82
Definition: opal_convertor.h:90
int sctp_free_list_num
initial size of free lists
Definition: btl_sctp.h:70
Definition: opal_list.h:147
struct sockaddr_in sctp_ifaddr
PTL interface address.
Definition: btl_sctp.h:106
char * sctp_if_exclude
comma seperated list of interface to exclude
Definition: btl_sctp.h:85
mca_btl_base_descriptor_t * mca_btl_sctp_alloc(struct mca_btl_base_module_t *btl, struct mca_btl_base_endpoint_t *endpoint, uint8_t order, size_t size, uint32_t flags)
Allocate a descriptor with a segment of the requested size.
Definition: btl_sctp.c:167
int mca_btl_sctp_del_procs(struct mca_btl_base_module_t *btl, size_t nprocs, struct ompi_proc_t **procs, struct mca_btl_base_endpoint_t **peers)
PML->BTL notification of change in the process list.
Definition: btl_sctp.c:141
SCTP BTL component.
Definition: btl_sctp.h:65
struct sockaddr_in sctp_ifmask
PTL interface netmask.
Definition: btl_sctp.h:107
opal_hash_table_t sctp_procs
hash table of sctp proc structures
Definition: btl_sctp.h:74
BTL module interface functions and attributes.
Definition: btl.h:786
int sctp_rcvbuf
socket rcvbuf size
Definition: btl_sctp.h:87
BTL Module Interface.
Definition: btl_sctp.h:103
Represents the state of a remote process and the set of addresses that it exports.
Definition: btl_sctp_proc.h:37