Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 103602
b: refs/heads/master
c: 17715e6
h: refs/heads/master
v: v3
  • Loading branch information
David S. Miller committed Jul 18, 2008
1 parent 1592378 commit 5121c54
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 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: 8a34c5dc3a7c6431f1cd94c0904be81b296e08ca
refs/heads/master: 17715e62a5e5c7224e5f906a4b8f9e5084100118
6 changes: 4 additions & 2 deletions trunk/net/sched/sch_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -757,18 +757,20 @@ static void shutdown_scheduler_queue(struct net_device *dev,
struct Qdisc *qdisc_default = _qdisc_default;

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

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

spin_lock(root_lock);
qdisc_destroy(qdisc);
spin_unlock(root_lock);
}
}

void dev_shutdown(struct net_device *dev)
{
qdisc_lock_tree(dev);
netdev_for_each_tx_queue(dev, shutdown_scheduler_queue, &noop_qdisc);
shutdown_scheduler_queue(dev, &dev->rx_queue, NULL);
BUG_TRAP(!timer_pending(&dev->watchdog_timer));
qdisc_unlock_tree(dev);
}

0 comments on commit 5121c54

Please sign in to comment.