1RDMA_CREATE_ID(3) Librdmacm Programmer's Manual RDMA_CREATE_ID(3)
2
3
4
6 rdma_create_id - Allocate a communication identifier.
7
9 #include <rdma/rdma_cma.h>
10
11 int rdma_create_id (struct rdma_event_channel *channel, struct
12 rdma_cm_id **id, void *context, enum rdma_port_space ps);
13
15 channel The communication channel that events associated with the
16 allocated rdma_cm_id will be reported on. This may be
17 NULL.
18
19 id A reference where the allocated communication identifier
20 will be returned.
21
22 context User specified context associated with the rdma_cm_id.
23
24 ps RDMA port space.
25
27 Creates an identifier that is used to track communication information.
28
30 Returns 0 on success, or -1 on error. If an error occurs, errno will
31 be set to indicate the failure reason.
32
34 Rdma_cm_id's are conceptually equivalent to a socket for RDMA communi‐
35 cation. The difference is that RDMA communication requires explicitly
36 binding to a specified RDMA device before communication can occur, and
37 most operations are asynchronous in nature. Asynchronous communication
38 events on an rdma_cm_id are reported through the associated event chan‐
39 nel. If the channel parameter is NULL, the rdma_cm_id will be placed
40 into synchronous operation. While operating synchronously, calls that
41 result in an event will block until the operation completes. The event
42 will be returned to the user through the rdma_cm_id structure, and be
43 available for access until another rdma_cm call is made.
44
45 Users must release the rdma_cm_id by calling rdma_destroy_id.
46
48 Details of the services provided by the different port spaces are out‐
49 lined below.
50
51 RDMA_PS_TCP
52 Provides reliable, connection-oriented QP communication. Unlike
53 TCP, the RDMA port space provides message, not stream, based
54 communication.
55
56 RDMA_PS_UDP
57 Provides unreliable, connectionless QP communication. Supports
58 both datagram and multicast communication.
59
60 RDMA_PS_IB
61 Provides for any IB services (UD, UC, RC, XRC, etc.).
62
64 rdma_cm(7), rdma_create_event_channel(3), rdma_destroy_id(3),
65 rdma_get_devices(3), rdma_bind_addr(3), rdma_resolve_addr(3), rdma_con‐
66 nect(3), rdma_listen(3), rdma_set_option(3)
67
68
69
70librdmacm 2010-07-19 RDMA_CREATE_ID(3)