iPXE
ib_mad.h
Go to the documentation of this file.
00001 #ifndef _IPXE_IB_MAD_H
00002 #define _IPXE_IB_MAD_H
00003 
00004 /** @file
00005  *
00006  * Infiniband management datagrams
00007  *
00008  */
00009 
00010 FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
00011 
00012 #include <stdint.h>
00013 #include <ipxe/ib_packet.h>
00014 
00015 /*****************************************************************************
00016  *
00017  * Subnet management MADs
00018  *
00019  *****************************************************************************
00020  */
00021 
00022 /** A subnet management header
00023  *
00024  * Defined in sections 14.2.1.1 and 14.2.1.2 of the IBA.
00025  */
00026 struct ib_smp_hdr {
00027         uint64_t mkey;
00028         uint16_t slid;
00029         uint16_t dlid;
00030         uint8_t reserved[28];
00031 } __attribute__ (( packed ));
00032 
00033 /** Subnet management class version */
00034 #define IB_SMP_CLASS_VERSION                    1
00035 
00036 /** Subnet management direction bit
00037  *
00038  * This bit resides in the "status" field in the MAD header.
00039  */
00040 #define IB_SMP_STATUS_D_INBOUND                 0x8000
00041 
00042 /* Subnet management attributes */
00043 #define IB_SMP_ATTR_NOTICE                      0x0002
00044 #define IB_SMP_ATTR_NODE_DESC                   0x0010
00045 #define IB_SMP_ATTR_NODE_INFO                   0x0011
00046 #define IB_SMP_ATTR_SWITCH_INFO                 0x0012
00047 #define IB_SMP_ATTR_GUID_INFO                   0x0014
00048 #define IB_SMP_ATTR_PORT_INFO                   0x0015
00049 #define IB_SMP_ATTR_PKEY_TABLE                  0x0016
00050 #define IB_SMP_ATTR_SL_TO_VL_TABLE              0x0017
00051 #define IB_SMP_ATTR_VL_ARB_TABLE                0x0018
00052 #define IB_SMP_ATTR_LINEAR_FORWARD_TABLE        0x0019
00053 #define IB_SMP_ATTR_RANDOM_FORWARD_TABLE        0x001A
00054 #define IB_SMP_ATTR_MCAST_FORWARD_TABLE         0x001B
00055 #define IB_SMP_ATTR_SM_INFO                     0x0020
00056 #define IB_SMP_ATTR_VENDOR_DIAG                 0x0030
00057 #define IB_SMP_ATTR_LED_INFO                    0x0031
00058 #define IB_SMP_ATTR_VENDOR_MASK                 0xFF00
00059 
00060 /**
00061  * A Node Description attribute
00062  *
00063  * Defined in section 14.2.5.2 of the IBA
00064  */
00065 struct ib_node_desc {
00066         char node_string[64];
00067 } __attribute__ (( packed ));
00068 
00069 /** A Node Information attribute
00070  *
00071  * Defined in section 14.2.5.3 of the IBA.
00072  */
00073 struct ib_node_info {
00074         uint8_t base_version;
00075         uint8_t class_version;
00076         uint8_t node_type;
00077         uint8_t num_ports;
00078         union ib_guid sys_guid;
00079         union ib_guid node_guid;
00080         union ib_guid port_guid;
00081         uint16_t partition_cap;
00082         uint16_t device_id;
00083         uint32_t revision;
00084         uint8_t local_port_num;
00085         uint8_t vendor_id[3];
00086 } __attribute__ ((packed));
00087 
00088 #define IB_NODE_TYPE_HCA                0x01
00089 #define IB_NODE_TYPE_SWITCH             0x02
00090 #define IB_NODE_TYPE_ROUTER             0x03
00091 
00092 /** A GUID Information attribute
00093  *
00094  * Defined in section 14.2.5.5 of the IBA.
00095  */
00096 struct ib_guid_info {
00097         uint8_t guid[8][8];
00098 } __attribute__ (( packed ));
00099 
00100 /** A Port Information attribute
00101  *
00102  * Defined in section 14.2.5.6 of the IBA.
00103  */
00104 struct ib_port_info {
00105         uint64_t mkey;
00106         uint8_t gid_prefix[8];
00107         uint16_t lid;
00108         uint16_t mastersm_lid;
00109         uint32_t cap_mask;
00110         uint16_t diag_code;
00111         uint16_t mkey_lease_period;
00112         uint8_t local_port_num;
00113         uint8_t link_width_enabled;
00114         uint8_t link_width_supported;
00115         uint8_t link_width_active;
00116         uint8_t link_speed_supported__port_state;
00117         uint8_t port_phys_state__link_down_def_state;
00118         uint8_t mkey_prot_bits__lmc;
00119         uint8_t link_speed_active__link_speed_enabled;
00120         uint8_t neighbour_mtu__mastersm_sl;
00121         uint8_t vl_cap__init_type;
00122         uint8_t vl_high_limit;
00123         uint8_t vl_arbitration_high_cap;
00124         uint8_t vl_arbitration_low_cap;
00125         uint8_t init_type_reply__mtu_cap;
00126         uint8_t vl_stall_count__hoq_life;
00127         uint8_t operational_vls__enforcement;
00128         uint16_t mkey_violations;
00129         uint16_t pkey_violations;
00130         uint16_t qkey_violations;
00131         uint8_t guid_cap;
00132         uint8_t client_reregister__subnet_timeout;
00133         uint8_t resp_time_value;
00134         uint8_t local_phy_errors__overrun_errors;
00135         uint16_t max_credit_hint;
00136         uint32_t link_round_trip_latency;
00137 } __attribute__ (( packed ));
00138 
00139 #define IB_LINK_WIDTH_1X                0x01
00140 #define IB_LINK_WIDTH_4X                0x02
00141 #define IB_LINK_WIDTH_8X                0x04
00142 #define IB_LINK_WIDTH_12X               0x08
00143 
00144 #define IB_LINK_SPEED_SDR               0x01
00145 #define IB_LINK_SPEED_DDR               0x02
00146 #define IB_LINK_SPEED_QDR               0x04
00147 #define IB_LINK_SPEED_FDR10             0x08
00148 #define IB_LINK_SPEED_FDR               0x10
00149 #define IB_LINK_SPEED_EDR               0x20
00150 
00151 #define IB_PORT_STATE_DOWN              0x01
00152 #define IB_PORT_STATE_INIT              0x02
00153 #define IB_PORT_STATE_ARMED             0x03
00154 #define IB_PORT_STATE_ACTIVE            0x04
00155 
00156 #define IB_PORT_PHYS_STATE_SLEEP        0x01
00157 #define IB_PORT_PHYS_STATE_POLLING      0x02
00158 
00159 #define IB_MTU_256                      0x01
00160 #define IB_MTU_512                      0x02
00161 #define IB_MTU_1024                     0x03
00162 #define IB_MTU_2048                     0x04
00163 #define IB_MTU_4096                     0x05
00164 
00165 #define IB_VL_0                         0x01
00166 #define IB_VL_0_1                       0x02
00167 #define IB_VL_0_3                       0x03
00168 #define IB_VL_0_7                       0x04
00169 #define IB_VL_0_14                      0x05
00170 
00171 /** A Partition Key Table attribute
00172  *
00173  * Defined in section 14.2.5.7 of the IBA.
00174  */
00175 struct ib_pkey_table {
00176         uint16_t pkey[32];
00177 } __attribute__ (( packed ));
00178 
00179 /** A subnet management attribute */
00180 union ib_smp_data {
00181         struct ib_node_desc node_desc;
00182         struct ib_node_info node_info;
00183         struct ib_guid_info guid_info;
00184         struct ib_port_info port_info;
00185         struct ib_pkey_table pkey_table;
00186         uint8_t bytes[64];
00187 } __attribute__ (( packed ));
00188 
00189 /** A subnet management directed route path */
00190 struct ib_smp_dr_path {
00191         uint8_t hops[64];
00192 } __attribute__ (( packed ));
00193 
00194 /** Subnet management MAD class-specific data */
00195 struct ib_smp_class_specific {
00196         uint8_t hop_pointer;
00197         uint8_t hop_count;
00198 } __attribute__ (( packed ));
00199 
00200 /*****************************************************************************
00201  *
00202  * Subnet administration MADs
00203  *
00204  *****************************************************************************
00205  */
00206 
00207 #define IB_SA_CLASS_VERSION                     2
00208 
00209 #define IB_SA_METHOD_DELETE_RESP                0x95
00210 
00211 struct ib_rmpp_hdr {
00212         uint32_t raw[3];
00213 } __attribute__ (( packed ));
00214 
00215 struct ib_sa_hdr {
00216         uint32_t sm_key[2];
00217         uint16_t reserved;
00218         uint16_t attrib_offset;
00219         uint32_t comp_mask[2];
00220 } __attribute__ (( packed ));
00221 
00222 #define IB_SA_ATTR_SERVICE_REC                  0x31
00223 #define IB_SA_ATTR_PATH_REC                     0x35
00224 #define IB_SA_ATTR_MC_MEMBER_REC                0x38
00225 
00226 struct ib_service_record {
00227         uint64_t id;
00228         union ib_gid gid;
00229         uint16_t pkey;
00230         uint16_t reserved;
00231         uint32_t lease;
00232         uint8_t key[16];
00233         char name[64];
00234         uint8_t data8[16];
00235         uint16_t data16[8];
00236         uint32_t data32[4];
00237         uint64_t data64[2];
00238 } __attribute__ (( packed ));
00239 
00240 #define IB_SA_SERVICE_REC_NAME                  (1<<6)
00241 
00242 struct ib_path_record {
00243         uint32_t reserved0[2];
00244         union ib_gid dgid;
00245         union ib_gid sgid;
00246         uint16_t dlid;
00247         uint16_t slid;
00248         uint32_t hop_limit__flow_label__raw_traffic;
00249         uint32_t pkey__numb_path__reversible__tclass;
00250         uint8_t reserved1;
00251         uint8_t reserved__sl;
00252         uint8_t mtu_selector__mtu;
00253         uint8_t rate_selector__rate;
00254         uint32_t preference__packet_lifetime__packet_lifetime_selector;
00255         uint32_t reserved2[35];
00256 } __attribute__ (( packed ));
00257 
00258 #define IB_SA_PATH_REC_DGID                     (1<<2)
00259 #define IB_SA_PATH_REC_SGID                     (1<<3)
00260 
00261 struct ib_mc_member_record {
00262         union ib_gid mgid;
00263         union ib_gid port_gid;
00264         uint32_t qkey;
00265         uint16_t mlid;
00266         uint8_t mtu_selector__mtu;
00267         uint8_t tclass;
00268         uint16_t pkey;
00269         uint8_t rate_selector__rate;
00270         uint8_t packet_lifetime_selector__packet_lifetime;
00271         uint32_t sl__flow_label__hop_limit;
00272         uint8_t scope__join_state;
00273         uint8_t proxy_join__reserved;
00274         uint16_t reserved0;
00275         uint32_t reserved1[37];
00276 } __attribute__ (( packed ));
00277 
00278 #define IB_SA_MCMEMBER_REC_MGID                 (1<<0)
00279 #define IB_SA_MCMEMBER_REC_PORT_GID             (1<<1)
00280 #define IB_SA_MCMEMBER_REC_QKEY                 (1<<2)
00281 #define IB_SA_MCMEMBER_REC_MLID                 (1<<3)
00282 #define IB_SA_MCMEMBER_REC_MTU_SELECTOR         (1<<4)
00283 #define IB_SA_MCMEMBER_REC_MTU                  (1<<5)
00284 #define IB_SA_MCMEMBER_REC_TRAFFIC_CLASS        (1<<6)
00285 #define IB_SA_MCMEMBER_REC_PKEY                 (1<<7)
00286 #define IB_SA_MCMEMBER_REC_RATE_SELECTOR        (1<<8)
00287 #define IB_SA_MCMEMBER_REC_RATE                 (1<<9)
00288 #define IB_SA_MCMEMBER_REC_PACKET_LIFE_TIME_SELECTOR    (1<<10)
00289 #define IB_SA_MCMEMBER_REC_PACKET_LIFE_TIME     (1<<11)
00290 #define IB_SA_MCMEMBER_REC_SL                   (1<<12)
00291 #define IB_SA_MCMEMBER_REC_FLOW_LABEL           (1<<13)
00292 #define IB_SA_MCMEMBER_REC_HOP_LIMIT            (1<<14)
00293 #define IB_SA_MCMEMBER_REC_SCOPE                (1<<15)
00294 #define IB_SA_MCMEMBER_REC_JOIN_STATE           (1<<16)
00295 #define IB_SA_MCMEMBER_REC_PROXY_JOIN           (1<<17)
00296 
00297 union ib_sa_data {
00298         struct ib_service_record service_record;
00299         struct ib_path_record path_record;
00300         struct ib_mc_member_record mc_member_record;
00301 } __attribute__ (( packed ));
00302 
00303 /*****************************************************************************
00304  *
00305  * Communication management MADs
00306  *
00307  *****************************************************************************
00308  */
00309 
00310 /** Communication management class version */
00311 #define IB_CM_CLASS_VERSION                     2
00312 
00313 /* Communication management attributes */
00314 #define IB_CM_ATTR_CLASS_PORT_INFO              0x0001
00315 #define IB_CM_ATTR_CONNECT_REQUEST              0x0010
00316 #define IB_CM_ATTR_MSG_RCPT_ACK                 0x0011
00317 #define IB_CM_ATTR_CONNECT_REJECT               0x0012
00318 #define IB_CM_ATTR_CONNECT_REPLY                0x0013
00319 #define IB_CM_ATTR_READY_TO_USE                 0x0014
00320 #define IB_CM_ATTR_DISCONNECT_REQUEST           0x0015
00321 #define IB_CM_ATTR_DISCONNECT_REPLY             0x0016
00322 #define IB_CM_ATTR_SERVICE_ID_RES_REQ           0x0016
00323 #define IB_CM_ATTR_SERVICE_ID_RES_REQ_RESP      0x0018
00324 #define IB_CM_ATTR_LOAD_ALTERNATE_PATH          0x0019
00325 #define IB_CM_ATTR_ALTERNATE_PATH_RESPONSE      0x001a
00326 
00327 /** Communication management common fields */
00328 struct ib_cm_common {
00329         /** Local communication ID */
00330         uint32_t local_id;
00331         /** Remote communication ID */
00332         uint32_t remote_id;
00333         /** Reserved */
00334         uint8_t reserved[224];
00335 } __attribute__ (( packed ));
00336 
00337 /** A communication management path */
00338 struct ib_cm_path {
00339         /** Local port LID */
00340         uint16_t local_lid;
00341         /** Remote port LID */
00342         uint16_t remote_lid;
00343         /** Local port GID */
00344         union ib_gid local_gid;
00345         /** Remote port GID */
00346         union ib_gid remote_gid;
00347         /** Flow label and rate */
00348         uint32_t flow_label__rate;
00349         /** Traffic class */
00350         uint8_t tc;
00351         /** Hop limit */
00352         uint8_t hop_limit;
00353         /** SL and subnet local*/
00354         uint8_t sl__subnet_local;
00355         /** Local ACK timeout */
00356         uint8_t local_ack_timeout;
00357 } __attribute__ (( packed ));
00358 
00359 /** A communication management connection request
00360  *
00361  * Defined in section 12.6.5 of the IBA.
00362  */
00363 struct ib_cm_connect_request {
00364         /** Local communication ID */
00365         uint32_t local_id;
00366         /** Reserved */
00367         uint32_t reserved0[1];
00368         /** Service ID */
00369         union ib_guid service_id;
00370         /** Local CA GUID */
00371         union ib_guid local_ca;
00372         /** Reserved */
00373         uint32_t reserved1[1];
00374         /** Local queue key */
00375         uint32_t local_qkey;
00376         /** Local QPN and responder resources*/
00377         uint32_t local_qpn__responder_resources;
00378         /** Local EECN and initiator depth */
00379         uint32_t local_eecn__initiator_depth;
00380         /** Remote EECN, remote CM response timeout, transport service
00381          * type, EE flow control
00382          */
00383         uint32_t remote_eecn__remote_timeout__service_type__ee_flow_ctrl;
00384         /** Starting PSN, local CM response timeout and retry count */
00385         uint32_t starting_psn__local_timeout__retry_count;
00386         /** Partition key */
00387         uint16_t pkey;
00388         /** Path packet payload MTU, RDC exists, RNR retry count */
00389         uint8_t payload_mtu__rdc_exists__rnr_retry;
00390         /** Max CM retries and SRQ */
00391         uint8_t max_cm_retries__srq;
00392         /** Primary path */
00393         struct ib_cm_path primary;
00394         /** Alternate path */
00395         struct ib_cm_path alternate;
00396         /** Private data */
00397         uint8_t private_data[92];
00398 } __attribute__ (( packed ));
00399 
00400 /** CM transport types */
00401 #define IB_CM_TRANSPORT_RC              0
00402 #define IB_CM_TRANSPORT_UC              1
00403 #define IB_CM_TRANSPORT_RD              2
00404 
00405 /** A communication management connection rejection
00406  *
00407  * Defined in section 12.6.7 of the IBA.
00408  */
00409 struct ib_cm_connect_reject {
00410         /** Local communication ID */
00411         uint32_t local_id;
00412         /** Remote communication ID */
00413         uint32_t remote_id;
00414         /** Message rejected */
00415         uint8_t message;
00416         /** Reject information length */
00417         uint8_t info_len;
00418         /** Rejection reason */
00419         uint16_t reason;
00420         /** Additional rejection information */
00421         uint8_t info[72];
00422         /** Private data */
00423         uint8_t private_data[148];
00424 } __attribute__ (( packed ));
00425 
00426 /** CM rejection reasons */
00427 #define IB_CM_REJECT_BAD_SERVICE_ID     8
00428 #define IB_CM_REJECT_STALE_CONN         10
00429 #define IB_CM_REJECT_CONSUMER           28
00430 
00431 /** A communication management connection reply
00432  *
00433  * Defined in section 12.6.8 of the IBA.
00434  */
00435 struct ib_cm_connect_reply {
00436         /** Local communication ID */
00437         uint32_t local_id;
00438         /** Remote communication ID */
00439         uint32_t remote_id;
00440         /** Local queue key */
00441         uint32_t local_qkey;
00442         /** Local QPN */
00443         uint32_t local_qpn;
00444         /** Local EECN */
00445         uint32_t local_eecn;
00446         /** Starting PSN */
00447         uint32_t starting_psn;
00448         /** Responder resources */
00449         uint8_t responder_resources;
00450         /** Initiator depth */
00451         uint8_t initiator_depth;
00452         /** Target ACK delay, failover accepted, and end-to-end flow control */
00453         uint8_t target_ack_delay__failover_accepted__ee_flow_ctrl;
00454         /** RNR retry count, SRQ */
00455         uint8_t rnr_retry__srq;
00456         /** Local CA GUID */
00457         union ib_guid local_ca;
00458         /** Private data */
00459         uint8_t private_data[196];
00460 } __attribute__ (( packed ));
00461 
00462 /** A communication management ready to use reply
00463  *
00464  * Defined in section 12.6.9 of the IBA.
00465  */
00466 struct ib_cm_ready_to_use {
00467         /** Local communication ID */
00468         uint32_t local_id;
00469         /** Remote communication ID */
00470         uint32_t remote_id;
00471         /** Private data */
00472         uint8_t private_data[224];
00473 } __attribute__ (( packed ));
00474 
00475 /** A communication management disconnection request
00476  *
00477  * Defined in section 12.6.10 of the IBA.
00478  */
00479 struct ib_cm_disconnect_request {
00480         /** Local communication ID */
00481         uint32_t local_id;
00482         /** Remote communication ID */
00483         uint32_t remote_id;
00484         /** Remote QPN/EECN */
00485         uint32_t remote_qpn_eecn;
00486         /** Private data */
00487         uint8_t private_data[220];
00488 } __attribute__ (( packed ));
00489 
00490 /** A communication management disconnection reply
00491  *
00492  * Defined in section 12.6.11 of the IBA.
00493  */
00494 struct ib_cm_disconnect_reply {
00495         /** Local communication ID */
00496         uint32_t local_id;
00497         /** Remote communication ID */
00498         uint32_t remote_id;
00499         /** Private data */
00500         uint8_t private_data[224];
00501 } __attribute__ (( packed ));
00502 
00503 /** A communication management attribute */
00504 union ib_cm_data {
00505         struct ib_cm_common common;
00506         struct ib_cm_connect_request connect_request;
00507         struct ib_cm_connect_reject connect_reject;
00508         struct ib_cm_connect_reply connect_reply;
00509         struct ib_cm_ready_to_use ready_to_use;
00510         struct ib_cm_disconnect_request disconnect_request;
00511         struct ib_cm_disconnect_reply disconnect_reply;
00512         uint8_t bytes[232];
00513 } __attribute__ (( packed ));
00514 
00515 /*****************************************************************************
00516  *
00517  * MADs
00518  *
00519  *****************************************************************************
00520  */
00521 
00522 /** Management datagram class_specific data */
00523 union ib_mad_class_specific {
00524         uint16_t raw;
00525         struct ib_smp_class_specific smp;
00526 } __attribute__ (( packed ));
00527 
00528 /** A management datagram transaction identifier */
00529 struct ib_mad_tid {
00530         uint32_t high;
00531         uint32_t low;
00532 } __attribute__ (( packed ));
00533 
00534 /** A management datagram common header
00535  *
00536  * Defined in section 13.4.2 of the IBA.
00537  */
00538 struct ib_mad_hdr {
00539         uint8_t base_version;
00540         uint8_t mgmt_class;
00541         uint8_t class_version;
00542         uint8_t method;
00543         uint16_t status;
00544         union ib_mad_class_specific class_specific;
00545         struct ib_mad_tid tid;
00546         uint16_t attr_id;
00547         uint8_t reserved[2];
00548         uint32_t attr_mod;
00549 } __attribute__ (( packed ));
00550 
00551 /* Management base version */
00552 #define IB_MGMT_BASE_VERSION                    1
00553 
00554 /* Management classes */
00555 #define IB_MGMT_CLASS_SUBN_LID_ROUTED           0x01
00556 #define IB_MGMT_CLASS_SUBN_DIRECTED_ROUTE       0x81
00557 #define IB_MGMT_CLASS_SUBN_ADM                  0x03
00558 #define IB_MGMT_CLASS_PERF_MGMT                 0x04
00559 #define IB_MGMT_CLASS_BM                        0x05
00560 #define IB_MGMT_CLASS_DEVICE_MGMT               0x06
00561 #define IB_MGMT_CLASS_CM                        0x07
00562 #define IB_MGMT_CLASS_SNMP                      0x08
00563 #define IB_MGMT_CLASS_VENDOR_RANGE2_START       0x30
00564 #define IB_MGMT_CLASS_VENDOR_RANGE2_END         0x4f
00565 
00566 #define IB_MGMT_CLASS_MASK                      0x7f
00567 
00568 /* Management methods */
00569 #define IB_MGMT_METHOD_GET                      0x01
00570 #define IB_MGMT_METHOD_SET                      0x02
00571 #define IB_MGMT_METHOD_GET_RESP                 0x81
00572 #define IB_MGMT_METHOD_SEND                     0x03
00573 #define IB_MGMT_METHOD_TRAP                     0x05
00574 #define IB_MGMT_METHOD_REPORT                   0x06
00575 #define IB_MGMT_METHOD_REPORT_RESP              0x86
00576 #define IB_MGMT_METHOD_TRAP_REPRESS             0x07
00577 #define IB_MGMT_METHOD_DELETE                   0x15
00578 
00579 /* Status codes */
00580 #define IB_MGMT_STATUS_OK                       0x0000
00581 #define IB_MGMT_STATUS_BAD_VERSION              0x0001
00582 #define IB_MGMT_STATUS_UNSUPPORTED_METHOD       0x0002
00583 #define IB_MGMT_STATUS_UNSUPPORTED_METHOD_ATTR  0x0003
00584 #define IB_MGMT_STATUS_INVALID_VALUE            0x0004
00585 
00586 /** A subnet management MAD */
00587 struct ib_mad_smp {
00588         struct ib_mad_hdr mad_hdr;
00589         struct ib_smp_hdr smp_hdr;
00590         union ib_smp_data smp_data;
00591         struct ib_smp_dr_path initial_path;
00592         struct ib_smp_dr_path return_path;
00593 } __attribute__ (( packed ));
00594 
00595 /** A subnet administration MAD */
00596 struct ib_mad_sa {
00597         struct ib_mad_hdr mad_hdr;
00598         struct ib_rmpp_hdr rmpp_hdr;
00599         struct ib_sa_hdr sa_hdr;
00600         union ib_sa_data sa_data;
00601 } __attribute__ (( packed ));
00602 
00603 /** A communication management MAD */
00604 struct ib_mad_cm {
00605         struct ib_mad_hdr mad_hdr;
00606         union ib_cm_data cm_data;
00607 } __attribute__ (( packed ));
00608 
00609 /** A management datagram */
00610 union ib_mad {
00611         struct ib_mad_hdr hdr;
00612         struct ib_mad_smp smp;
00613         struct ib_mad_sa sa;
00614         struct ib_mad_cm cm;
00615         uint8_t bytes[256];
00616 } __attribute__ (( packed ));
00617 
00618 #endif /* _IPXE_IB_MAD_H */