diff options
author | David S. Miller <davem@davemloft.net> | 2008-05-15 03:34:44 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-05-15 03:34:44 -0400 |
commit | 63fe46da9c380b3f2bbdf3765044649517cc717c (patch) | |
tree | 9478c1aca1d692b408955aea20c9cd9a37e589c0 /net/sched/sch_htb.c | |
parent | 99dd1a2b8347ac2ae802300b7862f6f7bcf17139 (diff) | |
parent | 066b2118976e6e7cc50eed39e2747c75343a23c4 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
drivers/net/wireless/iwlwifi/iwl-4965-rs.c
drivers/net/wireless/rt2x00/rt61pci.c
Diffstat (limited to 'net/sched/sch_htb.c')
-rw-r--r-- | net/sched/sch_htb.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/net/sched/sch_htb.c b/net/sched/sch_htb.c index 66148cc4759e..5bc1ed490180 100644 --- a/net/sched/sch_htb.c +++ b/net/sched/sch_htb.c | |||
@@ -1197,12 +1197,16 @@ static inline int htb_parent_last_child(struct htb_class *cl) | |||
1197 | return 1; | 1197 | return 1; |
1198 | } | 1198 | } |
1199 | 1199 | ||
1200 | static void htb_parent_to_leaf(struct htb_class *cl, struct Qdisc *new_q) | 1200 | static void htb_parent_to_leaf(struct htb_sched *q, struct htb_class *cl, |
1201 | struct Qdisc *new_q) | ||
1201 | { | 1202 | { |
1202 | struct htb_class *parent = cl->parent; | 1203 | struct htb_class *parent = cl->parent; |
1203 | 1204 | ||
1204 | BUG_TRAP(!cl->level && cl->un.leaf.q && !cl->prio_activity); | 1205 | BUG_TRAP(!cl->level && cl->un.leaf.q && !cl->prio_activity); |
1205 | 1206 | ||
1207 | if (parent->cmode != HTB_CAN_SEND) | ||
1208 | htb_safe_rb_erase(&parent->pq_node, q->wait_pq + parent->level); | ||
1209 | |||
1206 | parent->level = 0; | 1210 | parent->level = 0; |
1207 | memset(&parent->un.inner, 0, sizeof(parent->un.inner)); | 1211 | memset(&parent->un.inner, 0, sizeof(parent->un.inner)); |
1208 | INIT_LIST_HEAD(&parent->un.leaf.drop_list); | 1212 | INIT_LIST_HEAD(&parent->un.leaf.drop_list); |
@@ -1300,7 +1304,7 @@ static int htb_delete(struct Qdisc *sch, unsigned long arg) | |||
1300 | htb_deactivate(q, cl); | 1304 | htb_deactivate(q, cl); |
1301 | 1305 | ||
1302 | if (last_child) | 1306 | if (last_child) |
1303 | htb_parent_to_leaf(cl, new_q); | 1307 | htb_parent_to_leaf(q, cl, new_q); |
1304 | 1308 | ||
1305 | if (--cl->refcnt == 0) | 1309 | if (--cl->refcnt == 0) |
1306 | htb_destroy_class(sch, cl); | 1310 | htb_destroy_class(sch, cl); |