• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/sys/net/altq/

Lines Matching refs:top

126  * top level input function called from ip_input.
136 struct top_cdnr *top;
146 top = ifp->if_snd.altq_cdnr;
162 cb = acc_classify(&top->tc_classifier, m, af);
167 tca = &top->tc_block.cb_action;
170 PKTCNTR_ADD(&top->tc_cnts[tca->tca_code], pktinfo.pkt_len);
210 struct top_cdnr *top;
214 LIST_FOREACH(top, &tcb_list, tc_next)
215 if (top->tc_ifq->altq_ifp == ifp)
216 return (top);
243 cdnr_cballoc(top, type, input_func)
244 struct top_cdnr *top;
281 if (top == NULL)
284 cb->cb_top = top;
297 /* if this isn't top, register the element to the top level cdnr */
298 if (top != NULL)
299 LIST_INSERT_HEAD(&top->tc_elements, cb, cb_next);
313 /* remove from the top level cdnr */
416 * top level traffic conditioner
422 struct top_cdnr *top;
424 if ((top = cdnr_cballoc(NULL, TCETYPE_TOP, NULL)) == NULL)
427 top->tc_ifq = ifq;
428 /* set default action for the top level conditioner */
429 top->tc_block.cb_action.tca_code = TCACODE_PASS;
431 LIST_INSERT_HEAD(&tcb_list, top, tc_next);
433 ifq->altq_cdnr = top;
435 return (top);
439 top_destroy(top)
440 struct top_cdnr *top;
444 if (ALTQ_IS_CNDTNING(top->tc_ifq))
445 ALTQ_CLEAR_CNDTNING(top->tc_ifq);
446 top->tc_ifq->altq_cdnr = NULL;
451 while ((cb = LIST_FIRST(&top->tc_elements)) != NULL) {
458 LIST_REMOVE(top, tc_next);
460 cdnr_cbdestroy(top);
464 LIST_FOREACH(top, &tcb_list, tc_next)
465 if (ALTQ_IS_CNDTNING(top->tc_ifq))
467 if (top == NULL)
478 element_create(top, action)
479 struct top_cdnr *top;
487 if ((cb = cdnr_cballoc(top, TCETYPE_ELEMENT, NULL)) == NULL)
538 tbm_create(top, profile, in_action, out_action)
539 struct top_cdnr *top;
549 if ((tbm = cdnr_cballoc(top, TCETYPE_TBMETER,
614 trtcm_create(top, cmtd_profile, peak_profile,
616 struct top_cdnr *top;
628 if ((tcm = cdnr_cballoc(top, TCETYPE_TRTCM,
742 tswtcm_create(top, cmtd_rate, peak_rate, avg_interval,
744 struct top_cdnr *top;
755 if ((tsw = cdnr_cballoc(top, TCETYPE_TSWTCM,
873 struct top_cdnr *top;
881 if ((top = top_create(&ifp->if_snd)) == NULL)
890 struct top_cdnr *top;
892 if ((top = tcb_lookup(ifname)) == NULL)
895 return top_destroy(top);
902 struct top_cdnr *top;
905 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
908 cb = element_create(top, &ap->action);
920 struct top_cdnr *top;
923 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
939 struct top_cdnr *top;
942 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
948 return acc_add_filter(&top->tc_classifier, &ap->filter,
956 struct top_cdnr *top;
958 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
961 return acc_delete_filter(&top->tc_classifier, ap->filter_handle);
968 struct top_cdnr *top;
971 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
974 tbm = tbm_create(top, &ap->profile, &ap->in_action, &ap->out_action);
1015 struct top_cdnr *top;
1018 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
1021 tcm = trtcm_create(top, &ap->cmtd_profile, &ap->peak_profile,
1078 struct top_cdnr *top;
1081 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
1087 tsw = tswtcm_create(top, ap->cmtd_rate, ap->peak_rate,
1125 struct top_cdnr *top;
1133 if ((top = tcb_lookup(ap->iface.cdnr_ifname)) == NULL)
1137 bcopy(top->tc_cnts, ap->cnts, sizeof(ap->cnts));
1147 LIST_FOREACH(cb, &top->tc_elements, cb_next) {
1225 struct top_cdnr *top;
1228 while ((top = LIST_FIRST(&tcb_list)) != NULL) {
1230 err = top_destroy(top);
1251 struct top_cdnr *top;
1287 if ((top = tcb_lookup(ifacep->cdnr_ifname)) == NULL) {
1295 ALTQ_SET_CNDTNING(top->tc_ifq);
1301 ALTQ_CLEAR_CNDTNING(top->tc_ifq);
1302 LIST_FOREACH(top, &tcb_list, tc_next)
1303 if (ALTQ_IS_CNDTNING(top->tc_ifq))
1305 if (top == NULL)