summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/sched/sch_red.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/net/sched/sch_red.c b/net/sched/sch_red.c
index d5e934c33f9..76e8df8447d 100644
--- a/net/sched/sch_red.c
+++ b/net/sched/sch_red.c
@@ -135,7 +135,7 @@ red_dequeue(struct Qdisc* sch)
skb = qdisc_dequeue_head(sch);
- if (skb == NULL)
+ if (skb == NULL && !red_is_idling(&q->parms))
red_start_of_idle_period(&q->parms);
return skb;
@@ -154,7 +154,9 @@ static unsigned int red_drop(struct Qdisc* sch)
return len;
}
- red_start_of_idle_period(&q->parms);
+ if (!red_is_idling(&q->parms))
+ red_start_of_idle_period(&q->parms);
+
return 0;
}