summaryrefslogtreecommitdiffstats
path: root/src/include/gpxe/ib_mad.h
diff options
context:
space:
mode:
authorMichael Brown2009-08-09 22:00:48 +0200
committerMichael Brown2009-08-10 23:31:55 +0200
commit0ff5c456cb1ad38c3300a214799478101a3540a6 (patch)
tree4827eb2eb1af8a07afd4c304957c06b9513f006a /src/include/gpxe/ib_mad.h
parent[infiniband] Allow SRP reconnection attempts even after reporting failures (diff)
downloadipxe-0ff5c456cb1ad38c3300a214799478101a3540a6.tar.gz
ipxe-0ff5c456cb1ad38c3300a214799478101a3540a6.tar.xz
ipxe-0ff5c456cb1ad38c3300a214799478101a3540a6.zip
[infiniband] Disambiguate CM connection rejection reasons
There is diagnostic value in being able to disambiguate between the various reasons why an IB CM has rejected a connection attempt. In particular, reason 8 "invalid service ID" can be used to identify an incorrect SRP service_id root-path component, and reason 28 "consumer reject" corresponds to a genuine SRP login rejection IU, which can be passed up to the SRP layer. For rejection reasons other than "consumer reject", we should not pass through the private data, since it is most likely generated by the CM without any protocol-specific knowledge.
Diffstat (limited to 'src/include/gpxe/ib_mad.h')
-rw-r--r--src/include/gpxe/ib_mad.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/include/gpxe/ib_mad.h b/src/include/gpxe/ib_mad.h
index 54d0a2af..8b497183 100644
--- a/src/include/gpxe/ib_mad.h
+++ b/src/include/gpxe/ib_mad.h
@@ -402,6 +402,11 @@ struct ib_cm_connect_reject {
uint8_t private_data[148];
} __attribute__ (( packed ));
+/** CM rejection reasons */
+#define IB_CM_REJECT_BAD_SERVICE_ID 8
+#define IB_CM_REJECT_STALE_CONN 10
+#define IB_CM_REJECT_CONSUMER 28
+
/** A communication management connection reply
*
* Defined in section 12.6.8 of the IBA.