Lines Matching refs:pinfo
41 struct tc_rsvp_pinfo *pinfo, int dir, int family) in get_addr_and_pi() argument
46 struct tc_rsvp_gpi *pi = dir ? &pinfo->dpi : &pinfo->spi; in get_addr_and_pi()
85 if (pinfo->protocol == 0) in get_addr_and_pi()
86 pinfo->protocol = IPPROTO_AH; in get_addr_and_pi()
97 if (pinfo->protocol == 0) in get_addr_and_pi()
98 pinfo->protocol = IPPROTO_ESP; in get_addr_and_pi()
172 struct tc_rsvp_pinfo pinfo; in rsvp_parse_opt() local
178 memset(&pinfo, 0, sizeof(pinfo)); in rsvp_parse_opt()
198 if (get_addr_and_pi(&argc, &argv, &addr, &pinfo, 1, family)) { in rsvp_parse_opt()
203 if (pinfo.dpi.mask || pinfo.protocol) in rsvp_parse_opt()
210 if (get_addr_and_pi(&argc, &argv, &addr, &pinfo, 0, family)) { in rsvp_parse_opt()
215 if (pinfo.spi.mask || pinfo.protocol) in rsvp_parse_opt()
226 pinfo.protocol = num; in rsvp_parse_opt()
244 pinfo.tunnelid = tid; in rsvp_parse_opt()
262 pinfo.tunnelhdr = tid; in rsvp_parse_opt()
290 addattr_l(n, 4096, TCA_RSVP_PINFO, &pinfo, sizeof(pinfo)); in rsvp_parse_opt()
326 struct tc_rsvp_pinfo *pinfo = NULL; in rsvp_print_opt() local
337 if (RTA_PAYLOAD(tb[TCA_RSVP_PINFO]) < sizeof(*pinfo)) in rsvp_print_opt()
340 pinfo = RTA_DATA(tb[TCA_RSVP_PINFO]); in rsvp_print_opt()
345 if (!pinfo || pinfo->tunnelhdr == 0) in rsvp_print_opt()
348 fprintf(f, "tunnel %d skip %d ", rta_getattr_u32(tb[TCA_RSVP_CLASSID]), pinfo->tunnelhdr); in rsvp_print_opt()
349 } else if (pinfo && pinfo->tunnelhdr) in rsvp_print_opt()
350 fprintf(f, "tunnel [BAD] skip %d ", pinfo->tunnelhdr); in rsvp_print_opt()
359 if (pinfo && pinfo->dpi.mask) { in rsvp_print_opt()
361 fprintf(f, "%s ", sprint_spi(&pinfo->dpi, 1, b2)); in rsvp_print_opt()
365 if (pinfo && pinfo->dpi.mask) { in rsvp_print_opt()
367 fprintf(f, "session [NONE]%s ", sprint_spi(&pinfo->dpi, 1, b2)); in rsvp_print_opt()
372 if (pinfo && pinfo->protocol) { in rsvp_print_opt()
374 fprintf(f, "ipproto %s ", inet_proto_n2a(pinfo->protocol, b1, sizeof(b1))); in rsvp_print_opt()
376 if (pinfo && pinfo->tunnelid) in rsvp_print_opt()
377 fprintf(f, "tunnelid %d ", pinfo->tunnelid); in rsvp_print_opt()
386 if (pinfo && pinfo->spi.mask) { in rsvp_print_opt()
388 fprintf(f, "%s ", sprint_spi(&pinfo->spi, 0, b2)); in rsvp_print_opt()
391 } else if (pinfo && pinfo->spi.mask) { in rsvp_print_opt()
393 fprintf(f, "sender [NONE]%s ", sprint_spi(&pinfo->spi, 0, b2)); in rsvp_print_opt()