From b97f4eda02f294f99648ce934323baec3a5f1a86 Mon Sep 17 00:00:00 2001 From: Jarek Poplawski Date: Wed, 23 Jul 2008 21:34:27 -0700 Subject: [PATCH] --- yaml --- r: 105581 b: refs/heads/master c: f867e6af94239a04ec23aeec2fcda5aa58e41db7 h: refs/heads/master i: 105579: a0b49f1f46a1c31e0d28729fdb3fce9b7b238b3a v: v3 --- [refs] | 2 +- trunk/net/sched/sch_sfq.c | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index cd4abf6bdbc4..76fbd49a0027 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 6f75a9b6426e686649ac440c37ec7c249501f9a5 +refs/heads/master: f867e6af94239a04ec23aeec2fcda5aa58e41db7 diff --git a/trunk/net/sched/sch_sfq.c b/trunk/net/sched/sch_sfq.c index 8589da666568..73f53844ce97 100644 --- a/trunk/net/sched/sch_sfq.c +++ b/trunk/net/sched/sch_sfq.c @@ -536,7 +536,14 @@ static int sfq_dump(struct Qdisc *sch, struct sk_buff *skb) opt.limit = q->limit; opt.divisor = SFQ_HASH_DIVISOR; - opt.flows = q->limit; + opt.flows = 0; + if (q->tail != SFQ_DEPTH) { + unsigned int i; + + for (i = 0; i < SFQ_HASH_DIVISOR; i++) + if (q->ht[i] != SFQ_DEPTH) + opt.flows++; + } NLA_PUT(skb, TCA_OPTIONS, sizeof(opt), &opt);