Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 108823
b: refs/heads/master
c: 4d8863a
h: refs/heads/master
i:
  108821: 96baf06
  108819: 2a6a77c
  108815: fee289b
v: v3
  • Loading branch information
David S. Miller committed Aug 19, 2008
1 parent 40f9f04 commit 64f10ca
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 25bfcd5a78a377ea4c54a3c21e44590e2fc478a6
refs/heads/master: 4d8863a29c4755a0461cd31b6865026187d6c43a
13 changes: 2 additions & 11 deletions trunk/net/sched/sch_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -638,11 +638,8 @@ static void notify_and_destroy(struct sk_buff *skb, struct nlmsghdr *n, u32 clid
if (new || old)
qdisc_notify(skb, n, clid, old, new);

if (old) {
sch_tree_lock(old);
if (old)
qdisc_destroy(old);
sch_tree_unlock(old);
}
}

/* Graft qdisc "new" to class "classid" of qdisc "parent" or
Expand Down Expand Up @@ -1092,16 +1089,10 @@ static int tc_modify_qdisc(struct sk_buff *skb, struct nlmsghdr *n, void *arg)

graft:
if (1) {
spinlock_t *root_lock;

err = qdisc_graft(dev, p, skb, n, clid, q, NULL);
if (err) {
if (q) {
root_lock = qdisc_root_lock(q);
spin_lock_bh(root_lock);
if (q)
qdisc_destroy(q);
spin_unlock_bh(root_lock);
}
return err;
}
}
Expand Down
6 changes: 0 additions & 6 deletions trunk/net/sched/sch_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -518,8 +518,6 @@ void qdisc_reset(struct Qdisc *qdisc)
}
EXPORT_SYMBOL(qdisc_reset);

/* Under qdisc_lock(qdisc) and BH! */

void qdisc_destroy(struct Qdisc *qdisc)
{
const struct Qdisc_ops *ops = qdisc->ops;
Expand Down Expand Up @@ -712,14 +710,10 @@ static void shutdown_scheduler_queue(struct net_device *dev,
struct Qdisc *qdisc_default = _qdisc_default;

if (qdisc) {
spinlock_t *root_lock = qdisc_lock(qdisc);

dev_queue->qdisc = qdisc_default;
dev_queue->qdisc_sleeping = qdisc_default;

spin_lock_bh(root_lock);
qdisc_destroy(qdisc);
spin_unlock_bh(root_lock);
}
}

Expand Down

0 comments on commit 64f10ca

Please sign in to comment.