static void
lane_hdr_print(netdissect_options *ndo, const u_char *bp)
{
- ND_PRINT("lecid:%x ", EXTRACT_BE_U_2(bp));
+ ND_PRINT("lecid:%x ", GET_BE_U_2(bp));
}
/*
{
const struct lane_controlhdr *lec;
+ ndo->ndo_protocol = "lane";
if (caplen < sizeof(struct lane_controlhdr)) {
- ND_PRINT("[|lane]");
+ nd_print_trunc(ndo);
return;
}
lec = (const struct lane_controlhdr *)p;
- if (EXTRACT_BE_U_2(lec->lec_header) == 0xff00) {
+ if (GET_BE_U_2(lec->lec_header) == 0xff00) {
/*
* LE Control.
*/
ND_PRINT("lec: proto %x vers %x %s",
- EXTRACT_U_1(lec->lec_proto),
- EXTRACT_U_1(lec->lec_vers),
- tok2str(lecop2str, "opcode-#%u", EXTRACT_BE_U_2(lec->lec_opcode)));
+ GET_U_1(lec->lec_proto),
+ GET_U_1(lec->lec_vers),
+ tok2str(lecop2str, "opcode-#%u", GET_BE_U_2(lec->lec_opcode)));
return;
}
u_int
lane_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p)
{
+ ndo->ndo_protocol = "lane_if";
lane_print(ndo, p, h->len, h->caplen);
return (sizeof(struct lecdatahdr_8023));