iPXE
ib_cm.h
Go to the documentation of this file.
1 #ifndef _IPXE_IB_CM_H
2 #define _IPXE_IB_CM_H
3 
4 /** @file
5  *
6  * Infiniband communication management
7  *
8  */
9 
10 FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
11 
12 #include <ipxe/infiniband.h>
13 #include <ipxe/retry.h>
14 
15 struct ib_mad_transaction;
16 struct ib_connection;
17 
18 /** Infiniband connection operations */
20  /** Handle change of connection status
21  *
22  * @v ibdev Infiniband device
23  * @v qp Queue pair
24  * @v conn Connection
25  * @v rc Connection status code
26  * @v private_data Private data, if available
27  * @v private_data_len Length of private data
28  */
29  void ( * changed ) ( struct ib_device *ibdev, struct ib_queue_pair *qp,
30  struct ib_connection *conn, int rc,
31  void *private_data, size_t private_data_len );
32 };
33 
34 /** An Infiniband connection */
35 struct ib_connection {
36  /** Infiniband device */
37  struct ib_device *ibdev;
38  /** Queue pair */
39  struct ib_queue_pair *qp;
40  /** Local communication ID */
42  /** Remote communication ID */
44  /** Target service ID */
46  /** Connection operations */
48 
49  /** List of connections */
50  struct list_head list;
51 
52  /** Path to target */
53  struct ib_path *path;
54  /** Connection request management transaction */
56 
57  /** Length of connection request private data */
59  /** Connection request private data */
61 };
62 
63 extern struct ib_connection *
64 ib_create_conn ( struct ib_device *ibdev, struct ib_queue_pair *qp,
65  union ib_gid *dgid, union ib_guid *service_id,
66  void *req_private_data, size_t req_private_data_len,
67  struct ib_connection_operations *op );
68 extern void ib_destroy_conn ( struct ib_device *ibdev,
69  struct ib_queue_pair *qp,
70  struct ib_connection *conn );
71 
72 #endif /* _IPXE_IB_CM_H */
struct arbelprm_rc_send_wqe rc
Definition: arbel.h:14
Infiniband protocol.
An Infiniband path.
Definition: ib_pathrec.h:32
FILE_LICENCE(GPL2_OR_LATER_OR_UBDL)
struct list_head list
List of connections.
Definition: ib_cm.h:50
Infiniband connection operations.
Definition: ib_cm.h:19
Retry timers.
uint8_t private_data[0]
Connection request private data.
Definition: ib_cm.h:60
size_t private_data_len
Length of connection request private data.
Definition: ib_cm.h:58
uint32_t remote_id
Remote communication ID.
Definition: ib_cm.h:43
An Infiniband Global Identifier.
Definition: ib_packet.h:33
union ib_guid service_id
Target service ID.
Definition: ib_cm.h:45
A doubly-linked list entry (or list head)
Definition: list.h:18
uint32_t local_id
Local communication ID.
Definition: ib_cm.h:41
An Infiniband device.
Definition: infiniband.h:398
void(* changed)(struct ib_device *ibdev, struct ib_queue_pair *qp, struct ib_connection *conn, int rc, void *private_data, size_t private_data_len)
Handle change of connection status.
Definition: ib_cm.h:29
void ib_destroy_conn(struct ib_device *ibdev, struct ib_queue_pair *qp, struct ib_connection *conn)
An Infiniband management transaction.
Definition: ib_mi.h:70
struct ib_connection * ib_create_conn(struct ib_device *ibdev, struct ib_queue_pair *qp, union ib_gid *dgid, union ib_guid *service_id, void *req_private_data, size_t req_private_data_len, struct ib_connection_operations *op)
Create connection to remote QP.
Definition: ib_cm.c:451
struct ib_connection_operations * op
Connection operations.
Definition: ib_cm.h:47
An Infiniband Globally Unique Identifier.
Definition: ib_packet.h:18
unsigned char uint8_t
Definition: stdint.h:10
unsigned int uint32_t
Definition: stdint.h:12
An Infiniband connection.
Definition: ib_cm.h:35
struct ib_path * path
Path to target.
Definition: ib_cm.h:53
An Infiniband Queue Pair.
Definition: infiniband.h:157
union ib_gid dgid
Definition: ib_mad.h:12
struct arbelprm_qp_db_record qp
Definition: arbel.h:13
static uint16_t struct vmbus_xfer_pages_operations * op
Definition: netvsc.h:327
struct ib_queue_pair * qp
Queue pair.
Definition: ib_cm.h:39
uint8_t private_data[92]
Private data.
Definition: ib_mad.h:44
struct ib_device * ibdev
Infiniband device.
Definition: ib_cm.h:37
struct ib_mad_transaction * madx
Connection request management transaction.
Definition: ib_cm.h:55
union ib_guid service_id
Service ID.
Definition: ib_mad.h:16