aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorSean Hefty <sean.hefty@intel.com>2013-05-29 13:09:25 -0400
committerRoland Dreier <roland@purestorage.com>2013-06-21 02:35:39 -0400
commitee7aed4528fb3c44a36abd79eb23fd5401a5b697 (patch)
tree16e084d5abbf42b117b8a4b4cb24dcb6d5bd281e /include
parent94d0c939416480066d4e4d69e0d3c217bc083cea (diff)
RDMA/ucma: Support querying for AF_IB addresses
The sockaddr structure for AF_IB is larger than sockaddr_in6. The rdma cm user space ABI uses the latter to exchange address information between user space and the kernel. To support querying for larger addresses, define a new query command that exchanges data using sockaddr_storage, rather than sockaddr_in6. Unlike the existing query_route command, the new command only returns address information. Route (i.e. path record) data is separated. Signed-off-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'include')
-rw-r--r--include/uapi/rdma/rdma_user_cm.h22
1 files changed, 19 insertions, 3 deletions
diff --git a/include/uapi/rdma/rdma_user_cm.h b/include/uapi/rdma/rdma_user_cm.h
index 29de08f603ac..3ea7e7a4d54b 100644
--- a/include/uapi/rdma/rdma_user_cm.h
+++ b/include/uapi/rdma/rdma_user_cm.h
@@ -61,7 +61,8 @@ enum {
61 RDMA_USER_CM_CMD_NOTIFY, 61 RDMA_USER_CM_CMD_NOTIFY,
62 RDMA_USER_CM_CMD_JOIN_MCAST, 62 RDMA_USER_CM_CMD_JOIN_MCAST,
63 RDMA_USER_CM_CMD_LEAVE_MCAST, 63 RDMA_USER_CM_CMD_LEAVE_MCAST,
64 RDMA_USER_CM_CMD_MIGRATE_ID 64 RDMA_USER_CM_CMD_MIGRATE_ID,
65 RDMA_USER_CM_CMD_QUERY
65}; 66};
66 67
67/* 68/*
@@ -113,10 +114,14 @@ struct rdma_ucm_resolve_route {
113 __u32 timeout_ms; 114 __u32 timeout_ms;
114}; 115};
115 116
116struct rdma_ucm_query_route { 117enum {
118 RDMA_USER_CM_QUERY_ADDR
119};
120
121struct rdma_ucm_query {
117 __u64 response; 122 __u64 response;
118 __u32 id; 123 __u32 id;
119 __u32 reserved; 124 __u32 option;
120}; 125};
121 126
122struct rdma_ucm_query_route_resp { 127struct rdma_ucm_query_route_resp {
@@ -129,6 +134,17 @@ struct rdma_ucm_query_route_resp {
129 __u8 reserved[3]; 134 __u8 reserved[3];
130}; 135};
131 136
137struct rdma_ucm_query_addr_resp {
138 __u64 node_guid;
139 __u8 port_num;
140 __u8 reserved;
141 __u16 pkey;
142 __u16 src_size;
143 __u16 dst_size;
144 struct sockaddr_storage src_addr;
145 struct sockaddr_storage dst_addr;
146};
147
132struct rdma_ucm_conn_param { 148struct rdma_ucm_conn_param {
133 __u32 qp_num; 149 __u32 qp_num;
134 __u32 qkey; 150 __u32 qkey;