]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
tc: cake: add cake_mq support
authorJonas Köppeler <j.koeppeler@tu-berlin.de>
Mon, 5 Jan 2026 16:29:02 +0000 (17:29 +0100)
committerDavid Ahern <dsahern@kernel.org>
Thu, 15 Jan 2026 16:23:35 +0000 (09:23 -0700)
This adds support for the cake_mq variant of sch_cake to tc.

Signed-off-by: Jonas Köppeler <j.koeppeler@tu-berlin.de>
Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
tc/q_cake.c

index e2b8de55e5a27d6d64e09872ede53ba0ed661eee..250cc8b6014785657463b32f2910343140ec690d 100644 (file)
@@ -667,6 +667,11 @@ static int cake_print_xstats(const struct qdisc_util *qu, FILE *f,
                           " /%8u\n", GET_STAT_U32(MAX_ADJLEN));
        }
 
+       if (st[TCA_CAKE_STATS_ACTIVE_QUEUES])
+               print_uint(PRINT_ANY, "active_queues",
+                          " active queues: %25u\n",
+                          GET_STAT_U32(ACTIVE_QUEUES));
+
        if (st[TCA_CAKE_STATS_AVG_NETOFF])
                print_uint(PRINT_ANY, "avg_hdr_offset",
                           " average network hdr offset: %12u\n\n",
@@ -827,3 +832,10 @@ struct qdisc_util cake_qdisc_util = {
        .print_qopt     = cake_print_opt,
        .print_xstats   = cake_print_xstats,
 };
+
+struct qdisc_util cake_mq_qdisc_util = {
+       .id             = "cake_mq",
+       .parse_qopt     = cake_parse_opt,
+       .print_qopt     = cake_print_opt,
+       .print_xstats   = cake_print_xstats,
+};