/linux-4.4.14/drivers/infiniband/core/ |
H A D | ud_header.c | 47 { STRUCT_FIELD(lrh, virtual_lane), 51 { STRUCT_FIELD(lrh, link_version), 55 { STRUCT_FIELD(lrh, service_level), 63 { STRUCT_FIELD(lrh, link_next_header), 67 { STRUCT_FIELD(lrh, destination_lid), 75 { STRUCT_FIELD(lrh, packet_length), 79 { STRUCT_FIELD(lrh, source_lid), 239 header->lrh.link_version = 0; ib_ud_header_init() 240 header->lrh.link_next_header = ib_ud_header_init() 249 header->lrh.packet_length = cpu_to_be16(packet_length); ib_ud_header_init() 296 &header->lrh, buf + len); ib_ud_header_pack() 344 buf, &header->lrh); ib_ud_header_unpack() 347 if (header->lrh.link_version != 0) { ib_ud_header_unpack() 349 header->lrh.link_version); ib_ud_header_unpack() 353 switch (header->lrh.link_next_header) { ib_ud_header_unpack() 378 header->lrh.link_next_header); ib_ud_header_unpack()
|
/linux-4.4.14/drivers/infiniband/hw/qib/ |
H A D | qib_ud.c | 352 qp->s_hdr->lrh[0] = cpu_to_be16(lrh0); qib_make_ud_req() 353 qp->s_hdr->lrh[1] = cpu_to_be16(ah_attr->dlid); /* DEST LID */ qib_make_ud_req() 354 qp->s_hdr->lrh[2] = cpu_to_be16(qp->s_hdrwords + nwords + SIZE_OF_CRC); qib_make_ud_req() 358 qp->s_hdr->lrh[3] = cpu_to_be16(lid); qib_make_ud_req() 360 qp->s_hdr->lrh[3] = IB_LID_PERMISSIVE; qib_make_ud_req() 466 if (unlikely(hdr->lrh[1] == IB_LID_PERMISSIVE || qib_ud_rcv() 467 hdr->lrh[3] == IB_LID_PERMISSIVE)) qib_ud_rcv() 477 (be16_to_cpu(hdr->lrh[0]) >> 4) & qib_ud_rcv() 480 hdr->lrh[3], hdr->lrh[1]); qib_ud_rcv() 486 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, qib_ud_rcv() 488 hdr->lrh[3], hdr->lrh[1]); qib_ud_rcv() 494 (be16_to_cpu(hdr->lrh[0]) >> 12) == 15))) qib_ud_rcv() 500 if (tlen != 256 || (be16_to_cpu(hdr->lrh[0]) >> 12) != 15) qib_ud_rcv() 503 if ((hdr->lrh[1] == IB_LID_PERMISSIVE || qib_ud_rcv() 504 hdr->lrh[3] == IB_LID_PERMISSIVE) && qib_ud_rcv() 573 wc.slid = be16_to_cpu(hdr->lrh[3]); qib_ud_rcv() 574 wc.sl = (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF; qib_ud_rcv() 575 dlid = be16_to_cpu(hdr->lrh[1]); qib_ud_rcv()
|
H A D | qib_ruc.c | 293 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, qib_ruc_check_hdr() 295 hdr->lrh[3], hdr->lrh[1]); qib_ruc_check_hdr() 299 if (be16_to_cpu(hdr->lrh[3]) != qp->alt_ah_attr.dlid || qib_ruc_check_hdr() 325 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, qib_ruc_check_hdr() 327 hdr->lrh[3], hdr->lrh[1]); qib_ruc_check_hdr() 331 if (be16_to_cpu(hdr->lrh[3]) != qp->remote_ah_attr.dlid || qib_ruc_check_hdr() 695 qp->s_hdr->lrh[0] = cpu_to_be16(lrh0); qib_make_ruc_header() 696 qp->s_hdr->lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); qib_make_ruc_header() 697 qp->s_hdr->lrh[2] = cpu_to_be16(qp->s_hdrwords + nwords + SIZE_OF_CRC); qib_make_ruc_header() 698 qp->s_hdr->lrh[3] = cpu_to_be16(ppd_from_ibp(ibp)->lid | qib_make_ruc_header()
|
H A D | qib_driver.c | 311 u16 lid = be16_to_cpu(hdr->lrh[1]); qib_rcv_hdrerr() 312 int lnh = be16_to_cpu(hdr->lrh[0]) & 3; qib_rcv_hdrerr() 495 u16 lrh_len = be16_to_cpu(hdr->lrh[2]) << 2; qib_kreceive()
|
H A D | qib_user_sdma.c | 453 hdr->lrh[2] = cpu_to_be16(le16_to_cpu(pbc16[0])); qib_user_sdma_page_to_frags() 471 be16_to_cpu(hdr->lrh[2]) - qib_user_sdma_page_to_frags() 499 hdr->lrh[2] = cpu_to_be16(le16_to_cpu(pbc16[0])); qib_user_sdma_page_to_frags() 515 be16_to_cpu(hdr->lrh[2]) - qib_user_sdma_page_to_frags()
|
H A D | qib_rc.c | 698 hdr.lrh[0] = cpu_to_be16(lrh0); qib_send_rc_ack() 699 hdr.lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); qib_send_rc_ack() 700 hdr.lrh[2] = cpu_to_be16(hwords + SIZE_OF_CRC); qib_send_rc_ack() 701 hdr.lrh[3] = cpu_to_be16(ppd->lid | qp->remote_ah_attr.src_path_bits); qib_send_rc_ack() 984 if ((be16_to_cpu(hdr->lrh[0]) & 3) == QIB_LRH_BTH) qib_rc_send_complete()
|
H A D | qib_verbs.c | 642 lid = be16_to_cpu(hdr->lrh[1]); qib_ib_rcv() 650 lnh = be16_to_cpu(hdr->lrh[0]) & 3; qib_ib_rcv() 1178 be16_to_cpu(hdr->lrh[0]) >> 12); qib_verbs_send_dma() 1302 be16_to_cpu(ibhdr->lrh[0]) >> 12); qib_verbs_send_pio()
|
H A D | qib_common.h | 700 __be16 lrh[4]; member in struct:qib_message_header
|
H A D | qib_verbs.h | 190 __be16 lrh[4]; member in struct:qib_ib_header
|
H A D | qib_iba7322.c | 1434 .lrh[0] = cpu_to_be16(0xF000 | QIB_LRH_BTH), flush_fifo() 1435 .lrh[1] = IB_LID_PERMISSIVE, flush_fifo() 1436 .lrh[2] = cpu_to_be16(hdrwords + SIZE_OF_CRC), flush_fifo() 1437 .lrh[3] = IB_LID_PERMISSIVE, flush_fifo()
|
/linux-4.4.14/drivers/staging/rdma/hfi1/ |
H A D | ud.c | 386 qp->s_hdr->ibh.lrh[0] = cpu_to_be16(lrh0); hfi1_make_ud_req() 387 qp->s_hdr->ibh.lrh[1] = cpu_to_be16(ah_attr->dlid); /* DEST LID */ hfi1_make_ud_req() 388 qp->s_hdr->ibh.lrh[2] = hfi1_make_ud_req() 391 qp->s_hdr->ibh.lrh[3] = IB_LID_PERMISSIVE; hfi1_make_ud_req() 396 qp->s_hdr->ibh.lrh[3] = cpu_to_be16(lid); hfi1_make_ud_req() 398 qp->s_hdr->ibh.lrh[3] = IB_LID_PERMISSIVE; hfi1_make_ud_req() 517 hdr.lrh[0] = cpu_to_be16(lrh0); return_cnp() 518 hdr.lrh[1] = cpu_to_be16(dlid); return_cnp() 519 hdr.lrh[2] = cpu_to_be16(hwords + SIZE_OF_CRC); return_cnp() 520 hdr.lrh[3] = cpu_to_be16(slid); return_cnp() 667 dlid = be16_to_cpu(hdr->lrh[1]); hfi1_ud_rcv() 680 sc5 = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; hfi1_ud_rcv() 697 u16 slid = be16_to_cpu(hdr->lrh[3]); hfi1_ud_rcv() 700 sc5 = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; hfi1_ud_rcv() 720 if (unlikely(hdr->lrh[1] == IB_LID_PERMISSIVE || hfi1_ud_rcv() 721 hdr->lrh[3] == IB_LID_PERMISSIVE)) hfi1_ud_rcv() 728 sc5 = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; hfi1_ud_rcv() 731 slid = be16_to_cpu(hdr->lrh[3]); hfi1_ud_rcv() 741 (be16_to_cpu(hdr->lrh[0]) >> 4) & hfi1_ud_rcv() 744 hdr->lrh[3], hdr->lrh[1]); hfi1_ud_rcv() 756 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, hfi1_ud_rcv() 758 hdr->lrh[3], hdr->lrh[1]); hfi1_ud_rcv() 764 (be16_to_cpu(hdr->lrh[0]) >> 12) == 15))) hfi1_ud_rcv() 769 u16 slid = be16_to_cpu(hdr->lrh[3]); hfi1_ud_rcv() 772 sc5 = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; hfi1_ud_rcv() 780 if ((hdr->lrh[1] == IB_LID_PERMISSIVE || hfi1_ud_rcv() 781 hdr->lrh[3] == IB_LID_PERMISSIVE) && hfi1_ud_rcv() 866 wc.slid = be16_to_cpu(hdr->lrh[3]); hfi1_ud_rcv() 867 sc = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; hfi1_ud_rcv()
|
H A D | trace.h | 377 #define lrh_name(lrh) { HFI1_##lrh, #lrh } 378 #define show_lnh(lrh) \ 379 __print_symbolic(lrh, \ 464 (u8)(be16_to_cpu(hdr->lrh[0]) >> 12); 466 (u8)(be16_to_cpu(hdr->lrh[0]) >> 8) & 0xf; 468 (u8)(be16_to_cpu(hdr->lrh[0]) >> 4) & 0xf; 470 (u8)(be16_to_cpu(hdr->lrh[0]) & 3); 472 be16_to_cpu(hdr->lrh[1]); 475 be16_to_cpu(hdr->lrh[2]); 477 be16_to_cpu(hdr->lrh[3]); 583 __entry->lnh = (u8)(be16_to_cpu(hdr->lrh[0]) & 3); 589 __entry->slid = be16_to_cpu(hdr->lrh[3]); 590 __entry->dlid = be16_to_cpu(hdr->lrh[1]); 593 __entry->sl = (u8)(be16_to_cpu(hdr->lrh[0]) >> 4) & 0xf; 1064 __be32 *lrh = (__be32 *)hdr->lrh; 1074 __entry->lrh0 = be32_to_cpu(lrh[0]); 1075 __entry->lrh1 = be32_to_cpu(lrh[1]);
|
H A D | ruc.c | 310 sc5, be16_to_cpu(hdr->lrh[3])))) { hfi1_ruc_check_hdr() 313 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, hfi1_ruc_check_hdr() 315 hdr->lrh[3], hdr->lrh[1]); hfi1_ruc_check_hdr() 319 if (be16_to_cpu(hdr->lrh[3]) != qp->alt_ah_attr.dlid || hfi1_ruc_check_hdr() 342 sc5, be16_to_cpu(hdr->lrh[3])))) { hfi1_ruc_check_hdr() 345 (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF, hfi1_ruc_check_hdr() 347 hdr->lrh[3], hdr->lrh[1]); hfi1_ruc_check_hdr() 351 if (be16_to_cpu(hdr->lrh[3]) != qp->remote_ah_attr.dlid || hfi1_ruc_check_hdr() 804 qp->s_hdr->ibh.lrh[0] = cpu_to_be16(lrh0); hfi1_make_ruc_header() 805 qp->s_hdr->ibh.lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); hfi1_make_ruc_header() 806 qp->s_hdr->ibh.lrh[2] = hfi1_make_ruc_header() 808 qp->s_hdr->ibh.lrh[3] = cpu_to_be16(ppd_from_ibp(ibp)->lid | hfi1_make_ruc_header()
|
H A D | driver.c | 266 int lnh = be16_to_cpu(rhdr->lrh[0]) & 3; rcv_hdrerr() 277 u16 lid = be16_to_cpu(hdr->lrh[1]); rcv_hdrerr() 378 sc5 = (be16_to_cpu(rhdr->lrh[0]) >> 12) & 0xf; rcv_hdrerr() 398 rlid = be16_to_cpu(rhdr->lrh[3]); rcv_hdrerr() 466 sc5 = (be16_to_cpu(hdr->lrh[0]) >> 12) & 0xf; process_ecn() 473 u16 dlid = be16_to_cpu(hdr->lrh[1]); process_ecn() 474 u16 slid = be16_to_cpu(hdr->lrh[3]); process_ecn() 586 lnh = be16_to_cpu(hdr->lrh[0]) & 3; prescan_rxq()
|
H A D | diag.c | 91 #define HFI1_GET_PKT_LEN(x) (((be16_to_cpu((x)->lrh[2]) & 0x7FF)) << 2) 1257 if (*((u16 *)value) == be16_to_cpu(hdr->lrh[3])) /* matches slid */ hfi1_filter_lid() 1277 if (*((u16 *)value) == be16_to_cpu(hdr->lrh[1])) hfi1_filter_dlid() 1306 if ((be16_to_cpu(hdr->lrh[0]) & 3) == HFI1_LRH_BTH) hfi1_filter_mad_mgmt_class() 1339 if ((be16_to_cpu(hdr->lrh[0]) & 3) == HFI1_LRH_BTH) hfi1_filter_qp_number() 1367 lnh = (be16_to_cpu(hdr->lrh[0]) & 3); hfi1_filter_ibpacket_type() 1399 if ((*((u8 *)value)) == ((be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF)) hfi1_filter_ib_service_level() 1422 lnh = (be16_to_cpu(hdr->lrh[0]) & 3); hfi1_filter_ib_pkey() 1681 vl = be16_to_cpu(ahdr->ibh.lrh[0]) >> 12; snoop_send_pio_handler()
|
H A D | uc.c | 292 u16 rlid = be16_to_cpu(hdr->lrh[3]); hfi1_uc_rcv() 307 u16 slid = be16_to_cpu(hdr->lrh[3]); hfi1_uc_rcv() 308 u16 dlid = be16_to_cpu(hdr->lrh[1]); hfi1_uc_rcv()
|
H A D | user_sdma.c | 583 sc = (((be16_to_cpu(req->hdr.lrh[0]) >> 12) & 0xF) | hfi1_user_sdma_process_request() 597 if ((be16_to_cpu(req->hdr.lrh[0]) & 0x3) == HFI1_LRH_GRH) { hfi1_user_sdma_process_request() 741 len = ((be16_to_cpu(req->hdr.lrh[2]) << 2) - compute_data_length() 1187 hdr->lrh[2] = cpu_to_be16(lrhlen >> 2); set_txreq_header() 1203 req->hdr.lrh[2] = hdr->lrh[2]; set_txreq_header()
|
H A D | trace.c | 57 u8 lnh = (u8)(be16_to_cpu(hdr->lrh[0]) & 3); ibhdr_exhdr_len()
|
H A D | verbs.c | 622 lnh = be16_to_cpu(hdr->lrh[0]) & 3; hfi1_ib_rcv() 645 lid = be16_to_cpu(hdr->lrh[1]); hfi1_ib_rcv() 973 phdr->hdr.lrh[0] = ahdr->ibh.lrh[0]; build_verbs_tx_desc() 974 if ((be16_to_cpu(phdr->hdr.lrh[0]) & 3) == HFI1_LRH_GRH) { build_verbs_tx_desc() 1261 lnh = be16_to_cpu(hdr->lrh[0]) & 3; egress_pkey_check() 1294 u16 slid = be16_to_cpu(hdr->lrh[3]); egress_pkey_check()
|
H A D | common.h | 329 __be16 lrh[4]; member in struct:hfi1_message_header
|
H A D | rc.c | 737 hdr.lrh[0] = cpu_to_be16(lrh0); hfi1_send_rc_ack() 738 hdr.lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); hfi1_send_rc_ack() 739 hdr.lrh[2] = cpu_to_be16(hwords + SIZE_OF_CRC); hfi1_send_rc_ack() 740 hdr.lrh[3] = cpu_to_be16(ppd->lid | qp->remote_ah_attr.src_path_bits); hfi1_send_rc_ack() 997 if ((be16_to_cpu(hdr->lrh[0]) & 3) == HFI1_LRH_BTH) hfi1_rc_send_complete()
|
H A D | verbs.h | 186 __be16 lrh[4]; member in struct:hfi1_ib_header
|
/linux-4.4.14/drivers/staging/rdma/ipath/ |
H A D | ipath_ud.c | 351 qp->s_hdr.lrh[0] = cpu_to_be16(lrh0); ipath_make_ud_req() 352 qp->s_hdr.lrh[1] = cpu_to_be16(ah_attr->dlid); /* DEST LID */ ipath_make_ud_req() 353 qp->s_hdr.lrh[2] = cpu_to_be16(qp->s_hdrwords + nwords + ipath_make_ud_req() 359 qp->s_hdr.lrh[3] = cpu_to_be16(lid); ipath_make_ud_req() 361 qp->s_hdr.lrh[3] = IB_LID_PERMISSIVE; ipath_make_ud_req() 453 if (unlikely(hdr->lrh[1] == IB_LID_PERMISSIVE || ipath_ud_rcv() 454 hdr->lrh[3] == IB_LID_PERMISSIVE)) { ipath_ud_rcv() 464 } else if (hdr->lrh[1] == IB_LID_PERMISSIVE || ipath_ud_rcv() 465 hdr->lrh[3] == IB_LID_PERMISSIVE) { ipath_ud_rcv() 508 (be16_to_cpu(hdr->lrh[0]) >> 12) != 15)) || ipath_ud_rcv() 511 (be16_to_cpu(hdr->lrh[0]) >> 12) == 15)))) { ipath_ud_rcv() 564 wc.slid = be16_to_cpu(hdr->lrh[3]); ipath_ud_rcv() 565 wc.sl = (be16_to_cpu(hdr->lrh[0]) >> 4) & 0xF; ipath_ud_rcv() 566 dlid = be16_to_cpu(hdr->lrh[1]); ipath_ud_rcv()
|
H A D | ipath_ruc.c | 618 qp->s_hdr.lrh[0] = cpu_to_be16(lrh0); ipath_make_ruc_header() 619 qp->s_hdr.lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); ipath_make_ruc_header() 620 qp->s_hdr.lrh[2] = cpu_to_be16(qp->s_hdrwords + nwords + SIZE_OF_CRC); ipath_make_ruc_header() 621 qp->s_hdr.lrh[3] = cpu_to_be16(dev->dd->ipath_lid | ipath_make_ruc_header()
|
H A D | ipath_rc.c | 674 hdr.lrh[0] = cpu_to_be16(lrh0); send_rc_ack() 675 hdr.lrh[1] = cpu_to_be16(qp->remote_ah_attr.dlid); send_rc_ack() 676 hdr.lrh[2] = cpu_to_be16(hwords + SIZE_OF_CRC); send_rc_ack() 677 hdr.lrh[3] = cpu_to_be16(dd->ipath_lid | send_rc_ack() 1586 if (unlikely(be16_to_cpu(hdr->lrh[3]) != qp->remote_ah_attr.dlid)) ipath_rc_rcv()
|
H A D | ipath_uc.c | 254 if (unlikely(be16_to_cpu(hdr->lrh[3]) != qp->remote_ah_attr.dlid)) ipath_uc_rcv()
|
H A D | ipath_verbs.c | 616 lid = be16_to_cpu(hdr->lrh[1]); ipath_ib_rcv() 626 lnh = be16_to_cpu(hdr->lrh[0]) & 3; ipath_ib_rcv() 1161 if ((be16_to_cpu(hdr->lrh[0]) >> 12) == 15) { ipath_verbs_send_dma() 1263 if ((be16_to_cpu(ibhdr->lrh[0]) >> 12) == 15) ipath_verbs_send_pio()
|
H A D | ipath_common.h | 743 __be16 lrh[4]; member in struct:ipath_message_header 752 __be16 lrh[4]; member in struct:ether_header
|
H A D | ipath_verbs.h | 136 __be16 lrh[4]; member in struct:ipath_ib_header
|
/linux-4.4.14/drivers/infiniband/hw/mthca/ |
H A D | mthca_av.c | 272 header->lrh.service_level = be32_to_cpu(ah->av->sl_tclass_flowlabel) >> 28; mthca_read_ah() 273 header->lrh.destination_lid = ah->av->dlid; mthca_read_ah() 274 header->lrh.source_lid = cpu_to_be16(ah->av->g_slid & 0x7f); mthca_read_ah()
|
H A D | mthca_qp.c | 1496 (sqp->ud_header.lrh.destination_lid == build_mlx_header() 1498 (sqp->ud_header.lrh.service_level << 8)); build_mlx_header() 1499 mlx->rlid = sqp->ud_header.lrh.destination_lid; build_mlx_header() 1516 sqp->ud_header.lrh.virtual_lane = !sqp->qp.ibqp.qp_num ? 15 : 0; build_mlx_header() 1517 if (sqp->ud_header.lrh.destination_lid == IB_LID_PERMISSIVE) build_mlx_header() 1518 sqp->ud_header.lrh.source_lid = IB_LID_PERMISSIVE; build_mlx_header()
|
/linux-4.4.14/net/ipv4/ |
H A D | inetpeer.c | 258 int lrh; peer_avl_rebalance() local 261 lrh = node_height(lr); peer_avl_rebalance() 262 if (lrh <= node_height(ll)) { /* ll: RH+1 */ peer_avl_rebalance() 265 node->avl_height = lrh + 1; /* RH+1 or RH+2 */ peer_avl_rebalance()
|
/linux-4.4.14/drivers/infiniband/hw/mlx4/ |
H A D | qp.c | 2174 sqp->ud_header.lrh.service_level = build_sriov_qp0_header() 2176 sqp->ud_header.lrh.destination_lid = build_sriov_qp0_header() 2178 sqp->ud_header.lrh.source_lid = build_sriov_qp0_header() 2186 mlx->rlid = sqp->ud_header.lrh.destination_lid; build_sriov_qp0_header() 2188 sqp->ud_header.lrh.virtual_lane = 0; build_sriov_qp0_header() 2320 sqp->ud_header.lrh.service_level = build_mlx_header() 2322 sqp->ud_header.lrh.destination_lid = ah->av.ib.dlid; build_mlx_header() 2323 sqp->ud_header.lrh.source_lid = cpu_to_be16(ah->av.ib.g_slid & 0x7f); build_mlx_header() 2359 (sqp->ud_header.lrh.destination_lid == build_mlx_header() 2361 (sqp->ud_header.lrh.service_level << 8)); build_mlx_header() 2364 mlx->rlid = sqp->ud_header.lrh.destination_lid; build_mlx_header() 2414 sqp->ud_header.lrh.virtual_lane = !sqp->qp.ibqp.qp_num ? 15 : 0; build_mlx_header() 2415 if (sqp->ud_header.lrh.destination_lid == IB_LID_PERMISSIVE) build_mlx_header() 2416 sqp->ud_header.lrh.source_lid = IB_LID_PERMISSIVE; build_mlx_header()
|
/linux-4.4.14/include/rdma/ |
H A D | ib_pack.h | 233 struct ib_unpacked_lrh lrh; member in struct:ib_ud_header
|
/linux-4.4.14/include/uapi/rdma/hfi/ |
H A D | hfi1_user.h | 401 __be16 lrh[4]; member in struct:hfi1_pkt_header
|