Home
last modified time | relevance | path

Searched refs:grh (Results 1 – 25 of 53) sorted by relevance

123

/freebsd/sys/ofed/drivers/infiniband/core/
H A Dib_uverbs_marshall.c71 memset(&dst->grh.reserved, 0, sizeof(dst->grh.reserved)); in ib_copy_ah_attr_to_user()
85 const struct ib_global_route *grh = rdma_ah_read_grh(src); in ib_copy_ah_attr_to_user() local
87 memcpy(dst->grh.dgid, grh->dgid.raw, sizeof(grh->dgid)); in ib_copy_ah_attr_to_user()
88 dst->grh.flow_label = grh->flow_label; in ib_copy_ah_attr_to_user()
89 dst->grh.sgid_index = grh->sgid_index; in ib_copy_ah_attr_to_user()
90 dst->grh.hop_limit = grh->hop_limit; in ib_copy_ah_attr_to_user()
91 dst->grh.traffic_class = grh->traffic_class; in ib_copy_ah_attr_to_user()
H A Dib_ud_header.c190 { STRUCT_FIELD(grh, ip_version),
194 { STRUCT_FIELD(grh, traffic_class),
198 { STRUCT_FIELD(grh, flow_label),
202 { STRUCT_FIELD(grh, payload_length),
206 { STRUCT_FIELD(grh, next_header),
210 { STRUCT_FIELD(grh, hop_limit),
214 { STRUCT_FIELD(grh, source_gid),
218 { STRUCT_FIELD(grh, destination_gid),
363 header->grh.ip_version = 6; in ib_ud_header_init()
364 header->grh.payload_length = in ib_ud_header_init()
[all …]
H A Dib_verbs.c368 if (dest->grh.sgid_attr) in rdma_copy_ah_attr()
369 rdma_hold_gid_attr(dest->grh.sgid_attr); in rdma_copy_ah_attr()
388 if (old->grh.sgid_attr) in rdma_replace_ah_attr()
389 rdma_hold_gid_attr(old->grh.sgid_attr); in rdma_replace_ah_attr()
408 src->grh.sgid_attr = NULL; in rdma_move_ah_attr()
426 if (ah_attr->grh.sgid_attr) { in rdma_check_ah_attr()
431 if (ah_attr->grh.sgid_attr->index != ah_attr->grh.sgid_index || in rdma_check_ah_attr()
432 ah_attr->grh.sgid_attr->port_num != ah_attr->port_num) in rdma_check_ah_attr()
447 struct ib_global_route *grh; in rdma_fill_sgid_attr() local
450 *old_sgid_attr = ah_attr->grh.sgid_attr; in rdma_fill_sgid_attr()
[all …]
H A Dib_agent.c83 void agent_send_response(const struct ib_mad_hdr *mad_hdr, const struct ib_grh *grh, in agent_send_response() argument
104 ah = ib_create_ah_from_wc(agent->qp->pd, wc, grh, port_num); in agent_send_response()
H A Dagent.h49 extern void agent_send_response(const struct ib_mad_hdr *mad_hdr, const struct ib_grh *grh,
H A Dib_mad.c1883 const struct ib_global_route *grh = in rcv_has_same_gid() local
1887 grh->sgid_index, &sgid)) in rcv_has_same_gid()
1889 return !memcmp(sgid.raw, rwc->recv_buf.grh->dgid.raw, in rcv_has_same_gid()
1898 rwc->recv_buf.grh->sgid.raw, in rcv_has_same_gid()
2056 response->header.recv_wc.recv_buf.grh = &response->grh; in handle_ib_smi()
2059 &response->grh, wc, in handle_ib_smi()
2083 response->header.recv_wc.recv_buf.grh = &response->grh; in generate_unmatched_resp()
2144 response->header.recv_wc.recv_buf.grh = &response->grh; in handle_opa_smi()
2147 &response->grh, wc, in handle_opa_smi()
2232 recv->header.recv_wc.recv_buf.grh = &recv->grh; in ib_mad_recv_done()
[all …]
H A Dib_user_mad.c241 const struct ib_global_route *grh; in recv_handler() local
246 mad_recv_wc->recv_buf.grh, in recv_handler()
251 grh = rdma_ah_read_grh(&ah_attr); in recv_handler()
252 packet->mad.hdr.gid_index = grh->sgid_index; in recv_handler()
253 packet->mad.hdr.hop_limit = grh->hop_limit; in recv_handler()
254 packet->mad.hdr.traffic_class = grh->traffic_class; in recv_handler()
255 memcpy(packet->mad.hdr.gid, &grh->dgid, 16); in recv_handler()
256 packet->mad.hdr.flow_label = cpu_to_be32(grh->flow_label); in recv_handler()
/freebsd/contrib/ofed/libibverbs/
H A Dmarshall.c42 memcpy(dst->grh.dgid.raw, src->grh.dgid, sizeof dst->grh.dgid); in ibv_copy_ah_attr_from_kern()
43 dst->grh.flow_label = src->grh.flow_label; in ibv_copy_ah_attr_from_kern()
44 dst->grh.sgid_index = src->grh.sgid_index; in ibv_copy_ah_attr_from_kern()
45 dst->grh.hop_limit = src->grh.hop_limit; in ibv_copy_ah_attr_from_kern()
46 dst->grh.traffic_class = src->grh.traffic_class; in ibv_copy_ah_attr_from_kern()
H A Dverbs.c775 static inline int get_grh_header_version(struct ibv_grh *grh) in get_grh_header_version() argument
777 int ip6h_version = (be32toh(grh->version_tclass_flow) >> 28) & 0xf; in get_grh_header_version()
778 struct ip *ip4h = (struct ip *)((void *)grh + 20); in get_grh_header_version()
809 struct ibv_grh *grh, in set_ah_attr_generic_fields() argument
814 flow_class = be32toh(grh->version_tclass_flow); in set_ah_attr_generic_fields()
815 ah_attr->grh.flow_label = flow_class & 0xFFFFF; in set_ah_attr_generic_fields()
842 (struct in6_addr *)&ah_attr->grh.dgid); in set_ah_attr_by_ipv4()
843 ah_attr->grh.sgid_index = (uint8_t) ret; in set_ah_attr_by_ipv4()
844 ah_attr->grh.hop_limit = ip4h->ip_ttl; in set_ah_attr_by_ipv4()
845 ah_attr->grh.traffic_class = ip4h->ip_tos; in set_ah_attr_by_ipv4()
[all …]
H A Dcmd.c1273 memcpy(attr->ah_attr.grh.dgid.raw, resp.dest.dgid, 16); in ibv_cmd_query_qp()
1274 attr->ah_attr.grh.flow_label = resp.dest.flow_label; in ibv_cmd_query_qp()
1276 attr->ah_attr.grh.sgid_index = resp.dest.sgid_index; in ibv_cmd_query_qp()
1277 attr->ah_attr.grh.hop_limit = resp.dest.hop_limit; in ibv_cmd_query_qp()
1278 attr->ah_attr.grh.traffic_class = resp.dest.traffic_class; in ibv_cmd_query_qp()
1285 memcpy(attr->alt_ah_attr.grh.dgid.raw, resp.alt_dest.dgid, 16); in ibv_cmd_query_qp()
1286 attr->alt_ah_attr.grh.flow_label = resp.alt_dest.flow_label; in ibv_cmd_query_qp()
1288 attr->alt_ah_attr.grh.sgid_index = resp.alt_dest.sgid_index; in ibv_cmd_query_qp()
1289 attr->alt_ah_attr.grh.hop_limit = resp.alt_dest.hop_limit; in ibv_cmd_query_qp()
1290 attr->alt_ah_attr.grh.traffic_class = resp.alt_dest.traffic_class; in ibv_cmd_query_qp()
[all …]
/freebsd/sys/dev/mlx4/mlx4_ib/
H A Dmlx4_ib_ah.c56 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in create_ib_ah() local
59 ah->av.ib.gid_index = grh->sgid_index; in create_ib_ah()
60 ah->av.ib.hop_limit = grh->hop_limit; in create_ib_ah()
62 cpu_to_be32((grh->traffic_class << 20) | in create_ib_ah()
63 grh->flow_label); in create_ib_ah()
64 memcpy(ah->av.ib.dgid, grh->dgid.raw, 16); in create_ib_ah()
85 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in create_iboe_ah() local
91 memcpy(&in6, grh->dgid.raw, sizeof(in6)); in create_iboe_ah()
97 gid_attr = ah_attr->grh.sgid_attr; in create_iboe_ah()
112 ah->av.eth.hop_limit = grh->hop_limit; in create_iboe_ah()
[all …]
H A Dmlx4_ib_mad.c69 struct ib_grh grh; member
78 struct ib_grh grh; member
85 struct ib_grh grh; member
152 u8 grh[40]; in mlx4_MAD_IFC() member
166 memcpy(ext_info->grh, in_grh, 40); in mlx4_MAD_IFC()
483 static int get_gids_from_l3_hdr(struct ib_grh *grh, union ib_gid *sgid, in get_gids_from_l3_hdr() argument
486 int version = ib_get_rdma_header_version((const union rdma_network_hdr *)grh); in get_gids_from_l3_hdr()
496 return ib_get_gids_from_rdma_hdr((union rdma_network_hdr *)grh, net_type, in get_gids_from_l3_hdr()
502 struct ib_grh *grh, struct ib_mad *mad) in mlx4_ib_send_to_slave() argument
563 if (get_gids_from_l3_hdr(grh, &sgid, &dgid)) in mlx4_ib_send_to_slave()
[all …]
/freebsd/sys/dev/mlx5/mlx5_ib/
H A Dmlx5_ib_ah.c36 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in create_ib_ah() local
38 memcpy(ah->av.rgid, &grh->dgid, 16); in create_ib_ah()
39 ah->av.grh_gid_fl = cpu_to_be32(grh->flow_label | in create_ib_ah()
41 grh->sgid_index << 20); in create_ib_ah()
42 ah->av.hop_limit = grh->hop_limit; in create_ib_ah()
43 ah->av.tclass = grh->traffic_class; in create_ib_ah()
52 mlx5_get_roce_udp_sport(dev, ah_attr->grh.sgid_attr); in create_ib_ah()
/freebsd/sys/dev/mthca/
H A Dmthca_av.c210 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in mthca_create_ah() local
215 grh->sgid_index; in mthca_create_ah()
216 av->hop_limit = grh->hop_limit; in mthca_create_ah()
218 cpu_to_be32((grh->traffic_class << 20) | in mthca_create_ah()
219 grh->flow_label); in mthca_create_ah()
220 memcpy(av->dgid, grh->dgid.raw, 16); in mthca_create_ah()
281 header->grh.traffic_class = in mthca_read_ah()
283 header->grh.flow_label = in mthca_read_ah()
285 header->grh.hop_limit = ah->av->hop_limit; in mthca_read_ah()
286 header->grh.source_gid = ah->ibah.sgid_attr->gid; in mthca_read_ah()
[all …]
/freebsd/sys/dev/qlnx/qlnxr/
H A Dqlnxr_cm.c489 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in qlnxr_gsi_build_header() local
490 const struct ib_gid_attr *sgid_attr = grh->sgid_attr; in qlnxr_gsi_build_header()
540 qp, swr->opcode, swr->wr_id, *roce_mode, grh->hop_limit, in qlnxr_gsi_build_header()
545 udh->grh.traffic_class = grh->traffic_class; in qlnxr_gsi_build_header()
546 udh->grh.flow_label = grh->flow_label; in qlnxr_gsi_build_header()
547 udh->grh.hop_limit = grh->hop_limit; in qlnxr_gsi_build_header()
548 udh->grh.destination_gid = grh->dgid; in qlnxr_gsi_build_header()
549 memcpy(&udh->grh.source_gid.raw, sgid_attr->gid.raw, in qlnxr_gsi_build_header()
550 sizeof(udh->grh.source_gid.raw)); in qlnxr_gsi_build_header()
552 "hop_limit: %x \n", udh->grh.traffic_class, in qlnxr_gsi_build_header()
[all …]
H A Dqlnxr_def.h834 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in qlnxr_get_dmac() local
836 u8 *guid = &grh->dgid.raw[8]; /* GID's 64 MSBs are the GUID */ in qlnxr_get_dmac()
841 if (!memcmp(&grh->dgid, &zero_sgid, sizeof(union ib_gid))) { in qlnxr_get_dmac()
846 memcpy(&in6, grh->dgid.raw, sizeof(in6)); in qlnxr_get_dmac()
/freebsd/contrib/ofed/libmlx4/
H A Dverbs.c1170 if (link_local_gid(&attr->grh.dgid)) { in mlx4_resolve_grh_to_l2()
1171 memcpy(ah->mac, &attr->grh.dgid.raw[8], 3); in mlx4_resolve_grh_to_l2()
1172 memcpy(ah->mac + 3, &attr->grh.dgid.raw[13], 3); in mlx4_resolve_grh_to_l2()
1175 vid = get_vlan_id(&attr->grh.dgid); in mlx4_resolve_grh_to_l2()
1176 } else if (is_multicast_gid(&attr->grh.dgid)) { in mlx4_resolve_grh_to_l2()
1180 ah->mac[i] = attr->grh.dgid.raw[i + 10]; in mlx4_resolve_grh_to_l2()
1183 attr->grh.sgid_index, &sgid); in mlx4_resolve_grh_to_l2()
1231 ah->av.gid_index = attr->grh.sgid_index; in mlx4_create_ah()
1232 ah->av.hop_limit = attr->grh.hop_limit; in mlx4_create_ah()
1234 htobe32((attr->grh.traffic_class << 20) | in mlx4_create_ah()
[all …]
/freebsd/contrib/ofed/opensm/libvendor/
H A Dosm_vendor_mlx_ibmgt.c730 ib_grh_set_ver_class_flow(p_rcv_desc->grh. in __osmv_IBMGT_rcv_desc_to_osm_addr()
732 p_rcv_desc->grh. in __osmv_IBMGT_rcv_desc_to_osm_addr()
734 p_rcv_desc->grh. in __osmv_IBMGT_rcv_desc_to_osm_addr()
737 p_rcv_desc->grh.hop_limit; in __osmv_IBMGT_rcv_desc_to_osm_addr()
739 &p_rcv_desc->grh.sgid, sizeof(ib_net64_t)); in __osmv_IBMGT_rcv_desc_to_osm_addr()
741 p_rcv_desc->grh.dgid, sizeof(ib_net64_t)); in __osmv_IBMGT_rcv_desc_to_osm_addr()
H A Dosm_vendor_mtl.c121 ib_grh_set_ver_class_flow(p_rcv_desc->grh. in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
123 p_rcv_desc->grh. in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
125 p_rcv_desc->grh. in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
128 p_rcv_desc->grh.hop_limit; in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
130 &p_rcv_desc->grh.sgid, sizeof(ib_net64_t)); in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
132 p_rcv_desc->grh.dgid, sizeof(ib_net64_t)); in __osm_mtl_conv_ibmgt_rcv_desc_to_osm_addr()
/freebsd/sys/ofed/include/rdma/
H A Dib_verbs.h866 struct ib_global_route grh; member
3090 const struct ib_wc *wc, const struct ib_grh *grh,
3106 const struct ib_grh *grh, u8 port_num);
4079 return &attr->grh; in rdma_ah_read_grh()
4086 return &attr->grh; in rdma_ah_retrieve_grh()
4091 struct ib_global_route *grh = rdma_ah_retrieve_grh(attr); in rdma_ah_set_dgid_raw() local
4093 memcpy(grh->dgid.raw, dgid, sizeof(grh->dgid)); in rdma_ah_set_dgid_raw()
4099 struct ib_global_route *grh = rdma_ah_retrieve_grh(attr); in rdma_ah_set_subnet_prefix() local
4101 grh->dgid.global.subnet_prefix = prefix; in rdma_ah_set_subnet_prefix()
4107 struct ib_global_route *grh = rdma_ah_retrieve_grh(attr); in rdma_ah_set_interface_id() local
[all …]
H A Dib_hdrs.h120 struct ib_grh grh; member
/freebsd/sys/dev/irdma/
H A Dirdma_kcompat.c556 ah->sgid_index = attr->grh.sgid_index; in irdma_create_sleepable_ah()
557 memcpy(&ah->dgid, &attr->grh.dgid, sizeof(ah->dgid)); in irdma_create_sleepable_ah()
558 sgid_attr = attr->grh.sgid_attr; in irdma_create_sleepable_ah()
561 rdma_gid2ip((struct sockaddr *)&dgid_addr, &attr->grh.dgid); in irdma_create_sleepable_ah()
571 ah_info->flow_label = attr->grh.flow_label; in irdma_create_sleepable_ah()
572 ah_info->hop_ttl = attr->grh.hop_limit; in irdma_create_sleepable_ah()
573 ah_info->tc_tos = attr->grh.traffic_class; in irdma_create_sleepable_ah()
1385 const struct ib_global_route *grh = rdma_ah_read_grh(&attr->ah_attr); in kc_irdma_set_roce_cm_info() local
1387 sgid_attr = grh->sgid_attr; in kc_irdma_set_roce_cm_info()
/freebsd/contrib/ofed/libmlx5/
H A Dverbs.c1666 uint8_t grh; in mlx5_create_ah() local
1693 attr->grh.sgid_index, &gid_type)) in mlx5_create_ah()
1703 grh = 0; in mlx5_create_ah()
1707 grh = 1; in mlx5_create_ah()
1711 ah->av.tclass = attr->grh.traffic_class; in mlx5_create_ah()
1712 ah->av.hop_limit = attr->grh.hop_limit; in mlx5_create_ah()
1713 tmp = htobe32((grh << 30) | in mlx5_create_ah()
1714 ((attr->grh.sgid_index & 0xff) << 20) | in mlx5_create_ah()
1715 (attr->grh.flow_label & 0xfffff)); in mlx5_create_ah()
1717 memcpy(ah->av.rgid, attr->grh in mlx5_create_ah()
[all...]
/freebsd/sys/dev/bnxt/bnxt_re/
H A Dib_verbs.c933 const struct ib_global_route *grh = rdma_ah_read_grh(ah_attr); in bnxt_re_get_ah_info() local
936 gattr = grh->sgid_attr; in bnxt_re_get_ah_info()
968 const struct ib_global_route *grh = rdma_ah_read_grh(attr); in bnxt_re_create_ah() local
983 memcpy(ah->qplib_ah.dgid.data, grh->dgid.raw, in bnxt_re_create_ah()
985 ah->qplib_ah.sgid_index = _get_sgid_index(rdev, grh->sgid_index); in bnxt_re_create_ah()
991 ah->qplib_ah.host_sgid_index = grh->sgid_index; in bnxt_re_create_ah()
992 ah->qplib_ah.traffic_class = grh->traffic_class; in bnxt_re_create_ah()
993 ah->qplib_ah.flow_label = grh->flow_label; in bnxt_re_create_ah()
994 ah->qplib_ah.hop_limit = grh->hop_limit; in bnxt_re_create_ah()
2629 const struct ib_global_route *grh = in bnxt_re_modify_qp() local
[all …]
/freebsd/contrib/ofed/libibverbs/examples/
H A Duc_pingpong.c99 attr.ah_attr.grh.hop_limit = 1; in pp_connect_ctx()
100 attr.ah_attr.grh.dgid = dest->gid; in pp_connect_ctx()
101 attr.ah_attr.grh.sgid_index = sgid_idx; in pp_connect_ctx()

123