summaryrefslogtreecommitdiffstats
path: root/include/rdma/ib_cm.h
diff options
context:
space:
mode:
authorSean Hefty <sean.hefty@intel.com>2007-08-01 13:49:53 -0700
committerRoland Dreier <rolandd@cisco.com>2007-10-09 19:59:17 -0700
commitde98b693e9857e183679cd2f49b3c30d2bc57629 (patch)
treebfb31d9109f5057926b8849671e2937df22b37fd /include/rdma/ib_cm.h
parent1a1eb6a646f52dc62e3f9ceac4aab9c27e781186 (diff)
IB/cm: Modify interface to send MRAs in response to duplicate messages
The IB CM provides a message received acknowledged (MRA) message that can be sent to indicate that a REQ or REP message has been received, but will require more time to process than the timeout specified by those messages. In many cases, the application may not know how long it will take to respond to a CM message, but the majority of the time, it will usually respond before a retry has been sent. Rather than sending an MRA in response to all messages just to handle the case where a longer timeout is needed, it is more efficient to queue the MRA for sending in case a duplicate message is received. This avoids sending an MRA when it is not needed, but limits the number of times that a REQ or REP will be resent. It also provides for a simpler implementation than generating the MRA based on a timer event. (That is, trying to send the MRA after receiving the first REQ or REP if a response has not been generated, so that it is received at the remote side before a duplicate REQ or REP has been received) Signed-off-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'include/rdma/ib_cm.h')
-rw-r--r--include/rdma/ib_cm.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/rdma/ib_cm.h b/include/rdma/ib_cm.h
index 12243e80c70..a627c8682d2 100644
--- a/include/rdma/ib_cm.h
+++ b/include/rdma/ib_cm.h
@@ -477,12 +477,15 @@ int ib_send_cm_rej(struct ib_cm_id *cm_id,
const void *private_data,
u8 private_data_len);
+#define IB_CM_MRA_FLAG_DELAY 0x80 /* Send MRA only after a duplicate msg */
+
/**
* ib_send_cm_mra - Sends a message receipt acknowledgement to a connection
* message.
* @cm_id: Connection identifier associated with the connection message.
- * @service_timeout: The maximum time required for the sender to reply to
- * to the connection message.
+ * @service_timeout: The lower 5-bits specify the maximum time required for
+ * the sender to reply to to the connection message. The upper 3-bits
+ * specify additional control flags.
* @private_data: Optional user-defined private data sent with the
* message receipt acknowledgement.
* @private_data_len: Size of the private data buffer, in bytes.