aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/sch_generic.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sched/sch_generic.c')
-rw-r--r--net/sched/sch_generic.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
index 468574682caa..ff1c4557e5f8 100644
--- a/net/sched/sch_generic.c
+++ b/net/sched/sch_generic.c
@@ -597,6 +597,9 @@ static void transition_one_qdisc(struct net_device *dev,
597 struct Qdisc *new_qdisc = dev_queue->qdisc_sleeping; 597 struct Qdisc *new_qdisc = dev_queue->qdisc_sleeping;
598 int *need_watchdog_p = _need_watchdog; 598 int *need_watchdog_p = _need_watchdog;
599 599
600 if (!(new_qdisc->flags & TCQ_F_BUILTIN))
601 clear_bit(__QDISC_STATE_DEACTIVATED, &new_qdisc->state);
602
600 rcu_assign_pointer(dev_queue->qdisc, new_qdisc); 603 rcu_assign_pointer(dev_queue->qdisc, new_qdisc);
601 if (need_watchdog_p && new_qdisc != &noqueue_qdisc) 604 if (need_watchdog_p && new_qdisc != &noqueue_qdisc)
602 *need_watchdog_p = 1; 605 *need_watchdog_p = 1;
@@ -640,6 +643,9 @@ static void dev_deactivate_queue(struct net_device *dev,
640 if (qdisc) { 643 if (qdisc) {
641 spin_lock_bh(qdisc_lock(qdisc)); 644 spin_lock_bh(qdisc_lock(qdisc));
642 645
646 if (!(qdisc->flags & TCQ_F_BUILTIN))
647 set_bit(__QDISC_STATE_DEACTIVATED, &qdisc->state);
648
643 dev_queue->qdisc = qdisc_default; 649 dev_queue->qdisc = qdisc_default;
644 qdisc_reset(qdisc); 650 qdisc_reset(qdisc);
645 651