Lines Matching refs:level
106 int level; /* our level (see above) */ member
236 if (cl->level == 0) in htb_classify()
265 if (!cl->level) in htb_classify()
273 if (!cl || cl->level) in htb_classify()
319 struct rb_node **p = &q->hlevel[cl->level].wait_pq.rb_node, *parent = NULL; in htb_add_to_wait_tree()
326 if (q->near_ev_cache[cl->level] > cl->pq_key) in htb_add_to_wait_tree()
327 q->near_ev_cache[cl->level] = cl->pq_key; in htb_add_to_wait_tree()
339 rb_insert_color(&cl->pq_node, &q->hlevel[cl->level].wait_pq); in htb_add_to_wait_tree()
367 q->row_mask[cl->level] |= mask; in htb_add_class_to_row()
371 htb_add_to_id_tree(&q->hlevel[cl->level].hprio[prio].row, cl, prio); in htb_add_class_to_row()
400 struct htb_level *hlevel = &q->hlevel[cl->level]; in htb_remove_class_from_row()
414 q->row_mask[cl->level] &= ~m; in htb_remove_class_from_row()
595 WARN_ON(cl->level || !cl->leaf.q || !cl->leaf.q->q.qlen); in htb_activate()
700 int level, struct sk_buff *skb) in htb_charge_class() argument
708 if (cl->level >= level) { in htb_charge_class()
709 if (cl->level == level) in htb_charge_class()
724 htb_safe_rb_erase(&cl->pq_node, &q->hlevel[cl->level].wait_pq); in htb_charge_class()
730 if (cl->level) in htb_charge_class()
747 static s64 htb_do_events(struct htb_sched *q, const int level, in htb_do_events() argument
755 struct rb_root *wait_pq = &q->hlevel[level].wait_pq; in htb_do_events()
859 if (!cl->level) in htb_lookup_leaf()
875 const int level) in htb_dequeue_tree() argument
879 struct htb_level *hlevel = &q->hlevel[level]; in htb_dequeue_tree()
900 if ((q->row_mask[level] & (1 << prio)) == 0) in htb_dequeue_tree()
916 htb_next_rb_node(level ? &cl->parent->inner.clprio[prio].ptr: in htb_dequeue_tree()
924 cl->leaf.deficit[level] -= qdisc_pkt_len(skb); in htb_dequeue_tree()
925 if (cl->leaf.deficit[level] < 0) { in htb_dequeue_tree()
926 cl->leaf.deficit[level] += cl->quantum; in htb_dequeue_tree()
927 htb_next_rb_node(level ? &cl->parent->inner.clprio[prio].ptr : in htb_dequeue_tree()
935 htb_charge_class(q, cl, level, skb); in htb_dequeue_tree()
944 int level; in htb_dequeue() local
965 for (level = 0; level < TC_HTB_MAXDEPTH; level++) { in htb_dequeue()
968 s64 event = q->near_ev_cache[level]; in htb_dequeue()
971 event = htb_do_events(q, level, start_at); in htb_dequeue()
974 q->near_ev_cache[level] = event; in htb_dequeue()
980 m = ~q->row_mask[level]; in htb_dequeue()
985 skb = htb_dequeue_tree(q, prio, level); in htb_dequeue()
1008 if (cl->level) in htb_reset()
1256 if (!cl->level && cl->leaf.q) in htb_dump_class()
1271 opt.level = cl->level; in htb_dump_class()
1305 while (p && p->level < cl->level) in htb_offload_aggregate_stats()
1313 if (c->level == 0) { in htb_offload_aggregate_stats()
1333 if (!cl->level && cl->leaf.q) in htb_dump_class_stats()
1342 if (!cl->level) { in htb_dump_class_stats()
1452 if (cl->level) in htb_graft()
1484 return !cl->level ? cl->leaf.q : NULL; in htb_leaf()
1511 WARN_ON(cl->level || !cl->leaf.q || cl->prio_activity); in htb_parent_to_leaf()
1515 &q->hlevel[parent->level].wait_pq); in htb_parent_to_leaf()
1517 parent->level = 0; in htb_parent_to_leaf()
1551 if (cl->level) in htb_destroy_class_offload()
1606 if (!cl->level) { in htb_destroy_class()
1656 if (cl->level) in htb_destroy()
1711 if (!cl->level && htb_parent_last_child(cl)) in htb_delete()
1736 if (!cl->level) in htb_delete()
1748 &q->hlevel[cl->level].wait_pq); in htb_delete()
1843 if (parent && parent->parent && parent->parent->level < 2) { in htb_change_class()
1889 } else if (!(parent && !parent->level)) { in htb_change_class()
1948 if (parent && !parent->level) { in htb_change_class()
1959 parent->level = (parent->parent ? parent->parent->level in htb_change_class()
2027 if (!cl->level) { in htb_change_class()