Cake - FQ_codel the next generation
 help / color / mirror / Atom feed
* [Cake] Dropping dropped
@ 2019-02-14 14:01 Adrian Popescu
  2019-02-14 14:35 ` Toke Høiland-Jørgensen
  2019-02-15 20:45 ` Dave Taht
  0 siblings, 2 replies; 7+ messages in thread
From: Adrian Popescu @ 2019-02-14 14:01 UTC (permalink / raw)
  To: Cake List


[-- Attachment #1.1: Type: text/plain, Size: 389 bytes --]

Hello,

I've taken a look at cake's source code to see what simple changes could be
made to attempt to speed it up. There seemed to be a per flow variable
called dropped which might not be that useful for regular users. The
attached patch removes it.

Perhaps cake could be optimized further for slow devices. What's the
recommended solution for profiling the kernel on mips with openwrt?

[-- Attachment #1.2: Type: text/html, Size: 516 bytes --]

[-- Attachment #2: cake-remove-dropped.patch --]
[-- Type: application/octet-stream, Size: 1077 bytes --]

diff --git a/sch_cake.c b/sch_cake.c
index 3a26db0..d1ea1d6 100644
--- a/sch_cake.c
+++ b/sch_cake.c
@@ -136,7 +136,6 @@ struct cake_flow {
 	struct sk_buff	  *tail;
 	struct list_head  flowchain;
 	s32		  deficit;
-	u32		  dropped;
 	struct cobalt_vars cvars;
 	u16		  srchost; /* index into cake_host table */
 	u16		  dsthost;
@@ -1594,7 +1593,6 @@ static unsigned int cake_drop(struct Qdisc *sch, struct sk_buff **to_free)
 	sch->qstats.backlog -= len;
 	qdisc_tree_reduce_backlog(sch, 1, len);
 
-	flow->dropped++;
 	b->tin_dropped++;
 	sch->qstats.drops++;
 
@@ -2191,7 +2189,6 @@ retry:
 			flow->deficit -= len;
 			b->tin_deficit -= len;
 		}
-		flow->dropped++;
 		b->tin_dropped++;
 		qdisc_tree_reduce_backlog(sch, 1, qdisc_pkt_len(skb));
 #if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0)
@@ -3088,7 +3085,6 @@ static int cake_dump_class_stats(struct Qdisc *sch, unsigned long cl,
 			cake_maybe_unlock(sch);
 		}
 		qs.backlog = b->backlogs[idx % CAKE_QUEUES];
-		qs.drops = flow->dropped;
 	}
 	if (gnet_stats_copy_queue(d, NULL, &qs, qs.qlen) < 0)
 		return -1;

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-02-18 20:43 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-14 14:01 [Cake] Dropping dropped Adrian Popescu
2019-02-14 14:35 ` Toke Høiland-Jørgensen
2019-02-15  8:23   ` Adrian Popescu
2019-02-15 10:55     ` Toke Høiland-Jørgensen
2019-02-15 20:45 ` Dave Taht
2019-02-16  9:35   ` Adrian Popescu
2019-02-18 20:42     ` Adrian Popescu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox