Lines Matching refs:portid
215 static void output_aggregate_perfcounters(ib_portid_t * portid, in output_aggregate_perfcounters() argument
254 portid2str(portid), ALL_PORTS, ntohs(cap_mask), buf); in output_aggregate_perfcounters()
320 static void output_aggregate_perfcounters_ext(ib_portid_t * portid, in output_aggregate_perfcounters_ext() argument
387 portid2str(portid), ALL_PORTS, ntohs(cap_mask), cap_mask2, buf); in output_aggregate_perfcounters_ext()
391 uint32_t cap_mask2, ib_portid_t * portid, in dump_perfcounters() argument
398 if (!pma_query_via(pc, portid, port, timeout, in dump_perfcounters()
431 if (!pma_query_via(pc, portid, port, timeout, in dump_perfcounters()
445 portid2str(portid), port, ntohs(cap_mask), in dump_perfcounters()
450 portid2str(portid), port, ntohs(cap_mask), buf); in dump_perfcounters()
455 ib_portid_t * portid, int port) in reset_counters() argument
459 if (!performance_reset_via(pc, portid, port, mask, timeout, in reset_counters()
463 if (!performance_reset_via(pc, portid, port, mask, timeout, in reset_counters()
476 static void common_func(ib_portid_t * portid, int port_num, int mask, in common_func() argument
485 if (!pma_query_via(pc, portid, port_num, ibd_timeout, attr, in common_func()
492 portid2str(portid), port_num, buf); in common_func()
496 if (reset && !performance_reset_via(pc, portid, port, mask, ibd_timeout, in common_func()
501 static void xmt_sl_query(ib_portid_t * portid, int port, int mask) in xmt_sl_query() argument
503 common_func(portid, port, mask, !reset_only, (reset_only || reset), in xmt_sl_query()
508 static void rcv_sl_query(ib_portid_t * portid, int port, int mask) in rcv_sl_query() argument
510 common_func(portid, port, mask, !reset_only, (reset_only || reset), in rcv_sl_query()
515 static void xmt_disc_query(ib_portid_t * portid, int port, int mask) in xmt_disc_query() argument
517 common_func(portid, port, mask, !reset_only, (reset_only || reset), in xmt_disc_query()
522 static void rcv_err_query(ib_portid_t * portid, int port, int mask) in rcv_err_query() argument
524 common_func(portid, port, mask, !reset_only, (reset_only || reset), in rcv_err_query()
566 static uint8_t is_rsfec_mode_active(ib_portid_t * portid, int port, in is_rsfec_mode_active() argument
573 if (!is_port_info_extended_supported(portid, port, srcport)) { in is_rsfec_mode_active()
578 if (!smp_query_via(data, portid, IB_ATTR_PORT_INFO_EXT, port, 0, in is_rsfec_mode_active()
594 static void extended_speeds_query(ib_portid_t * portid, int port, in extended_speeds_query() argument
600 if (is_rsfec_mode_active(portid, port, cap_mask)) in extended_speeds_query()
601 common_func(portid, port, mask, 1, 0, in extended_speeds_query()
606 common_func(portid, port, mask, 1, 0, in extended_speeds_query()
613 !ext_speeds_reset_via(pc, portid, port, ext_mask, ibd_timeout, srcport)) in extended_speeds_query()
617 static void oprcvcounters_query(ib_portid_t * portid, int port, int mask) in oprcvcounters_query() argument
619 common_func(portid, port, mask, !reset_only, (reset_only || reset), in oprcvcounters_query()
624 static void flowctlcounters_query(ib_portid_t * portid, int port, int mask) in flowctlcounters_query() argument
626 common_func(portid, port, mask, !reset_only, (reset_only || reset), in flowctlcounters_query()
631 static void vloppackets_query(ib_portid_t * portid, int port, int mask) in vloppackets_query() argument
633 common_func(portid, port, mask, !reset_only, (reset_only || reset), in vloppackets_query()
638 static void vlopdata_query(ib_portid_t * portid, int port, int mask) in vlopdata_query() argument
640 common_func(portid, port, mask, !reset_only, (reset_only || reset), in vlopdata_query()
645 static void vlxmitflowctlerrors_query(ib_portid_t * portid, int port, int mask) in vlxmitflowctlerrors_query() argument
647 common_func(portid, port, mask, !reset_only, (reset_only || reset), in vlxmitflowctlerrors_query()
652 static void vlxmitcounters_query(ib_portid_t * portid, int port, int mask) in vlxmitcounters_query() argument
654 common_func(portid, port, mask, !reset_only, (reset_only || reset), in vlxmitcounters_query()
659 static void swportvlcong_query(ib_portid_t * portid, int port, int mask) in swportvlcong_query() argument
661 common_func(portid, port, mask, !reset_only, (reset_only || reset), in swportvlcong_query()
666 static void rcvcc_query(ib_portid_t * portid, int port, int mask) in rcvcc_query() argument
668 common_func(portid, port, mask, !reset_only, (reset_only || reset), in rcvcc_query()
673 static void slrcvfecn_query(ib_portid_t * portid, int port, int mask) in slrcvfecn_query() argument
675 common_func(portid, port, mask, !reset_only, (reset_only || reset), in slrcvfecn_query()
680 static void slrcvbecn_query(ib_portid_t * portid, int port, int mask) in slrcvbecn_query() argument
682 common_func(portid, port, mask, !reset_only, (reset_only || reset), in slrcvbecn_query()
687 static void xmitcc_query(ib_portid_t * portid, int port, int mask) in xmitcc_query() argument
689 common_func(portid, port, mask, !reset_only, (reset_only || reset), in xmitcc_query()
694 static void vlxmittimecc_query(ib_portid_t * portid, int port, int mask) in vlxmittimecc_query() argument
696 common_func(portid, port, mask, !reset_only, (reset_only || reset), in vlxmittimecc_query()
701 void dump_portsamples_control(ib_portid_t * portid, int port) in dump_portsamples_control() argument
706 if (!pma_query_via(pc, portid, port, ibd_timeout, in dump_portsamples_control()
711 printf("# PortSamplesControl: %s port %d\n%s", portid2str(portid), in dump_portsamples_control()
805 ib_portid_t portid = { 0 }; in main() local
914 if (resolve_portid_str(ibd_ca, ibd_ca_port, &portid, argv[0], in main()
918 portid.grh_present = 1; in main()
919 memcpy(&portid.gid, &dgid, sizeof(portid.gid)); in main()
922 if (resolve_self(ibd_ca, ibd_ca_port, &portid, &port, 0) < 0) in main()
928 if (!pma_query_via(pc, &portid, port, ibd_timeout, CLASS_PORT_INFO, in main()
944 xmt_sl_query(&portid, port, mask); in main()
949 rcv_sl_query(&portid, port, mask); in main()
954 xmt_disc_query(&portid, port, mask); in main()
959 rcv_err_query(&portid, port, mask); in main()
964 extended_speeds_query(&portid, port, ext_mask, cap_mask); in main()
969 oprcvcounters_query(&portid, port, mask); in main()
974 flowctlcounters_query(&portid, port, mask); in main()
979 vloppackets_query(&portid, port, mask); in main()
984 vlopdata_query(&portid, port, mask); in main()
989 vlxmitflowctlerrors_query(&portid, port, mask); in main()
994 vlxmitcounters_query(&portid, port, mask); in main()
999 swportvlcong_query(&portid, port, mask); in main()
1004 rcvcc_query(&portid, port, mask); in main()
1009 slrcvfecn_query(&portid, port, mask); in main()
1014 slrcvbecn_query(&portid, port, mask); in main()
1019 xmitcc_query(&portid, port, mask); in main()
1024 vlxmittimecc_query(&portid, port, mask); in main()
1029 dump_portsamples_control(&portid, port); in main()
1035 if (!smp_query_via(data, &portid, IB_ATTR_NODE_INFO, 0, 0, in main()
1044 if (!smp_query_via(data, &portid, IB_ATTR_SWITCH_INFO, in main()
1064 &portid, i, (all_ports_loop in main()
1068 output_aggregate_perfcounters(&portid, in main()
1071 output_aggregate_perfcounters_ext(&portid, in main()
1077 cap_mask2, &portid, ports[i], in main()
1081 output_aggregate_perfcounters(&portid, in main()
1084 output_aggregate_perfcounters_ext(&portid, in main()
1089 &portid, port, 0); in main()
1112 reset_counters(extended, ibd_timeout, mask, &portid, i); in main()
1115 reset_counters(extended, ibd_timeout, mask, &portid, ports[i]); in main()
1117 reset_counters(extended, ibd_timeout, mask, &portid, port); in main()