diff options
author | Dasaratharaman Chandramouli <dasaratharaman.chandramouli@intel.com> | 2017-04-27 19:05:58 -0400 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2017-05-01 14:37:28 -0400 |
commit | c2f8fc4ec4400901e5561d4815deca19f395deb6 (patch) | |
tree | d23a16ce4b125ec09faed4c6d1ba2ef36b3d2d2c | |
parent | 82ffc226483cad8780c25c754da5d0013c88ff8c (diff) |
IB/SA: Rename ib_sa_path_rec to sa_path_rec
Rename ib_sa_path_rec to a more generic sa_path_rec.
This is part of extending ib_sa to also support OPA
path records in addition to the IB defined path records.
Reviewed-by: Don Hiatt <don.hiatt@intel.com>
Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Dasaratharaman Chandramouli <dasaratharaman.chandramouli@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
-rw-r--r-- | drivers/infiniband/core/cm.c | 20 | ||||
-rw-r--r-- | drivers/infiniband/core/cma.c | 8 | ||||
-rw-r--r-- | drivers/infiniband/core/sa_query.c | 20 | ||||
-rw-r--r-- | drivers/infiniband/core/ucm.c | 6 | ||||
-rw-r--r-- | drivers/infiniband/core/ucma.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/core/uverbs_marshall.c | 4 | ||||
-rw-r--r-- | drivers/infiniband/ulp/ipoib/ipoib.h | 2 | ||||
-rw-r--r-- | drivers/infiniband/ulp/ipoib/ipoib_cm.c | 6 | ||||
-rw-r--r-- | drivers/infiniband/ulp/ipoib/ipoib_main.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/ulp/srp/ib_srp.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/ulp/srp/ib_srp.h | 2 | ||||
-rw-r--r-- | include/rdma/ib_cm.h | 14 | ||||
-rw-r--r-- | include/rdma/ib_marshall.h | 4 | ||||
-rw-r--r-- | include/rdma/ib_sa.h | 14 | ||||
-rw-r--r-- | include/rdma/rdma_cm.h | 2 | ||||
-rw-r--r-- | include/rdma/rdma_cm_ib.h | 2 |
16 files changed, 55 insertions, 55 deletions
diff --git a/drivers/infiniband/core/cm.c b/drivers/infiniband/core/cm.c index 53661f34a326..fe838234cf94 100644 --- a/drivers/infiniband/core/cm.c +++ b/drivers/infiniband/core/cm.c | |||
@@ -241,7 +241,7 @@ struct cm_work { | |||
241 | __be32 local_id; /* Established / timewait */ | 241 | __be32 local_id; /* Established / timewait */ |
242 | __be32 remote_id; | 242 | __be32 remote_id; |
243 | struct ib_cm_event cm_event; | 243 | struct ib_cm_event cm_event; |
244 | struct ib_sa_path_rec path[0]; | 244 | struct sa_path_rec path[0]; |
245 | }; | 245 | }; |
246 | 246 | ||
247 | struct cm_timewait_info { | 247 | struct cm_timewait_info { |
@@ -440,7 +440,7 @@ static void cm_init_av_for_response(struct cm_port *port, struct ib_wc *wc, | |||
440 | grh, &av->ah_attr); | 440 | grh, &av->ah_attr); |
441 | } | 441 | } |
442 | 442 | ||
443 | static int cm_init_av_by_path(struct ib_sa_path_rec *path, struct cm_av *av, | 443 | static int cm_init_av_by_path(struct sa_path_rec *path, struct cm_av *av, |
444 | struct cm_id_private *cm_id_priv) | 444 | struct cm_id_private *cm_id_priv) |
445 | { | 445 | { |
446 | struct cm_device *cm_dev; | 446 | struct cm_device *cm_dev; |
@@ -1172,8 +1172,8 @@ static void cm_format_req(struct cm_req_msg *req_msg, | |||
1172 | struct cm_id_private *cm_id_priv, | 1172 | struct cm_id_private *cm_id_priv, |
1173 | struct ib_cm_req_param *param) | 1173 | struct ib_cm_req_param *param) |
1174 | { | 1174 | { |
1175 | struct ib_sa_path_rec *pri_path = param->primary_path; | 1175 | struct sa_path_rec *pri_path = param->primary_path; |
1176 | struct ib_sa_path_rec *alt_path = param->alternate_path; | 1176 | struct sa_path_rec *alt_path = param->alternate_path; |
1177 | 1177 | ||
1178 | cm_format_mad_hdr(&req_msg->hdr, CM_REQ_ATTR_ID, | 1178 | cm_format_mad_hdr(&req_msg->hdr, CM_REQ_ATTR_ID, |
1179 | cm_form_tid(cm_id_priv, CM_MSG_SEQUENCE_REQ)); | 1179 | cm_form_tid(cm_id_priv, CM_MSG_SEQUENCE_REQ)); |
@@ -1401,8 +1401,8 @@ static inline int cm_is_active_peer(__be64 local_ca_guid, __be64 remote_ca_guid, | |||
1401 | } | 1401 | } |
1402 | 1402 | ||
1403 | static void cm_format_paths_from_req(struct cm_req_msg *req_msg, | 1403 | static void cm_format_paths_from_req(struct cm_req_msg *req_msg, |
1404 | struct ib_sa_path_rec *primary_path, | 1404 | struct sa_path_rec *primary_path, |
1405 | struct ib_sa_path_rec *alt_path) | 1405 | struct sa_path_rec *alt_path) |
1406 | { | 1406 | { |
1407 | memset(primary_path, 0, sizeof(*primary_path)); | 1407 | memset(primary_path, 0, sizeof(*primary_path)); |
1408 | primary_path->dgid = req_msg->primary_local_gid; | 1408 | primary_path->dgid = req_msg->primary_local_gid; |
@@ -2815,7 +2815,7 @@ out: | |||
2815 | 2815 | ||
2816 | static void cm_format_lap(struct cm_lap_msg *lap_msg, | 2816 | static void cm_format_lap(struct cm_lap_msg *lap_msg, |
2817 | struct cm_id_private *cm_id_priv, | 2817 | struct cm_id_private *cm_id_priv, |
2818 | struct ib_sa_path_rec *alternate_path, | 2818 | struct sa_path_rec *alternate_path, |
2819 | const void *private_data, | 2819 | const void *private_data, |
2820 | u8 private_data_len) | 2820 | u8 private_data_len) |
2821 | { | 2821 | { |
@@ -2845,7 +2845,7 @@ static void cm_format_lap(struct cm_lap_msg *lap_msg, | |||
2845 | } | 2845 | } |
2846 | 2846 | ||
2847 | int ib_send_cm_lap(struct ib_cm_id *cm_id, | 2847 | int ib_send_cm_lap(struct ib_cm_id *cm_id, |
2848 | struct ib_sa_path_rec *alternate_path, | 2848 | struct sa_path_rec *alternate_path, |
2849 | const void *private_data, | 2849 | const void *private_data, |
2850 | u8 private_data_len) | 2850 | u8 private_data_len) |
2851 | { | 2851 | { |
@@ -2899,7 +2899,7 @@ out: spin_unlock_irqrestore(&cm_id_priv->lock, flags); | |||
2899 | EXPORT_SYMBOL(ib_send_cm_lap); | 2899 | EXPORT_SYMBOL(ib_send_cm_lap); |
2900 | 2900 | ||
2901 | static void cm_format_path_from_lap(struct cm_id_private *cm_id_priv, | 2901 | static void cm_format_path_from_lap(struct cm_id_private *cm_id_priv, |
2902 | struct ib_sa_path_rec *path, | 2902 | struct sa_path_rec *path, |
2903 | struct cm_lap_msg *lap_msg) | 2903 | struct cm_lap_msg *lap_msg) |
2904 | { | 2904 | { |
2905 | memset(path, 0, sizeof *path); | 2905 | memset(path, 0, sizeof *path); |
@@ -3712,7 +3712,7 @@ static void cm_recv_handler(struct ib_mad_agent *mad_agent, | |||
3712 | atomic_long_inc(&port->counter_group[CM_RECV]. | 3712 | atomic_long_inc(&port->counter_group[CM_RECV]. |
3713 | counter[attr_id - CM_ATTR_ID_OFFSET]); | 3713 | counter[attr_id - CM_ATTR_ID_OFFSET]); |
3714 | 3714 | ||
3715 | work = kmalloc(sizeof(*work) + sizeof(struct ib_sa_path_rec) * paths, | 3715 | work = kmalloc(sizeof(*work) + sizeof(struct sa_path_rec) * paths, |
3716 | GFP_KERNEL); | 3716 | GFP_KERNEL); |
3717 | if (!work) { | 3717 | if (!work) { |
3718 | ib_free_recv_mad(mad_recv_wc); | 3718 | ib_free_recv_mad(mad_recv_wc); |
diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c index f3b800f28556..3af318a71622 100644 --- a/drivers/infiniband/core/cma.c +++ b/drivers/infiniband/core/cma.c | |||
@@ -1128,7 +1128,7 @@ static inline int cma_any_port(struct sockaddr *addr) | |||
1128 | static void cma_save_ib_info(struct sockaddr *src_addr, | 1128 | static void cma_save_ib_info(struct sockaddr *src_addr, |
1129 | struct sockaddr *dst_addr, | 1129 | struct sockaddr *dst_addr, |
1130 | struct rdma_cm_id *listen_id, | 1130 | struct rdma_cm_id *listen_id, |
1131 | struct ib_sa_path_rec *path) | 1131 | struct sa_path_rec *path) |
1132 | { | 1132 | { |
1133 | struct sockaddr_ib *listen_ib, *ib; | 1133 | struct sockaddr_ib *listen_ib, *ib; |
1134 | 1134 | ||
@@ -2301,7 +2301,7 @@ void rdma_set_service_type(struct rdma_cm_id *id, int tos) | |||
2301 | } | 2301 | } |
2302 | EXPORT_SYMBOL(rdma_set_service_type); | 2302 | EXPORT_SYMBOL(rdma_set_service_type); |
2303 | 2303 | ||
2304 | static void cma_query_handler(int status, struct ib_sa_path_rec *path_rec, | 2304 | static void cma_query_handler(int status, struct sa_path_rec *path_rec, |
2305 | void *context) | 2305 | void *context) |
2306 | { | 2306 | { |
2307 | struct cma_work *work = context; | 2307 | struct cma_work *work = context; |
@@ -2328,7 +2328,7 @@ static int cma_query_ib_route(struct rdma_id_private *id_priv, int timeout_ms, | |||
2328 | struct cma_work *work) | 2328 | struct cma_work *work) |
2329 | { | 2329 | { |
2330 | struct rdma_dev_addr *dev_addr = &id_priv->id.route.addr.dev_addr; | 2330 | struct rdma_dev_addr *dev_addr = &id_priv->id.route.addr.dev_addr; |
2331 | struct ib_sa_path_rec path_rec; | 2331 | struct sa_path_rec path_rec; |
2332 | ib_sa_comp_mask comp_mask; | 2332 | ib_sa_comp_mask comp_mask; |
2333 | struct sockaddr_in6 *sin6; | 2333 | struct sockaddr_in6 *sin6; |
2334 | struct sockaddr_ib *sib; | 2334 | struct sockaddr_ib *sib; |
@@ -2453,7 +2453,7 @@ err1: | |||
2453 | } | 2453 | } |
2454 | 2454 | ||
2455 | int rdma_set_ib_paths(struct rdma_cm_id *id, | 2455 | int rdma_set_ib_paths(struct rdma_cm_id *id, |
2456 | struct ib_sa_path_rec *path_rec, int num_paths) | 2456 | struct sa_path_rec *path_rec, int num_paths) |
2457 | { | 2457 | { |
2458 | struct rdma_id_private *id_priv; | 2458 | struct rdma_id_private *id_priv; |
2459 | int ret; | 2459 | int ret; |
diff --git a/drivers/infiniband/core/sa_query.c b/drivers/infiniband/core/sa_query.c index 23ba90d55c63..ee82aab8f7d9 100644 --- a/drivers/infiniband/core/sa_query.c +++ b/drivers/infiniband/core/sa_query.c | |||
@@ -129,7 +129,7 @@ struct ib_sa_service_query { | |||
129 | }; | 129 | }; |
130 | 130 | ||
131 | struct ib_sa_path_query { | 131 | struct ib_sa_path_query { |
132 | void (*callback)(int, struct ib_sa_path_rec *, void *); | 132 | void (*callback)(int, struct sa_path_rec *, void *); |
133 | void *context; | 133 | void *context; |
134 | struct ib_sa_query sa_query; | 134 | struct ib_sa_query sa_query; |
135 | }; | 135 | }; |
@@ -188,8 +188,8 @@ static DEFINE_SPINLOCK(tid_lock); | |||
188 | static u32 tid; | 188 | static u32 tid; |
189 | 189 | ||
190 | #define PATH_REC_FIELD(field) \ | 190 | #define PATH_REC_FIELD(field) \ |
191 | .struct_offset_bytes = offsetof(struct ib_sa_path_rec, field), \ | 191 | .struct_offset_bytes = offsetof(struct sa_path_rec, field), \ |
192 | .struct_size_bytes = sizeof ((struct ib_sa_path_rec *) 0)->field, \ | 192 | .struct_size_bytes = sizeof((struct sa_path_rec *)0)->field, \ |
193 | .field_name = "sa_path_rec:" #field | 193 | .field_name = "sa_path_rec:" #field |
194 | 194 | ||
195 | static const struct ib_field path_rec_table[] = { | 195 | static const struct ib_field path_rec_table[] = { |
@@ -618,7 +618,7 @@ static inline int ib_sa_query_cancelled(struct ib_sa_query *query) | |||
618 | static void ib_nl_set_path_rec_attrs(struct sk_buff *skb, | 618 | static void ib_nl_set_path_rec_attrs(struct sk_buff *skb, |
619 | struct ib_sa_query *query) | 619 | struct ib_sa_query *query) |
620 | { | 620 | { |
621 | struct ib_sa_path_rec *sa_rec = query->mad_buf->context[1]; | 621 | struct sa_path_rec *sa_rec = query->mad_buf->context[1]; |
622 | struct ib_sa_mad *mad = query->mad_buf->mad; | 622 | struct ib_sa_mad *mad = query->mad_buf->mad; |
623 | ib_sa_comp_mask comp_mask = mad->sa_hdr.comp_mask; | 623 | ib_sa_comp_mask comp_mask = mad->sa_hdr.comp_mask; |
624 | u16 val16; | 624 | u16 val16; |
@@ -1099,7 +1099,7 @@ static u8 get_src_path_mask(struct ib_device *device, u8 port_num) | |||
1099 | } | 1099 | } |
1100 | 1100 | ||
1101 | int ib_init_ah_from_path(struct ib_device *device, u8 port_num, | 1101 | int ib_init_ah_from_path(struct ib_device *device, u8 port_num, |
1102 | struct ib_sa_path_rec *rec, | 1102 | struct sa_path_rec *rec, |
1103 | struct rdma_ah_attr *ah_attr) | 1103 | struct rdma_ah_attr *ah_attr) |
1104 | { | 1104 | { |
1105 | int ret; | 1105 | int ret; |
@@ -1301,13 +1301,13 @@ static int send_mad(struct ib_sa_query *query, int timeout_ms, gfp_t gfp_mask) | |||
1301 | return ret ? ret : id; | 1301 | return ret ? ret : id; |
1302 | } | 1302 | } |
1303 | 1303 | ||
1304 | void ib_sa_unpack_path(void *attribute, struct ib_sa_path_rec *rec) | 1304 | void ib_sa_unpack_path(void *attribute, struct sa_path_rec *rec) |
1305 | { | 1305 | { |
1306 | ib_unpack(path_rec_table, ARRAY_SIZE(path_rec_table), attribute, rec); | 1306 | ib_unpack(path_rec_table, ARRAY_SIZE(path_rec_table), attribute, rec); |
1307 | } | 1307 | } |
1308 | EXPORT_SYMBOL(ib_sa_unpack_path); | 1308 | EXPORT_SYMBOL(ib_sa_unpack_path); |
1309 | 1309 | ||
1310 | void ib_sa_pack_path(struct ib_sa_path_rec *rec, void *attribute) | 1310 | void ib_sa_pack_path(struct sa_path_rec *rec, void *attribute) |
1311 | { | 1311 | { |
1312 | ib_pack(path_rec_table, ARRAY_SIZE(path_rec_table), rec, attribute); | 1312 | ib_pack(path_rec_table, ARRAY_SIZE(path_rec_table), rec, attribute); |
1313 | } | 1313 | } |
@@ -1321,7 +1321,7 @@ static void ib_sa_path_rec_callback(struct ib_sa_query *sa_query, | |||
1321 | container_of(sa_query, struct ib_sa_path_query, sa_query); | 1321 | container_of(sa_query, struct ib_sa_path_query, sa_query); |
1322 | 1322 | ||
1323 | if (mad) { | 1323 | if (mad) { |
1324 | struct ib_sa_path_rec rec; | 1324 | struct sa_path_rec rec; |
1325 | 1325 | ||
1326 | ib_unpack(path_rec_table, ARRAY_SIZE(path_rec_table), | 1326 | ib_unpack(path_rec_table, ARRAY_SIZE(path_rec_table), |
1327 | mad->data, &rec); | 1327 | mad->data, &rec); |
@@ -1366,11 +1366,11 @@ static void ib_sa_path_rec_release(struct ib_sa_query *sa_query) | |||
1366 | */ | 1366 | */ |
1367 | int ib_sa_path_rec_get(struct ib_sa_client *client, | 1367 | int ib_sa_path_rec_get(struct ib_sa_client *client, |
1368 | struct ib_device *device, u8 port_num, | 1368 | struct ib_device *device, u8 port_num, |
1369 | struct ib_sa_path_rec *rec, | 1369 | struct sa_path_rec *rec, |
1370 | ib_sa_comp_mask comp_mask, | 1370 | ib_sa_comp_mask comp_mask, |
1371 | int timeout_ms, gfp_t gfp_mask, | 1371 | int timeout_ms, gfp_t gfp_mask, |
1372 | void (*callback)(int status, | 1372 | void (*callback)(int status, |
1373 | struct ib_sa_path_rec *resp, | 1373 | struct sa_path_rec *resp, |
1374 | void *context), | 1374 | void *context), |
1375 | void *context, | 1375 | void *context, |
1376 | struct ib_sa_query **sa_query) | 1376 | struct ib_sa_query **sa_query) |
diff --git a/drivers/infiniband/core/ucm.c b/drivers/infiniband/core/ucm.c index cc0d51fb06e3..80d0fca05c06 100644 --- a/drivers/infiniband/core/ucm.c +++ b/drivers/infiniband/core/ucm.c | |||
@@ -702,10 +702,10 @@ static int ib_ucm_alloc_data(const void **dest, u64 src, u32 len) | |||
702 | return 0; | 702 | return 0; |
703 | } | 703 | } |
704 | 704 | ||
705 | static int ib_ucm_path_get(struct ib_sa_path_rec **path, u64 src) | 705 | static int ib_ucm_path_get(struct sa_path_rec **path, u64 src) |
706 | { | 706 | { |
707 | struct ib_user_path_rec upath; | 707 | struct ib_user_path_rec upath; |
708 | struct ib_sa_path_rec *sa_path; | 708 | struct sa_path_rec *sa_path; |
709 | 709 | ||
710 | *path = NULL; | 710 | *path = NULL; |
711 | 711 | ||
@@ -962,7 +962,7 @@ static ssize_t ib_ucm_send_lap(struct ib_ucm_file *file, | |||
962 | int in_len, int out_len) | 962 | int in_len, int out_len) |
963 | { | 963 | { |
964 | struct ib_ucm_context *ctx; | 964 | struct ib_ucm_context *ctx; |
965 | struct ib_sa_path_rec *path = NULL; | 965 | struct sa_path_rec *path = NULL; |
966 | struct ib_ucm_lap cmd; | 966 | struct ib_ucm_lap cmd; |
967 | const void *data = NULL; | 967 | const void *data = NULL; |
968 | int result; | 968 | int result; |
diff --git a/drivers/infiniband/core/ucma.c b/drivers/infiniband/core/ucma.c index e12f8faf8c23..2beff90f4bbb 100644 --- a/drivers/infiniband/core/ucma.c +++ b/drivers/infiniband/core/ucma.c | |||
@@ -1197,7 +1197,7 @@ static int ucma_set_option_id(struct ucma_context *ctx, int optname, | |||
1197 | static int ucma_set_ib_path(struct ucma_context *ctx, | 1197 | static int ucma_set_ib_path(struct ucma_context *ctx, |
1198 | struct ib_path_rec_data *path_data, size_t optlen) | 1198 | struct ib_path_rec_data *path_data, size_t optlen) |
1199 | { | 1199 | { |
1200 | struct ib_sa_path_rec sa_path; | 1200 | struct sa_path_rec sa_path; |
1201 | struct rdma_cm_event event; | 1201 | struct rdma_cm_event event; |
1202 | int ret; | 1202 | int ret; |
1203 | 1203 | ||
diff --git a/drivers/infiniband/core/uverbs_marshall.c b/drivers/infiniband/core/uverbs_marshall.c index cb4ba16f830f..eda6f301a3b1 100644 --- a/drivers/infiniband/core/uverbs_marshall.c +++ b/drivers/infiniband/core/uverbs_marshall.c | |||
@@ -97,7 +97,7 @@ void ib_copy_qp_attr_to_user(struct ib_uverbs_qp_attr *dst, | |||
97 | EXPORT_SYMBOL(ib_copy_qp_attr_to_user); | 97 | EXPORT_SYMBOL(ib_copy_qp_attr_to_user); |
98 | 98 | ||
99 | void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, | 99 | void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, |
100 | struct ib_sa_path_rec *src) | 100 | struct sa_path_rec *src) |
101 | { | 101 | { |
102 | memcpy(dst->dgid, src->dgid.raw, sizeof src->dgid); | 102 | memcpy(dst->dgid, src->dgid.raw, sizeof src->dgid); |
103 | memcpy(dst->sgid, src->sgid.raw, sizeof src->sgid); | 103 | memcpy(dst->sgid, src->sgid.raw, sizeof src->sgid); |
@@ -122,7 +122,7 @@ void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, | |||
122 | } | 122 | } |
123 | EXPORT_SYMBOL(ib_copy_path_rec_to_user); | 123 | EXPORT_SYMBOL(ib_copy_path_rec_to_user); |
124 | 124 | ||
125 | void ib_copy_path_rec_from_user(struct ib_sa_path_rec *dst, | 125 | void ib_copy_path_rec_from_user(struct sa_path_rec *dst, |
126 | struct ib_user_path_rec *src) | 126 | struct ib_user_path_rec *src) |
127 | { | 127 | { |
128 | memcpy(dst->dgid.raw, src->dgid, sizeof dst->dgid); | 128 | memcpy(dst->dgid.raw, src->dgid, sizeof dst->dgid); |
diff --git a/drivers/infiniband/ulp/ipoib/ipoib.h b/drivers/infiniband/ulp/ipoib/ipoib.h index fc9b0a3964f1..ff50a7bd66d8 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib.h +++ b/drivers/infiniband/ulp/ipoib/ipoib.h | |||
@@ -423,7 +423,7 @@ struct ipoib_ah { | |||
423 | 423 | ||
424 | struct ipoib_path { | 424 | struct ipoib_path { |
425 | struct net_device *dev; | 425 | struct net_device *dev; |
426 | struct ib_sa_path_rec pathrec; | 426 | struct sa_path_rec pathrec; |
427 | struct ipoib_ah *ah; | 427 | struct ipoib_ah *ah; |
428 | struct sk_buff_head queue; | 428 | struct sk_buff_head queue; |
429 | 429 | ||
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_cm.c b/drivers/infiniband/ulp/ipoib/ipoib_cm.c index 21303c07ca55..7cbcfdac6529 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_cm.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_cm.c | |||
@@ -1068,7 +1068,7 @@ static struct ib_qp *ipoib_cm_create_tx_qp(struct net_device *dev, struct ipoib_ | |||
1068 | static int ipoib_cm_send_req(struct net_device *dev, | 1068 | static int ipoib_cm_send_req(struct net_device *dev, |
1069 | struct ib_cm_id *id, struct ib_qp *qp, | 1069 | struct ib_cm_id *id, struct ib_qp *qp, |
1070 | u32 qpn, | 1070 | u32 qpn, |
1071 | struct ib_sa_path_rec *pathrec) | 1071 | struct sa_path_rec *pathrec) |
1072 | { | 1072 | { |
1073 | struct ipoib_dev_priv *priv = ipoib_priv(dev); | 1073 | struct ipoib_dev_priv *priv = ipoib_priv(dev); |
1074 | struct ipoib_cm_data data = {}; | 1074 | struct ipoib_cm_data data = {}; |
@@ -1128,7 +1128,7 @@ static int ipoib_cm_modify_tx_init(struct net_device *dev, | |||
1128 | } | 1128 | } |
1129 | 1129 | ||
1130 | static int ipoib_cm_tx_init(struct ipoib_cm_tx *p, u32 qpn, | 1130 | static int ipoib_cm_tx_init(struct ipoib_cm_tx *p, u32 qpn, |
1131 | struct ib_sa_path_rec *pathrec) | 1131 | struct sa_path_rec *pathrec) |
1132 | { | 1132 | { |
1133 | struct ipoib_dev_priv *priv = ipoib_priv(p->dev); | 1133 | struct ipoib_dev_priv *priv = ipoib_priv(p->dev); |
1134 | int ret; | 1134 | int ret; |
@@ -1332,7 +1332,7 @@ static void ipoib_cm_tx_start(struct work_struct *work) | |||
1332 | struct ipoib_path *path; | 1332 | struct ipoib_path *path; |
1333 | int ret; | 1333 | int ret; |
1334 | 1334 | ||
1335 | struct ib_sa_path_rec pathrec; | 1335 | struct sa_path_rec pathrec; |
1336 | u32 qpn; | 1336 | u32 qpn; |
1337 | 1337 | ||
1338 | netif_tx_lock_bh(dev); | 1338 | netif_tx_lock_bh(dev); |
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c b/drivers/infiniband/ulp/ipoib/ipoib_main.c index f6002ef2deaa..535621ff7f6e 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_main.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c | |||
@@ -716,7 +716,7 @@ void ipoib_flush_paths(struct net_device *dev) | |||
716 | } | 716 | } |
717 | 717 | ||
718 | static void path_rec_completion(int status, | 718 | static void path_rec_completion(int status, |
719 | struct ib_sa_path_rec *pathrec, | 719 | struct sa_path_rec *pathrec, |
720 | void *path_ptr) | 720 | void *path_ptr) |
721 | { | 721 | { |
722 | struct ipoib_path *path = path_ptr; | 722 | struct ipoib_path *path = path_ptr; |
diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c index cee46266f434..ded9b9afbac0 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.c +++ b/drivers/infiniband/ulp/srp/ib_srp.c | |||
@@ -643,7 +643,7 @@ static void srp_free_ch_ib(struct srp_target_port *target, | |||
643 | } | 643 | } |
644 | 644 | ||
645 | static void srp_path_rec_completion(int status, | 645 | static void srp_path_rec_completion(int status, |
646 | struct ib_sa_path_rec *pathrec, | 646 | struct sa_path_rec *pathrec, |
647 | void *ch_ptr) | 647 | void *ch_ptr) |
648 | { | 648 | { |
649 | struct srp_rdma_ch *ch = ch_ptr; | 649 | struct srp_rdma_ch *ch = ch_ptr; |
diff --git a/drivers/infiniband/ulp/srp/ib_srp.h b/drivers/infiniband/ulp/srp/ib_srp.h index 32ed40db3ca2..ab9077b81d5a 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.h +++ b/drivers/infiniband/ulp/srp/ib_srp.h | |||
@@ -152,7 +152,7 @@ struct srp_rdma_ch { | |||
152 | struct completion done; | 152 | struct completion done; |
153 | int status; | 153 | int status; |
154 | 154 | ||
155 | struct ib_sa_path_rec path; | 155 | struct sa_path_rec path; |
156 | struct ib_sa_query *path_query; | 156 | struct ib_sa_query *path_query; |
157 | int path_query_id; | 157 | int path_query_id; |
158 | 158 | ||
diff --git a/include/rdma/ib_cm.h b/include/rdma/ib_cm.h index b49258b16f4e..7979cb04f529 100644 --- a/include/rdma/ib_cm.h +++ b/include/rdma/ib_cm.h | |||
@@ -117,8 +117,8 @@ struct ib_cm_req_event_param { | |||
117 | 117 | ||
118 | u8 port; | 118 | u8 port; |
119 | 119 | ||
120 | struct ib_sa_path_rec *primary_path; | 120 | struct sa_path_rec *primary_path; |
121 | struct ib_sa_path_rec *alternate_path; | 121 | struct sa_path_rec *alternate_path; |
122 | 122 | ||
123 | __be64 remote_ca_guid; | 123 | __be64 remote_ca_guid; |
124 | u32 remote_qkey; | 124 | u32 remote_qkey; |
@@ -197,7 +197,7 @@ struct ib_cm_mra_event_param { | |||
197 | }; | 197 | }; |
198 | 198 | ||
199 | struct ib_cm_lap_event_param { | 199 | struct ib_cm_lap_event_param { |
200 | struct ib_sa_path_rec *alternate_path; | 200 | struct sa_path_rec *alternate_path; |
201 | }; | 201 | }; |
202 | 202 | ||
203 | enum ib_cm_apr_status { | 203 | enum ib_cm_apr_status { |
@@ -363,8 +363,8 @@ struct ib_cm_id *ib_cm_insert_listen(struct ib_device *device, | |||
363 | __be64 service_id); | 363 | __be64 service_id); |
364 | 364 | ||
365 | struct ib_cm_req_param { | 365 | struct ib_cm_req_param { |
366 | struct ib_sa_path_rec *primary_path; | 366 | struct sa_path_rec *primary_path; |
367 | struct ib_sa_path_rec *alternate_path; | 367 | struct sa_path_rec *alternate_path; |
368 | __be64 service_id; | 368 | __be64 service_id; |
369 | u32 qp_num; | 369 | u32 qp_num; |
370 | enum ib_qp_type qp_type; | 370 | enum ib_qp_type qp_type; |
@@ -521,7 +521,7 @@ int ib_send_cm_mra(struct ib_cm_id *cm_id, | |||
521 | * @private_data_len: Size of the private data buffer, in bytes. | 521 | * @private_data_len: Size of the private data buffer, in bytes. |
522 | */ | 522 | */ |
523 | int ib_send_cm_lap(struct ib_cm_id *cm_id, | 523 | int ib_send_cm_lap(struct ib_cm_id *cm_id, |
524 | struct ib_sa_path_rec *alternate_path, | 524 | struct sa_path_rec *alternate_path, |
525 | const void *private_data, | 525 | const void *private_data, |
526 | u8 private_data_len); | 526 | u8 private_data_len); |
527 | 527 | ||
@@ -565,7 +565,7 @@ int ib_send_cm_apr(struct ib_cm_id *cm_id, | |||
565 | u8 private_data_len); | 565 | u8 private_data_len); |
566 | 566 | ||
567 | struct ib_cm_sidr_req_param { | 567 | struct ib_cm_sidr_req_param { |
568 | struct ib_sa_path_rec *path; | 568 | struct sa_path_rec *path; |
569 | __be64 service_id; | 569 | __be64 service_id; |
570 | int timeout_ms; | 570 | int timeout_ms; |
571 | const void *private_data; | 571 | const void *private_data; |
diff --git a/include/rdma/ib_marshall.h b/include/rdma/ib_marshall.h index 42a0fc6f2f03..68cef3bd50fb 100644 --- a/include/rdma/ib_marshall.h +++ b/include/rdma/ib_marshall.h | |||
@@ -45,9 +45,9 @@ void ib_copy_ah_attr_to_user(struct ib_uverbs_ah_attr *dst, | |||
45 | struct rdma_ah_attr *src); | 45 | struct rdma_ah_attr *src); |
46 | 46 | ||
47 | void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, | 47 | void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, |
48 | struct ib_sa_path_rec *src); | 48 | struct sa_path_rec *src); |
49 | 49 | ||
50 | void ib_copy_path_rec_from_user(struct ib_sa_path_rec *dst, | 50 | void ib_copy_path_rec_from_user(struct sa_path_rec *dst, |
51 | struct ib_user_path_rec *src); | 51 | struct ib_user_path_rec *src); |
52 | 52 | ||
53 | #endif /* IB_USER_MARSHALL_H */ | 53 | #endif /* IB_USER_MARSHALL_H */ |
diff --git a/include/rdma/ib_sa.h b/include/rdma/ib_sa.h index 3ff8e64fca85..7efdfb16ee83 100644 --- a/include/rdma/ib_sa.h +++ b/include/rdma/ib_sa.h | |||
@@ -148,7 +148,7 @@ enum ib_sa_mc_join_states { | |||
148 | #define IB_SA_PATH_REC_PACKET_LIFE_TIME IB_SA_COMP_MASK(21) | 148 | #define IB_SA_PATH_REC_PACKET_LIFE_TIME IB_SA_COMP_MASK(21) |
149 | #define IB_SA_PATH_REC_PREFERENCE IB_SA_COMP_MASK(22) | 149 | #define IB_SA_PATH_REC_PREFERENCE IB_SA_COMP_MASK(22) |
150 | 150 | ||
151 | struct ib_sa_path_rec { | 151 | struct sa_path_rec { |
152 | __be64 service_id; | 152 | __be64 service_id; |
153 | union ib_gid dgid; | 153 | union ib_gid dgid; |
154 | union ib_gid sgid; | 154 | union ib_gid sgid; |
@@ -179,7 +179,7 @@ struct ib_sa_path_rec { | |||
179 | enum ib_gid_type gid_type; | 179 | enum ib_gid_type gid_type; |
180 | }; | 180 | }; |
181 | 181 | ||
182 | static inline struct net_device *ib_get_ndev_from_path(struct ib_sa_path_rec *rec) | 182 | static inline struct net_device *ib_get_ndev_from_path(struct sa_path_rec *rec) |
183 | { | 183 | { |
184 | return rec->net ? dev_get_by_index(rec->net, rec->ifindex) : NULL; | 184 | return rec->net ? dev_get_by_index(rec->net, rec->ifindex) : NULL; |
185 | } | 185 | } |
@@ -323,11 +323,11 @@ void ib_sa_cancel_query(int id, struct ib_sa_query *query); | |||
323 | 323 | ||
324 | int ib_sa_path_rec_get(struct ib_sa_client *client, | 324 | int ib_sa_path_rec_get(struct ib_sa_client *client, |
325 | struct ib_device *device, u8 port_num, | 325 | struct ib_device *device, u8 port_num, |
326 | struct ib_sa_path_rec *rec, | 326 | struct sa_path_rec *rec, |
327 | ib_sa_comp_mask comp_mask, | 327 | ib_sa_comp_mask comp_mask, |
328 | int timeout_ms, gfp_t gfp_mask, | 328 | int timeout_ms, gfp_t gfp_mask, |
329 | void (*callback)(int status, | 329 | void (*callback)(int status, |
330 | struct ib_sa_path_rec *resp, | 330 | struct sa_path_rec *resp, |
331 | void *context), | 331 | void *context), |
332 | void *context, | 332 | void *context, |
333 | struct ib_sa_query **query); | 333 | struct ib_sa_query **query); |
@@ -428,20 +428,20 @@ int ib_init_ah_from_mcmember(struct ib_device *device, u8 port_num, | |||
428 | * path record. | 428 | * path record. |
429 | */ | 429 | */ |
430 | int ib_init_ah_from_path(struct ib_device *device, u8 port_num, | 430 | int ib_init_ah_from_path(struct ib_device *device, u8 port_num, |
431 | struct ib_sa_path_rec *rec, | 431 | struct sa_path_rec *rec, |
432 | struct rdma_ah_attr *ah_attr); | 432 | struct rdma_ah_attr *ah_attr); |
433 | 433 | ||
434 | /** | 434 | /** |
435 | * ib_sa_pack_path - Conert a path record from struct ib_sa_path_rec | 435 | * ib_sa_pack_path - Conert a path record from struct ib_sa_path_rec |
436 | * to IB MAD wire format. | 436 | * to IB MAD wire format. |
437 | */ | 437 | */ |
438 | void ib_sa_pack_path(struct ib_sa_path_rec *rec, void *attribute); | 438 | void ib_sa_pack_path(struct sa_path_rec *rec, void *attribute); |
439 | 439 | ||
440 | /** | 440 | /** |
441 | * ib_sa_unpack_path - Convert a path record from MAD format to struct | 441 | * ib_sa_unpack_path - Convert a path record from MAD format to struct |
442 | * ib_sa_path_rec. | 442 | * ib_sa_path_rec. |
443 | */ | 443 | */ |
444 | void ib_sa_unpack_path(void *attribute, struct ib_sa_path_rec *rec); | 444 | void ib_sa_unpack_path(void *attribute, struct sa_path_rec *rec); |
445 | 445 | ||
446 | /* Support GuidInfoRecord */ | 446 | /* Support GuidInfoRecord */ |
447 | int ib_sa_guid_info_rec_query(struct ib_sa_client *client, | 447 | int ib_sa_guid_info_rec_query(struct ib_sa_client *client, |
diff --git a/include/rdma/rdma_cm.h b/include/rdma/rdma_cm.h index c9ac1e1270d1..3d2eed3c4e75 100644 --- a/include/rdma/rdma_cm.h +++ b/include/rdma/rdma_cm.h | |||
@@ -85,7 +85,7 @@ struct rdma_addr { | |||
85 | 85 | ||
86 | struct rdma_route { | 86 | struct rdma_route { |
87 | struct rdma_addr addr; | 87 | struct rdma_addr addr; |
88 | struct ib_sa_path_rec *path_rec; | 88 | struct sa_path_rec *path_rec; |
89 | int num_paths; | 89 | int num_paths; |
90 | }; | 90 | }; |
91 | 91 | ||
diff --git a/include/rdma/rdma_cm_ib.h b/include/rdma/rdma_cm_ib.h index 2389c3b45404..6947a6ba2557 100644 --- a/include/rdma/rdma_cm_ib.h +++ b/include/rdma/rdma_cm_ib.h | |||
@@ -46,7 +46,7 @@ | |||
46 | * connection and replaces the call to rdma_resolve_route. | 46 | * connection and replaces the call to rdma_resolve_route. |
47 | */ | 47 | */ |
48 | int rdma_set_ib_paths(struct rdma_cm_id *id, | 48 | int rdma_set_ib_paths(struct rdma_cm_id *id, |
49 | struct ib_sa_path_rec *path_rec, int num_paths); | 49 | struct sa_path_rec *path_rec, int num_paths); |
50 | 50 | ||
51 | /* Global qkey for UDP QPs and multicast groups. */ | 51 | /* Global qkey for UDP QPs and multicast groups. */ |
52 | #define RDMA_UDP_QKEY 0x01234567 | 52 | #define RDMA_UDP_QKEY 0x01234567 |