/drivers/staging/rdma/ehca/ |
D | ehca_av.c | 118 av->av.grh.word_0 = EHCA_BMASK_SET(GRH_IPVERSION_MASK, 6); in ehca_create_ah() 119 av->av.grh.word_0 |= EHCA_BMASK_SET(GRH_TCLASS_MASK, in ehca_create_ah() 120 ah_attr->grh.traffic_class); in ehca_create_ah() 121 av->av.grh.word_0 |= EHCA_BMASK_SET(GRH_FLOWLABEL_MASK, in ehca_create_ah() 122 ah_attr->grh.flow_label); in ehca_create_ah() 123 av->av.grh.word_0 |= EHCA_BMASK_SET(GRH_HOPLIMIT_MASK, in ehca_create_ah() 124 ah_attr->grh.hop_limit); in ehca_create_ah() 125 av->av.grh.word_0 |= EHCA_BMASK_SET(GRH_NEXTHEADER_MASK, 0x1B); in ehca_create_ah() 144 ah_attr->grh.sgid_index, &gid); in ehca_create_ah() 152 memcpy(&av->av.grh.word_1, &gid, sizeof(gid)); in ehca_create_ah() [all …]
|
D | ehca_qp.c | 1515 mqpcb->source_gid_idx = attr->ah_attr.grh.sgid_index; in internal_modify_qp() 1521 attr->ah_attr.grh.dgid.raw[cnt]; in internal_modify_qp() 1524 mqpcb->flow_label = attr->ah_attr.grh.flow_label; in internal_modify_qp() 1526 mqpcb->hop_limit = attr->ah_attr.grh.hop_limit; in internal_modify_qp() 1528 mqpcb->traffic_class = attr->ah_attr.grh.traffic_class; in internal_modify_qp() 1631 attr->alt_ah_attr.grh.dgid.raw[cnt]; in internal_modify_qp() 1633 attr->alt_ah_attr.grh.sgid_index; in internal_modify_qp() 1634 mqpcb->flow_label_al = attr->alt_ah_attr.grh.flow_label; in internal_modify_qp() 1635 mqpcb->hop_limit_al = attr->alt_ah_attr.grh.hop_limit; in internal_modify_qp() 1637 attr->alt_ah_attr.grh.traffic_class; in internal_modify_qp() [all …]
|
/drivers/infiniband/hw/ocrdma/ |
D | ocrdma_ah.c | 64 struct ocrdma_grh grh; in set_av_attr() local 68 memset(&grh, 0, sizeof(grh)); in set_av_attr() 95 ah->sgid_index = attr->grh.sgid_index; in set_av_attr() 96 memcpy(&grh.sgid[0], sgid->raw, sizeof(union ib_gid)); in set_av_attr() 97 memcpy(&grh.dgid[0], attr->grh.dgid.raw, sizeof(attr->grh.dgid.raw)); in set_av_attr() 99 grh.tclass_flow = cpu_to_be32((6 << 28) | in set_av_attr() 100 (attr->grh.traffic_class << 24) | in set_av_attr() 101 attr->grh.flow_label); in set_av_attr() 103 grh.pdid_hoplimit = cpu_to_be32((pdid << 16) | in set_av_attr() 104 (0x1b << 8) | attr->grh.hop_limit); in set_av_attr() [all …]
|
/drivers/infiniband/hw/mlx4/ |
D | ah.c | 53 ah->av.ib.gid_index = ah_attr->grh.sgid_index; in create_ib_ah() 54 ah->av.ib.hop_limit = ah_attr->grh.hop_limit; in create_ib_ah() 56 cpu_to_be32((ah_attr->grh.traffic_class << 20) | in create_ib_ah() 57 ah_attr->grh.flow_label); in create_ib_ah() 58 memcpy(ah->av.ib.dgid, ah_attr->grh.dgid.raw, 16); in create_ib_ah() 84 memcpy(&in6, ah_attr->grh.dgid.raw, sizeof(in6)); in create_iboe_ah() 92 ah_attr->grh.sgid_index, &sgid, &gid_attr); in create_iboe_ah() 105 ret = mlx4_ib_gid_index_to_real_index(ibdev, ah_attr->port_num, ah_attr->grh.sgid_index); in create_iboe_ah() 110 ah->av.eth.hop_limit = ah_attr->grh.hop_limit; in create_iboe_ah() 118 cpu_to_be32((ah_attr->grh.traffic_class << 20) | in create_iboe_ah() [all …]
|
D | mad.c | 68 struct ib_grh grh; member 77 struct ib_grh grh; member 84 struct ib_grh grh; member 151 u8 grh[40]; in mlx4_MAD_IFC() member 165 memcpy(ext_info->grh, in_grh, 40); in mlx4_MAD_IFC() 457 struct ib_grh *grh, struct ib_mad *mad) in mlx4_ib_send_to_slave() argument 513 memcpy(&attr.grh.dgid.raw[0], &grh->dgid.raw[0], 16); in mlx4_ib_send_to_slave() 541 if (grh) in mlx4_ib_send_to_slave() 542 memcpy(&tun_mad->grh, grh, sizeof *grh); in mlx4_ib_send_to_slave() 548 tun_mad->hdr.g_ml_path = (grh && (wc->wc_flags & IB_WC_GRH)) ? 0x80 : 0; in mlx4_ib_send_to_slave() [all …]
|
D | qp.c | 1327 ah->grh.sgid_index); in _mlx4_set_path() 1337 path->hop_limit = ah->grh.hop_limit; in _mlx4_set_path() 1339 cpu_to_be32((ah->grh.traffic_class << 20) | in _mlx4_set_path() 1340 (ah->grh.flow_label)); in _mlx4_set_path() 1341 memcpy(path->rgid, ah->grh.dgid.raw, 16); in _mlx4_set_path() 1661 int index = attr->ah_attr.grh.sgid_index; in __mlx4_ib_modify_qp() 2335 sqp->ud_header.grh.traffic_class = in build_mlx_header() 2337 sqp->ud_header.grh.flow_label = in build_mlx_header() 2339 sqp->ud_header.grh.hop_limit = ah->av.ib.hop_limit; in build_mlx_header() 2341 memcpy(sqp->ud_header.grh.source_gid.raw, sgid.raw, 16); in build_mlx_header() [all …]
|
/drivers/infiniband/hw/mlx5/ |
D | ah.c | 39 memcpy(ah->av.rgid, &ah_attr->grh.dgid, 16); in create_ib_ah() 40 ah->av.grh_gid_fl = cpu_to_be32(ah_attr->grh.flow_label | in create_ib_ah() 42 ah_attr->grh.sgid_index << 20); in create_ib_ah() 43 ah->av.hop_limit = ah_attr->grh.hop_limit; in create_ib_ah() 44 ah->av.tclass = ah_attr->grh.traffic_class; in create_ib_ah() 75 ah_attr->grh.sgid_index = (tmp >> 20) & 0xff; in mlx5_ib_query_ah() 76 ah_attr->grh.flow_label = tmp & 0xfffff; in mlx5_ib_query_ah() 77 memcpy(&ah_attr->grh.dgid, ah->av.rgid, 16); in mlx5_ib_query_ah() 78 ah_attr->grh.hop_limit = ah->av.hop_limit; in mlx5_ib_query_ah() 79 ah_attr->grh.traffic_class = ah->av.tclass; in mlx5_ib_query_ah()
|
/drivers/infiniband/core/ |
D | ud_header.c | 120 { STRUCT_FIELD(grh, ip_version), 124 { STRUCT_FIELD(grh, traffic_class), 128 { STRUCT_FIELD(grh, flow_label), 132 { STRUCT_FIELD(grh, payload_length), 136 { STRUCT_FIELD(grh, next_header), 140 { STRUCT_FIELD(grh, hop_limit), 144 { STRUCT_FIELD(grh, source_gid), 148 { STRUCT_FIELD(grh, destination_gid), 256 header->grh.ip_version = 6; in ib_ud_header_init() 257 header->grh.payload_length = in ib_ud_header_init() [all …]
|
D | uverbs_marshall.c | 39 memcpy(dst->grh.dgid, src->grh.dgid.raw, sizeof src->grh.dgid); in ib_copy_ah_attr_to_user() 40 dst->grh.flow_label = src->grh.flow_label; in ib_copy_ah_attr_to_user() 41 dst->grh.sgid_index = src->grh.sgid_index; in ib_copy_ah_attr_to_user() 42 dst->grh.hop_limit = src->grh.hop_limit; in ib_copy_ah_attr_to_user() 43 dst->grh.traffic_class = src->grh.traffic_class; in ib_copy_ah_attr_to_user() 44 memset(&dst->grh.reserved, 0, sizeof(dst->grh.reserved)); in ib_copy_ah_attr_to_user()
|
D | verbs.c | 344 const struct ib_wc *wc, const struct ib_grh *grh, in ib_init_ah_from_wc() argument 361 ret = rdma_addr_find_dmac_by_grh(&grh->dgid, &grh->sgid, in ib_init_ah_from_wc() 371 &grh->dgid, &gid_index); in ib_init_ah_from_wc() 386 ah_attr->grh.dgid = grh->sgid; in ib_init_ah_from_wc() 389 ret = ib_find_cached_gid_by_port(device, &grh->dgid, in ib_init_ah_from_wc() 396 ah_attr->grh.sgid_index = (u8) gid_index; in ib_init_ah_from_wc() 397 flow_class = be32_to_cpu(grh->version_tclass_flow); in ib_init_ah_from_wc() 398 ah_attr->grh.flow_label = flow_class & 0xFFFFF; in ib_init_ah_from_wc() 399 ah_attr->grh.hop_limit = 0xFF; in ib_init_ah_from_wc() 400 ah_attr->grh.traffic_class = (flow_class >> 20) & 0xFF; in ib_init_ah_from_wc() [all …]
|
D | user_mad.c | 241 mad_recv_wc->wc, mad_recv_wc->recv_buf.grh, in recv_handler() 244 packet->mad.hdr.gid_index = ah_attr.grh.sgid_index; in recv_handler() 245 packet->mad.hdr.hop_limit = ah_attr.grh.hop_limit; in recv_handler() 246 packet->mad.hdr.traffic_class = ah_attr.grh.traffic_class; in recv_handler() 247 memcpy(packet->mad.hdr.gid, &ah_attr.grh.dgid, 16); in recv_handler() 248 packet->mad.hdr.flow_label = cpu_to_be32(ah_attr.grh.flow_label); in recv_handler() 503 memcpy(ah_attr.grh.dgid.raw, packet->mad.hdr.gid, 16); in ib_umad_write() 504 ah_attr.grh.sgid_index = packet->mad.hdr.gid_index; in ib_umad_write() 505 ah_attr.grh.flow_label = be32_to_cpu(packet->mad.hdr.flow_label); in ib_umad_write() 506 ah_attr.grh.hop_limit = packet->mad.hdr.hop_limit; in ib_umad_write() [all …]
|
D | uverbs_cmd.c | 2220 memcpy(resp.dest.dgid, attr->ah_attr.grh.dgid.raw, 16); in ib_uverbs_query_qp() 2221 resp.dest.flow_label = attr->ah_attr.grh.flow_label; in ib_uverbs_query_qp() 2222 resp.dest.sgid_index = attr->ah_attr.grh.sgid_index; in ib_uverbs_query_qp() 2223 resp.dest.hop_limit = attr->ah_attr.grh.hop_limit; in ib_uverbs_query_qp() 2224 resp.dest.traffic_class = attr->ah_attr.grh.traffic_class; in ib_uverbs_query_qp() 2232 memcpy(resp.alt_dest.dgid, attr->alt_ah_attr.grh.dgid.raw, 16); in ib_uverbs_query_qp() 2233 resp.alt_dest.flow_label = attr->alt_ah_attr.grh.flow_label; in ib_uverbs_query_qp() 2234 resp.alt_dest.sgid_index = attr->alt_ah_attr.grh.sgid_index; in ib_uverbs_query_qp() 2235 resp.alt_dest.hop_limit = attr->alt_ah_attr.grh.hop_limit; in ib_uverbs_query_qp() 2236 resp.alt_dest.traffic_class = attr->alt_ah_attr.grh.traffic_class; in ib_uverbs_query_qp() [all …]
|
D | agent.c | 81 void agent_send_response(const struct ib_mad_hdr *mad_hdr, const struct ib_grh *grh, in agent_send_response() argument 102 ah = ib_create_ah_from_wc(agent->qp->pd, wc, grh, port_num); in agent_send_response()
|
D | mad.c | 1888 attr.grh.sgid_index, &sgid, NULL)) in rcv_has_same_gid() 1890 return !memcmp(sgid.raw, rwc->recv_buf.grh->dgid.raw, in rcv_has_same_gid() 1898 return !memcmp(attr.grh.dgid.raw, rwc->recv_buf.grh->sgid.raw, in rcv_has_same_gid() 2055 response->header.recv_wc.recv_buf.grh = &response->grh; in handle_ib_smi() 2058 &response->grh, wc, in handle_ib_smi() 2082 response->header.recv_wc.recv_buf.grh = &response->grh; in generate_unmatched_resp() 2143 response->header.recv_wc.recv_buf.grh = &response->grh; in handle_opa_smi() 2146 &response->grh, wc, in handle_opa_smi() 2220 recv->header.recv_wc.recv_buf.grh = &recv->grh; in ib_mad_recv_done_handler() 2254 wc, &recv->grh, in ib_mad_recv_done_handler() [all …]
|
D | agent.h | 47 extern void agent_send_response(const struct ib_mad_hdr *mad_hdr, const struct ib_grh *grh,
|
D | multicast.c | 738 ah_attr->grh.dgid = rec->mgid; in ib_init_ah_from_mcmember() 740 ah_attr->grh.sgid_index = (u8) gid_index; in ib_init_ah_from_mcmember() 741 ah_attr->grh.flow_label = be32_to_cpu(rec->flow_label); in ib_init_ah_from_mcmember() 742 ah_attr->grh.hop_limit = rec->hop_limit; in ib_init_ah_from_mcmember() 743 ah_attr->grh.traffic_class = rec->traffic_class; in ib_init_ah_from_mcmember()
|
/drivers/infiniband/hw/mthca/ |
D | mthca_av.c | 210 ah_attr->grh.sgid_index; in mthca_create_ah() 211 av->hop_limit = ah_attr->grh.hop_limit; in mthca_create_ah() 213 cpu_to_be32((ah_attr->grh.traffic_class << 20) | in mthca_create_ah() 214 ah_attr->grh.flow_label); in mthca_create_ah() 215 memcpy(av->dgid, ah_attr->grh.dgid.raw, 16); in mthca_create_ah() 276 header->grh.traffic_class = in mthca_read_ah() 278 header->grh.flow_label = in mthca_read_ah() 280 header->grh.hop_limit = ah->av->hop_limit; in mthca_read_ah() 284 &header->grh.source_gid, NULL); in mthca_read_ah() 285 memcpy(header->grh.destination_gid.raw, in mthca_read_ah() [all …]
|
D | mthca_qp.c | 413 ib_ah_attr->grh.sgid_index = path->mgid_index & (dev->limits.gid_table_len - 1); in to_ib_ah_attr() 414 ib_ah_attr->grh.hop_limit = path->hop_limit; in to_ib_ah_attr() 415 ib_ah_attr->grh.traffic_class = in to_ib_ah_attr() 417 ib_ah_attr->grh.flow_label = in to_ib_ah_attr() 419 memcpy(ib_ah_attr->grh.dgid.raw, in to_ib_ah_attr() 420 path->rgid, sizeof ib_ah_attr->grh.dgid.raw); in to_ib_ah_attr() 523 if (ah->grh.sgid_index >= dev->limits.gid_table_len) { in mthca_path_set() 525 ah->grh.sgid_index, dev->limits.gid_table_len-1); in mthca_path_set() 530 path->mgid_index = ah->grh.sgid_index; in mthca_path_set() 531 path->hop_limit = ah->grh.hop_limit; in mthca_path_set() [all …]
|
/drivers/infiniband/hw/qib/ |
D | qib_ruc.c | 281 guid = get_sguid(ibp, qp->alt_ah_attr.grh.sgid_index); in qib_ruc_check_hdr() 282 if (!gid_ok(&hdr->u.l.grh.dgid, ibp->gid_prefix, guid)) in qib_ruc_check_hdr() 284 if (!gid_ok(&hdr->u.l.grh.sgid, in qib_ruc_check_hdr() 285 qp->alt_ah_attr.grh.dgid.global.subnet_prefix, in qib_ruc_check_hdr() 286 qp->alt_ah_attr.grh.dgid.global.interface_id)) in qib_ruc_check_hdr() 313 qp->remote_ah_attr.grh.sgid_index); in qib_ruc_check_hdr() 314 if (!gid_ok(&hdr->u.l.grh.dgid, ibp->gid_prefix, guid)) in qib_ruc_check_hdr() 316 if (!gid_ok(&hdr->u.l.grh.sgid, in qib_ruc_check_hdr() 317 qp->remote_ah_attr.grh.dgid.global.subnet_prefix, in qib_ruc_check_hdr() 318 qp->remote_ah_attr.grh.dgid.global.interface_id)) in qib_ruc_check_hdr() [all …]
|
D | qib_ud.c | 167 qib_copy_sge(&qp->r_sge, &ah_attr->grh, in qib_ud_loopback() 327 qp->s_hdrwords += qib_make_grh(ibp, &qp->s_hdr->u.l.grh, in qib_make_ud_req() 328 &ah_attr->grh, in qib_make_ud_req() 555 qib_copy_sge(&qp->r_sge, &hdr->u.l.grh, in qib_ud_rcv()
|
/drivers/staging/rdma/hfi1/ |
D | ruc.c | 301 guid = get_sguid(ibp, qp->alt_ah_attr.grh.sgid_index); in hfi1_ruc_check_hdr() 302 if (!gid_ok(&hdr->u.l.grh.dgid, ibp->gid_prefix, guid)) in hfi1_ruc_check_hdr() 304 if (!gid_ok(&hdr->u.l.grh.sgid, in hfi1_ruc_check_hdr() 305 qp->alt_ah_attr.grh.dgid.global.subnet_prefix, in hfi1_ruc_check_hdr() 306 qp->alt_ah_attr.grh.dgid.global.interface_id)) in hfi1_ruc_check_hdr() 333 qp->remote_ah_attr.grh.sgid_index); in hfi1_ruc_check_hdr() 334 if (!gid_ok(&hdr->u.l.grh.dgid, ibp->gid_prefix, guid)) in hfi1_ruc_check_hdr() 336 if (!gid_ok(&hdr->u.l.grh.sgid, in hfi1_ruc_check_hdr() 337 qp->remote_ah_attr.grh.dgid.global.subnet_prefix, in hfi1_ruc_check_hdr() 338 qp->remote_ah_attr.grh.dgid.global.interface_id)) in hfi1_ruc_check_hdr() [all …]
|
D | ud.c | 189 hfi1_copy_sge(&qp->r_sge, &ah_attr->grh, in ud_loopback() 357 qp->s_hdrwords += hfi1_make_grh(ibp, &qp->s_hdr->ibh.u.l.grh, in hfi1_make_ud_req() 358 &ah_attr->grh, in hfi1_make_ud_req() 494 struct ib_grh *grh = &hdr.u.l.grh; in return_cnp() local 496 grh->version_tclass_flow = old_grh->version_tclass_flow; in return_cnp() 497 grh->paylen = cpu_to_be16((hwords - 2 + SIZE_OF_CRC) << 2); in return_cnp() 498 grh->hop_limit = 0xff; in return_cnp() 499 grh->sgid = old_grh->dgid; in return_cnp() 500 grh->dgid = old_grh->sgid; in return_cnp() 663 struct ib_grh *grh = NULL; in hfi1_ud_rcv() local [all …]
|
D | driver.c | 292 if (hdr->u.l.grh.next_hdr != IB_GRH_NEXT_HDR) in rcv_hdrerr() 294 vtf = be32_to_cpu(hdr->u.l.grh.version_tclass_flow); in rcv_hdrerr() 444 u64 rhf, struct ib_grh *grh) in process_ecn() argument 476 return_cnp(ibp, qp, src_qpn, pkey, dlid, slid, sc5, grh); in process_ecn() 572 struct ib_grh *grh = NULL; in prescan_rxq() local 592 grh = &hdr->u.l.grh; in prescan_rxq() 613 process_ecn(qp, hdr, ohdr, rhf, grh); in prescan_rxq()
|
/drivers/staging/rdma/ipath/ |
D | ipath_ruc.c | 580 struct ib_global_route *grh, u32 hwords, u32 nwords) in ipath_make_grh() argument 584 (grh->traffic_class << 20) | in ipath_make_grh() 585 grh->flow_label); in ipath_make_grh() 589 hdr->hop_limit = grh->hop_limit; in ipath_make_grh() 593 hdr->dgid = grh->dgid; in ipath_make_grh() 612 qp->s_hdrwords += ipath_make_grh(dev, &qp->s_hdr.u.l.grh, in ipath_make_ruc_header() 613 &qp->remote_ah_attr.grh, in ipath_make_ruc_header()
|
D | ipath_ud.c | 179 ipath_copy_sge(&rsge, &ah_attr->grh, sizeof(struct ib_grh)); in ipath_ud_loopback() 328 qp->s_hdrwords += ipath_make_grh(dev, &qp->s_hdr.u.l.grh, in ipath_make_ud_req() 329 &ah_attr->grh, in ipath_make_ud_req() 547 ipath_copy_sge(&qp->r_sge, &hdr->u.l.grh, in ipath_ud_rcv()
|