From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mail.toke.dk; spf=pass smtp.mailfrom=; dkim=pass header.d=gmail.com; arc=none (Message is not ARC signed); dmarc=pass (Used From Domain Record) header.from=gmail.com policy.dmarc=quarantine Received: from mail-yw1-x1134.google.com (mail-yw1-x1134.google.com [IPv6:2607:f8b0:4864:20::1134]) by mail.toke.dk (Postfix) with ESMTPS id 5E6B89DD614 for ; Sat, 29 Nov 2025 03:08:16 +0100 (CET) Received: by mail-yw1-x1134.google.com with SMTP id 00721157ae682-789314f0920so20251307b3.1 for ; Fri, 28 Nov 2025 18:08:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1764382095; x=1764986895; darn=lists.bufferbloat.net; h=content-transfer-encoding:mime-version:subject:references :in-reply-to:message-id:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=lsRYCdc4G4wEDADpE0nWasPGvye4RSjOQQ03w+jfvak=; b=IayxeAoA2OzD1ydkht0SNB5ZA03ei+7zYCqXZXbShUJSgPvj3lbgrLj4u77bwehwSI oApfBl8/xxoqC4iqpOd06BWEW3HFkhZFdEbCwvbAF5WbibulIQP4RUr0EyARjmaC8/H2 EmgQI1c+uGDIsjPwc3tTtD1EBEWg3k8pGYfZtgDb+hYN/kpHd6cUnTUMWVB/GL+apEiP 5xH1/046dG2fyQA9pIx4rHWyX0WuK8HHnesjLPVjHFrJZ8/UjwIOQvpkEoaAiCKGQZjO dibZvek83plBTN/VM5cg925fI9GMdpzFkJMVwUncOgdjr7tb7TxWJ3LEAPv68DQqnYbA jERg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764382095; x=1764986895; h=content-transfer-encoding:mime-version:subject:references :in-reply-to:message-id:cc:to:from:date:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=lsRYCdc4G4wEDADpE0nWasPGvye4RSjOQQ03w+jf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mQrSt8HgDoK11SlC4FNI= X-Google-Smtp-Source: AGHT+IEmqYXBYpPqEYCSQkz8zSv3rzNYAa0HQAd47UXkkbuR8k3qdccCqSRbB3zv+SwTOcIUYRCuAw== X-Received: by 2002:a05:690c:6d93:b0:787:cb0c:c240 with SMTP id 00721157ae682-78ab6e01205mr143757197b3.19.1764382094910; Fri, 28 Nov 2025 18:08:14 -0800 (PST) Received: from gmail.com (116.235.236.35.bc.googleusercontent.com. [35.236.235.116]) by smtp.gmail.com with UTF8SMTPSA id 00721157ae682-78ad102d25csm20916737b3.44.2025.11.28.18.08.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Nov 2025 18:08:14 -0800 (PST) Date: Fri, 28 Nov 2025 21:08:13 -0500 From: Willem de Bruijn To: =?UTF-8?B?VG9rZSBIw7hpbGFuZC1Kw7hyZ2Vuc2Vu?= , =?UTF-8?B?VG9rZSBIw7hpbGFuZC1Kw7hyZ2Vuc2Vu?= , Jamal Hadi Salim , Cong Wang , Jiri Pirko , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman Cc: =?UTF-8?B?Sm9uYXMgS8O2cHBlbGVy?= , cake@lists.bufferbloat.net, netdev@vger.kernel.org, =?UTF-8?B?VG9rZSBIw7hpbGFuZC1Kw7hyZ2Vuc2Vu?= Message-ID: In-Reply-To: <20251127-mq-cake-sub-qdisc-v2-2-24d9ead047b9@redhat.com> References: <20251127-mq-cake-sub-qdisc-v2-0-24d9ead047b9@redhat.com> <20251127-mq-cake-sub-qdisc-v2-2-24d9ead047b9@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-MailFrom: willemdebruijn.kernel@gmail.com X-Mailman-Rule-Hits: nonmember-moderation X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation Message-ID-Hash: ND6M4XPQ3VFZNCUZAVKO6HP5MZ2RB5BJ X-Message-ID-Hash: ND6M4XPQ3VFZNCUZAVKO6HP5MZ2RB5BJ X-Mailman-Approved-At: Sat, 29 Nov 2025 10:25:17 +0100 X-Mailman-Version: 3.3.10 Precedence: list Subject: [Cake] Re: [PATCH net-next v2 2/4] net/sched: sch_cake: Add cake_mq qdisc for using cake on mq devices List-Id: Cake - FQ_codel the next generation Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Toke H=C3=B8iland-J=C3=B8rgensen wrote: > Add a cake_mq qdisc which installs cake instances on each hardware > queue on a multi-queue device. > = > This is just a copy of sch_mq that installs cake instead of the default= > qdisc on each queue. Subsequent commits will add sharing of the config > between cake instances, as well as a multi-queue aware shaper algorithm= . > = > Reviewed-by: Jamal Hadi Salim > Signed-off-by: Toke H=C3=B8iland-J=C3=B8rgensen > --- > net/sched/sch_cake.c | 214 +++++++++++++++++++++++++++++++++++++++++++= +++++++- > 1 file changed, 213 insertions(+), 1 deletion(-) Is this code duplication unavoidable? Could the same be achieved by either extending the original sch_mq to have a variant that calls the custom cake_mq_change. Or avoid hanging the shared state off of parent mq entirely. Have the cake instances share it directly. E.g., where all but the instance on netdev_get_tx_queue(dev, 0) are opened in a special "shared" mode (a bit like SO_REUSEPORT sockets) and lookup the state from that instance.=