Lines Matching refs:tptr

641                         const u_char *tptr, u_int tlv_len)  in lldp_private_8021_print()  argument
651 subtype = *(tptr+3); in lldp_private_8021_print()
663 EXTRACT_16BITS(tptr + 4))); in lldp_private_8021_print()
670 EXTRACT_16BITS(tptr+5), in lldp_private_8021_print()
671 bittok2str(lldp_8021_port_protocol_id_values, "none", *(tptr+4)), in lldp_private_8021_print()
672 *(tptr + 4))); in lldp_private_8021_print()
678 ND_PRINT((ndo, "\n\t vlan id (VID): %u", EXTRACT_16BITS(tptr + 4))); in lldp_private_8021_print()
682 sublen = *(tptr+6); in lldp_private_8021_print()
687 safeputs(ndo, tptr + 7, sublen); in lldp_private_8021_print()
693 sublen = *(tptr+4); in lldp_private_8021_print()
698 safeputs(ndo, tptr + 5, sublen); in lldp_private_8021_print()
704 tval=*(tptr+4); in lldp_private_8021_print()
710 tval=*(tptr+5); in lldp_private_8021_print()
722 tval=*(tptr+4); in lldp_private_8021_print()
727 print_ets_priority_assignment_table(ndo, tptr + 5); in lldp_private_8021_print()
730 print_tc_bandwidth_table(ndo, tptr + 9); in lldp_private_8021_print()
733 print_tsa_assignment_table(ndo, tptr + 17); in lldp_private_8021_print()
741 ND_PRINT((ndo, "\n\t RES: %d", *(tptr + 4))); in lldp_private_8021_print()
743 print_ets_priority_assignment_table(ndo, tptr + 5); in lldp_private_8021_print()
745 print_tc_bandwidth_table(ndo, tptr + 9); in lldp_private_8021_print()
747 print_tsa_assignment_table(ndo, tptr + 17); in lldp_private_8021_print()
754 tval=*(tptr+4); in lldp_private_8021_print()
758 tval=*(tptr+5); in lldp_private_8021_print()
769 ND_PRINT((ndo, "\n\t RES: %d", *(tptr + 4))); in lldp_private_8021_print()
781 tval=*(tptr+i+5); in lldp_private_8021_print()
784 ND_PRINT((ndo, "Protocol ID: %d", EXTRACT_16BITS(tptr + i + 5))); in lldp_private_8021_print()
793 tval=*(tptr+4); in lldp_private_8021_print()
797 tval=*(tptr+5); in lldp_private_8021_print()
800 tval=*(tptr+6); in lldp_private_8021_print()
802 tval=*(tptr+7); in lldp_private_8021_print()
806 tval=*(tptr+8); in lldp_private_8021_print()
814 tval=*(tptr+4); in lldp_private_8021_print()
817 ND_PRINT((ndo, "ChnCap: %d", EXTRACT_16BITS(tptr + 6) & 0x0fff)); in lldp_private_8021_print()
824 tval=EXTRACT_24BITS(tptr+i+8); in lldp_private_8021_print()
844 const u_char *tptr, u_int tlv_len) in lldp_private_8023_print() argument
851 subtype = *(tptr+3); in lldp_private_8023_print()
863 bittok2str(lldp_8023_autonegotiation_values, "none", *(tptr+4)), in lldp_private_8023_print()
864 *(tptr + 4))); in lldp_private_8023_print()
866 bittok2str(lldp_pmd_capability_values,"unknown", EXTRACT_16BITS(tptr+5)), in lldp_private_8023_print()
867 EXTRACT_16BITS(tptr + 5))); in lldp_private_8023_print()
869 tok2str(lldp_mau_types_values, "unknown", EXTRACT_16BITS(tptr+7)), in lldp_private_8023_print()
870 EXTRACT_16BITS(tptr + 7))); in lldp_private_8023_print()
878 bittok2str(lldp_mdi_values, "none", *(tptr+4)), in lldp_private_8023_print()
879 tok2str(lldp_mdi_power_pairs_values, "unknown", *(tptr+5)), in lldp_private_8023_print()
880 tok2str(lldp_mdi_power_class_values, "unknown", *(tptr + 6)))); in lldp_private_8023_print()
888 bittok2str(lldp_aggregation_values, "none", *(tptr+4)), in lldp_private_8023_print()
889 EXTRACT_32BITS(tptr + 5))); in lldp_private_8023_print()
893 ND_PRINT((ndo, "\n\t MTU size %u", EXTRACT_16BITS(tptr + 4))); in lldp_private_8023_print()
908 lldp_extract_latlon(const u_char *tptr) in lldp_extract_latlon() argument
912 latlon = *tptr & 0x3; in lldp_extract_latlon()
913 latlon = (latlon << 32) | EXTRACT_32BITS(tptr+1); in lldp_extract_latlon()
923 const u_char *tptr, u_int tlv_len) in lldp_private_tia_print() argument
934 subtype = *(tptr+3); in lldp_private_tia_print()
947 EXTRACT_16BITS(tptr + 4)), EXTRACT_16BITS(tptr + 4))); in lldp_private_tia_print()
949 tok2str(lldp_tia_device_type_values, "unknown", *(tptr+6)), in lldp_private_tia_print()
950 *(tptr + 6))); in lldp_private_tia_print()
958 tok2str(lldp_tia_application_type_values, "none", *(tptr+4)), in lldp_private_tia_print()
959 *(tptr + 4))); in lldp_private_tia_print()
961 lldp_tia_network_policy_bits_values, "none", *(tptr + 5)))); in lldp_private_tia_print()
963 LLDP_EXTRACT_NETWORK_POLICY_VLAN(EXTRACT_16BITS(tptr + 5)))); in lldp_private_tia_print()
965 LLDP_EXTRACT_NETWORK_POLICY_L2_PRIORITY(EXTRACT_16BITS(tptr + 6)))); in lldp_private_tia_print()
967 LLDP_EXTRACT_NETWORK_POLICY_DSCP(EXTRACT_16BITS(tptr + 6)))); in lldp_private_tia_print()
974 location_format = *(tptr+4); in lldp_private_tia_print()
985 (*(tptr + 5) >> 2), lldp_extract_latlon(tptr + 5))); in lldp_private_tia_print()
987 (*(tptr + 10) >> 2), lldp_extract_latlon(tptr + 10))); in lldp_private_tia_print()
989 tok2str(lldp_tia_location_altitude_type_values, "unknown",(*(tptr+15)>>4)), in lldp_private_tia_print()
990 (*(tptr + 15) >> 4))); in lldp_private_tia_print()
992 (EXTRACT_16BITS(tptr+15)>>6)&0x3f, in lldp_private_tia_print()
993 ((EXTRACT_32BITS(tptr + 16) & 0x3fffffff)))); in lldp_private_tia_print()
995 tok2str(lldp_tia_location_datum_type_values, "unknown", *(tptr+20)), in lldp_private_tia_print()
996 *(tptr + 20))); in lldp_private_tia_print()
1003 lci_len = *(tptr+5); in lldp_private_tia_print()
1012 tok2str(lldp_tia_location_lci_what_values, "unknown", *(tptr+6)), in lldp_private_tia_print()
1013 *(tptr + 6))); in lldp_private_tia_print()
1016 safeputs(ndo, tptr + 7, 2); in lldp_private_tia_print()
1019 tptr = tptr + 9; in lldp_private_tia_print()
1026 ca_type = *(tptr); in lldp_private_tia_print()
1027 ca_len = *(tptr+1); in lldp_private_tia_print()
1029 tptr += 2; in lldp_private_tia_print()
1044 safeputs(ndo, tptr, ca_len); in lldp_private_tia_print()
1045 tptr += ca_len; in lldp_private_tia_print()
1052 safeputs(ndo, tptr + 5, tlv_len - 5); in lldp_private_tia_print()
1057 print_unknown_data(ndo, tptr + 5, "\n\t ", tlv_len - 5); in lldp_private_tia_print()
1066 (*(tptr + 4) & 0xC0 >> 6) ? "PD device" : "PSE device")); in lldp_private_tia_print()
1068 tok2str(lldp_tia_power_source_values, "none", (*(tptr + 4) & 0x30) >> 4))); in lldp_private_tia_print()
1070 tok2str(lldp_tia_power_priority_values, "none", *(tptr+4)&0x0f), in lldp_private_tia_print()
1071 *(tptr + 4) & 0x0f)); in lldp_private_tia_print()
1072 power_val = EXTRACT_16BITS(tptr+5); in lldp_private_tia_print()
1089 safeputs(ndo, tptr + 4, tlv_len - 4); in lldp_private_tia_print()
1112 const u_char *tptr, *mptr; in lldp_private_dcbx_print() local
1127 tptr = pptr + 4; in lldp_private_dcbx_print()
1132 ND_TCHECK2(*tptr, sizeof(tlv)); in lldp_private_dcbx_print()
1134 tlv = EXTRACT_16BITS(tptr); in lldp_private_dcbx_print()
1141 tptr += sizeof(tlv); in lldp_private_dcbx_print()
1148 ND_TCHECK2(*tptr, tlv_len); in lldp_private_dcbx_print()
1161 ND_PRINT((ndo, "\n\t Oper_Version: %d", *tptr)); in lldp_private_dcbx_print()
1162 ND_PRINT((ndo, "\n\t Max_Version: %d", *(tptr + 1))); in lldp_private_dcbx_print()
1163 ND_PRINT((ndo, "\n\t Sequence Number: %d", EXTRACT_32BITS(tptr + 2))); in lldp_private_dcbx_print()
1165 EXTRACT_32BITS(tptr + 6))); in lldp_private_dcbx_print()
1173 ND_PRINT((ndo, "\n\t Oper_Version: %d", *tptr)); in lldp_private_dcbx_print()
1174 ND_PRINT((ndo, "\n\t Max_Version: %d", *(tptr + 1))); in lldp_private_dcbx_print()
1175 ND_PRINT((ndo, "\n\t Info block(0x%02X): ", *(tptr + 2))); in lldp_private_dcbx_print()
1176 tval = *(tptr+2); in lldp_private_dcbx_print()
1180 ND_PRINT((ndo, "\n\t SubType: %d", *(tptr + 3))); in lldp_private_dcbx_print()
1187 pgval = EXTRACT_32BITS(tptr+4); in lldp_private_dcbx_print()
1194 ND_PRINT((ndo, "\n\t Pg percentage[%d]: %d", i, *(tptr + 8 + i))); in lldp_private_dcbx_print()
1195 ND_PRINT((ndo, "\n\t NumTCsSupported: %d", *(tptr + 8 + 8))); in lldp_private_dcbx_print()
1204 ND_PRINT((ndo, "\n\t Oper_Version: %d", *tptr)); in lldp_private_dcbx_print()
1205 ND_PRINT((ndo, "\n\t Max_Version: %d", *(tptr + 1))); in lldp_private_dcbx_print()
1206 ND_PRINT((ndo, "\n\t Info block(0x%02X): ", *(tptr + 2))); in lldp_private_dcbx_print()
1207 tval = *(tptr+2); in lldp_private_dcbx_print()
1211 ND_PRINT((ndo, "\n\t SubType: %d", *(tptr + 3))); in lldp_private_dcbx_print()
1212 tval = *(tptr+4); in lldp_private_dcbx_print()
1213 ND_PRINT((ndo, "\n\t PFC Config (0x%02X)", *(tptr + 4))); in lldp_private_dcbx_print()
1217 ND_PRINT((ndo, "\n\t NumTCPFCSupported: %d", *(tptr + 5))); in lldp_private_dcbx_print()
1225 ND_PRINT((ndo, "\n\t Oper_Version: %d", *tptr)); in lldp_private_dcbx_print()
1226 ND_PRINT((ndo, "\n\t Max_Version: %d", *(tptr + 1))); in lldp_private_dcbx_print()
1227 ND_PRINT((ndo, "\n\t Info block(0x%02X): ", *(tptr + 2))); in lldp_private_dcbx_print()
1228 tval = *(tptr+2); in lldp_private_dcbx_print()
1232 ND_PRINT((ndo, "\n\t SubType: %d", *(tptr + 3))); in lldp_private_dcbx_print()
1234 mptr = tptr + 4; in lldp_private_dcbx_print()
1256 print_unknown_data(ndo, tptr, "\n\t ", tlv_len); in lldp_private_dcbx_print()
1260 tptr += tlv_len; in lldp_private_dcbx_print()
1268 lldp_network_addr_print(netdissect_options *ndo, const u_char *tptr, u_int len) in lldp_network_addr_print() argument
1277 af = *tptr; in lldp_network_addr_print()
1306 tok2str(af_values, "Unknown", af), af, (*pfunc)(ndo, tptr+1)); in lldp_network_addr_print()
1317 const u_char *tptr; in lldp_mgmt_addr_tlv_print() local
1322 tptr = pptr; in lldp_mgmt_addr_tlv_print()
1327 mgmt_addr_len = *tptr++; in lldp_mgmt_addr_tlv_print()
1334 mgmt_addr = lldp_network_addr_print(ndo, tptr, mgmt_addr_len); in lldp_mgmt_addr_tlv_print()
1340 tptr += mgmt_addr_len; in lldp_mgmt_addr_tlv_print()
1347 intf_num_subtype = *tptr; in lldp_mgmt_addr_tlv_print()
1351 EXTRACT_32BITS(tptr + 1))); in lldp_mgmt_addr_tlv_print()
1353 tptr += LLDP_INTF_NUM_LEN; in lldp_mgmt_addr_tlv_print()
1360 oid_len = *tptr; in lldp_mgmt_addr_tlv_print()
1367 safeputs(ndo, tptr + 1, oid_len); in lldp_mgmt_addr_tlv_print()
1381 const u_char *tptr; in lldp_print() local
1384 tptr = pptr; in lldp_print()
1391 ND_TCHECK2(*tptr, sizeof(tlv)); in lldp_print()
1393 tlv = EXTRACT_16BITS(tptr); in lldp_print()
1400 tptr += sizeof(tlv); in lldp_print()
1413 ND_TCHECK2(*tptr, tlv_len); in lldp_print()
1425 subtype = *tptr; in lldp_print()
1435 ND_PRINT((ndo, "%s", etheraddr_string(ndo, tptr + 1))); in lldp_print()
1443 safeputs(ndo, tptr + 1, tlv_len - 1); in lldp_print()
1447 network_addr = lldp_network_addr_print(ndo, tptr+1, tlv_len-1); in lldp_print()
1466 subtype = *tptr; in lldp_print()
1476 ND_PRINT((ndo, "%s", etheraddr_string(ndo, tptr + 1))); in lldp_print()
1484 safeputs(ndo, tptr + 1, tlv_len - 1); in lldp_print()
1488 network_addr = lldp_network_addr_print(ndo, tptr+1, tlv_len-1); in lldp_print()
1507 ND_PRINT((ndo, ": TTL %us", EXTRACT_16BITS(tptr))); in lldp_print()
1514 safeputs(ndo, tptr, tlv_len); in lldp_print()
1524 safeputs(ndo, tptr, tlv_len); in lldp_print()
1530 safeputs(ndo, tptr, tlv_len); in lldp_print()
1545 cap = EXTRACT_16BITS(tptr); in lldp_print()
1546 ena_cap = EXTRACT_16BITS(tptr+2); in lldp_print()
1556 if (!lldp_mgmt_addr_tlv_print(ndo, tptr, tlv_len)) { in lldp_print()
1567 oui = EXTRACT_24BITS(tptr); in lldp_print()
1572 hexdump = lldp_private_8021_print(ndo, tptr, tlv_len); in lldp_print()
1575 hexdump = lldp_private_8023_print(ndo, tptr, tlv_len); in lldp_print()
1578 hexdump = lldp_private_tia_print(ndo, tptr, tlv_len); in lldp_print()
1581 hexdump = lldp_private_dcbx_print(ndo, tptr, tlv_len); in lldp_print()
1597 print_unknown_data(ndo, tptr, "\n\t ", tlv_len); in lldp_print()
1601 tptr += tlv_len; in lldp_print()