rdma_post_ud_send
Posts a work request to send a datagram.
Syntax
Description
Posts a work request to the
send queue of the queue pair that is associated with the rdma_cm_id
identified.
The contents of the posted buffer is sent to the specified destination
of the queue pair.
Notes: You must make sure that the
remote peer posts a receive request before processing the send operations.
If the send request is using inline data, the message buffer must
be registered before being posted with the mr
parameter
by specifying the registration. The buffer must remain registered
until the send operation is completed. The send operation cannot be
posted to an rdma_cm_id
identifier or the corresponding
queue pair until the send operation is connected. The user-defined
context that is associated with the send request is returned to the
user by using the work completionwr_id
identifier,
work request identifier, and field.
Parameters
Item | Description |
---|---|
addr | Specifies the address of the memory buffer to post the work request. |
ah | Specifies an address handle that describes the address of the remote node. |
context | Specifies the user-defined context that is associated with the request. |
flags | Specifies the optional flags that are used to control the send operation. |
id | Specifies a reference to a communication identifier where the message buffer is posted. |
length | Specifies the length of the memory buffer. |
mr | Specifies the optional registered memory region that is associated with the posted buffer. |
remote_qpn | Specifies the number of the destination queue pair. |
Return Values
Returns 0 on success, or -1 on error. If an error occurs, then errno is set to indicate the reason for failure.