]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/sched/sch_api.c
[NETEM]: avoid excessive requeues
[karo-tx-linux.git] / net / sched / sch_api.c
index b06f20294ac055cc83a6b42c4839b5c801a9fbf6..fcaa4adefc827d495d0f10958ec1a0868cbd1d53 100644 (file)
@@ -298,6 +298,7 @@ static enum hrtimer_restart qdisc_watchdog(struct hrtimer *timer)
                                                 timer);
 
        wd->qdisc->flags &= ~TCQ_F_THROTTLED;
+       smp_wmb();
        netif_schedule(wd->qdisc->dev);
        return HRTIMER_NORESTART;
 }
@@ -315,6 +316,7 @@ void qdisc_watchdog_schedule(struct qdisc_watchdog *wd, psched_time_t expires)
        ktime_t time;
 
        wd->qdisc->flags |= TCQ_F_THROTTLED;
+       smp_wmb();
        time = ktime_set(0, 0);
        time = ktime_add_ns(time, PSCHED_US2NS(expires));
        hrtimer_start(&wd->timer, time, HRTIMER_MODE_ABS);
@@ -325,6 +327,7 @@ void qdisc_watchdog_cancel(struct qdisc_watchdog *wd)
 {
        hrtimer_cancel(&wd->timer);
        wd->qdisc->flags &= ~TCQ_F_THROTTLED;
+       smp_wmb();
 }
 EXPORT_SYMBOL(qdisc_watchdog_cancel);