Article View: linux.kernel.netdev
Article #17882Re: [PATCH net-next v4 4/8] net: xilinx: tsn: parse endpoint DMA channel configuration
From: netdev-bot+sashiko
Date: Tue, 17 Nov 2026 13:14
Date: Tue, 17 Nov 2026 13:14
89 lines
11299 bytes
11299 bytes
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.
Low priority / nit picks for your consideration:
- [Low] The driver requires the number of tx_chanN entries in "dma-names"
to equal "xlnx,num-priorities", but the DT binding does not encode orβ¦
--
net: xilinx: tsn: parse endpoint DMA channel configuration
This patch counts the tx_chanN and rx_chanN entries in dma-names and
allocates the conduit netdev with that many TX and RX queues. It parses
the tx-queues-config child node to map each logical TX queue to a TX DMA
channel. Probe also requires the TX channel count to equal
xlnx,num-priorities on the parent IP node.
> diff --git a/drivers/net/ethernet/xilinx/tsn/xilinx_tsn_ep.c b/drivers/net/ethernet/xilinx/tsn/xilinx_tsn_ep.c
> index b6458bb0ba0fd..9458db38255d4 100644
> --- a/drivers/net/ethernet/xilinx/tsn/xilinx_tsn_ep.c
> +++ b/drivers/net/ethernet/xilinx/tsn/xilinx_tsn_ep.c
[ ... ]
> @@ -69,15 +88,180 @@ static const struct ethtool_ops ep_ethtool_ops = {
[ ... ]
> static int xlnx_tsn_ep_probe(struct platform_device *pdev)
> {
[ ... ]
> + ret = of_property_read_u32(ip_np, "xlnx,num-priorities", &num_prio);
> + of_node_put(ip_np);
> + if (ret)
> + return dev_err_probe(dev, ret, "missing xlnx,num-priorities\n");
> +
> + if (num_prio < TSN_MIN_PRIORITIES || num_prio > TSN_MAX_TX_QUEUE)
> + return dev_err_probe(dev, -EINVAL,
> + "invalid xlnx,num-priorities %u\n",
> + num_prio);
>
> - ndev = alloc_etherdev(sizeof(*ep));
> + if (num_tx_dma_channels != num_prio)
> + return dev_err_probe(dev, -EINVAL,
> + "TX channel count %u must equal num-priorities %u\n",
> + num_tx_dma_channels, num_prio);
[Severity: Low]
Is this equality check stricter than what the binding in
xlnx,tsn-endpoint-ethernet-mac.yaml allows?
The binding says the following and nothing more:
- each dma-names item matches "^(tx|rx)_chan[0-7]$"
- there are 2..16 items, with at least one TX and one RX entry
- each queueN under tx-queues-config maps to a distinct TX channel
listed in dma-names
Taken together, these rules only require the TX channel count to be at
least xlnx,num-priorities. They don't require it to be equal.
For example, this DT looks valid against the schema:
xlnx,num-priorities = <2>;
...
dma-names = "tx_chan0", "tx_chan1", "tx_chan2", "rx_chan0";
tx-queues-config {
queue0 { xlnx,dma-channel-num = <0>; };
queue1 { xlnx,dma-channel-num = <1>; };
};
But xlnx_tsn_ep_probe()->ep_count_dma_channels() counts three TX
channels, and probe then fails with:
TX channel count 3 must equal num-priorities 2
The commit message says equality is the intended rule. Should the binding
state or enforce that in the xlnx,num-priorities or dma-names
descriptions? Or should the driver accept extra TX channels that no queue
uses?
--
Sashiko AI review Β· https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261113-patches_v2_external-v4-0-56bb26f042a4%40amd.com
Technical Details
Message-ID:
<179492128482.3136.14229628808606591959@kernel.org>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!nntp.comgw.net!eternal-september.org!feeder.eternal-september.org!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-365288-linux-kernel-netdev=dewy.ruReferences:
<20261113-patches_v2_external-v4-4-56bb26f042a4@amd.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!nntp.comgw.net!eternal-september.org!feeder.eternal-september.org!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-365288-linux-kernel-netdev=dewy.ru From: netdev-bot+sashiko@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next v4 4/8] net: xilinx: tsn: parse endpoint DMA channel configuration Date: Tue, 17 Nov 2026 13:14:44 +0000 Organization: Usenet Network Message-ID: <179492128482.3136.14229628808606591959@kernel.org> References: <20261113-patches_v2_external-v4-4-56bb26f042a4@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="2335233"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:/KdVWijuFoK2iMqkvAWgNtnGNOE= sha256:sVcKYffIEjyqHjuVbHhKQ4iwXK8nCIbYZx7sdZMuO/0= sha1:Q0wWCc2bl00tuSLQtECcGPkZVxE= sha256:l8d4VaZXcv6Ayob9tMEaE4OEYtFRa1dYyha7z6Cf1Kk= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 38216114F70; Tue, 17 Nov 2026 16:15:16 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.4 X-Spam-Status: No, score=-3.4 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aqKhNonkh4qc; Tue, 17 Nov 2026 16:15:12 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=104.64.211.4; helo=sin.lore.kernel.org; envelope-from=netdev+bounces-365288-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sin.lore.kernel.org (sin.lore.kernel.org [104.64.211.4]) by mail.dewy.ru (Postfix) with ESMTPS id 239A9114F6E; Tue, 17 Nov 2026 16:15:03 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sin.lore.kernel.org (Postfix) with ESMTP id 01D222E464; Tue, 17 Nov 2026 13:15:01 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794921287; b=QL+ZYjoB/oqKyFQg5VdSEmboyGbg0PhgtG8O2ty9nz6+pnmeaY+1Y1hS1wdMHpI/Bw9t A7t/vEUO86Tu5C7yS8g0IuxUYSxKOXiuOt5eJKYy2g96xH246ld9jHy7i6wkWuj8RVrCR rFrPoLkzqEOXd0rpkJI9YBHISrdLtttblGh0iJSuoVZ2iGMr1nL703qkFgpxwIDh9CQBZ 37VIExz5iUec/Xcro8zxuKHWRaRX5s+NGGUe6dFwi9VclDk7W16Rhz0QByQBgRUB7dBy2 nq/V7i3Psm5KaKkIy1K7j6PZqdJYbg0BFEvgsCo+9sjmp23w+pQklKjy3d/1YjbhGNA== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794921287; h=X-Original-To:Received:Received:DKIM-Signature:Subject:From:To:Cc: Date:Message-ID:In-Reply-To:References:X-sashiko-severity: Content-Type:Content-Transfer-Encoding:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version; bh=0qKcuyhzLFuBHbczAbqx5crwyCe5DTKBouONLeSXJ7A=; b=fp54GNGfikQhnVeS31FtTOh5n1bS4hXHPqkzsY8PBAGCwS1ON1SPZ1iXL4DVyTQsTCPK VazGXNp2RZ718GdqpnarTMm49w2XaxjuSNHiB1w+g+FRhmabCUKtqAtGlRGfIZdshjvuo sxtN0/Xrg73u5YIXlgzhrlLV3D3A6Isywhdf6U1sNLoxtWvJBqmrGSZVne3GO50JZY1GQ 9ELsHUikZoM/RMfToKmeXwrwU3kbSspaGyiV8mygAjVKYBFWg3XqDpLhoA4pt0GLciIT9 kLj31l56hChWFWCqd89EznFI+IapSB7yJlci9mJBiWef73CKfbQv+MOddJfj9T7/8JA== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=G64rw3CY; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D1ECC60A260B; Tue, 17 Nov 2026 13:14:47 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=G64rw3CY X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794921287; b=btGZTOh0dFzq8hCDh9hy0j2q8rRVXvGjn3oxoYJowF0yM8DtzAnqKQMLQe4mCprcssMS z1KiSaT+OJlnY8XgjaC1HlITOJVibsTJ10HcQ/1j5zvFsBDFtR8XUns6xUFk+6zZRurri jvZ5TznJvb+z2KppjKXvBcwlKlrJ5G4ng9g+h0cgU4hZlIRLFaWUlXPjOsKMbYQuq8zGP +Gl4eHEA+3Jdat6rk9N+YRoYEufHSiP4F7RLM41CzigmJGTIcbgFWwEKr8xPjy+euE9ez qMpEfGlEZ8GjfJkvo2BCGFPYazs13rkEllw070G8JTL4GITjRKx+XTEF5g8xUMpLAag== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794921287; h=Received:DKIM-Signature:Subject:From:To:Cc:Date:Message-ID: In-Reply-To:References:X-sashiko-severity:Content-Type: Content-Transfer-Encoding:MIME-Version; bh=0qKcuyhzLFuBHbczAbqx5crwyCe5DTKBouONLeSXJ7A=; b=pm9fcD6MomQ+XwbT+q2mEoDslmzagvHjuqOMDg+fLy+NMQgt5E4KD73ZlnyxyHjV204V o89lIsWloTr7kmE2tWwpt+hpDWj8C4uz+QvDsscxEgd/c4UbC53IqYHNUhiC3+XI7uVLx zx/pQWxwf/gHlemMS7iJJWxqpk/3kgjJBbOBDXDTTTxavc3cj6ck38jZl5MbFSJ1zqMuP FceJGnABVjsZiIjidosROpWW4V6imd2U9Sv1yKD+4GKSWkjva62S05RA/J+20AdoDvM6R pWlEvRQtr1JMle6JQt3KSPBx3ah99QqlrL6K5ugeVWZXj7hBlIAtEWB5UuzPXSJh+Ug== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=G64rw3CY; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F3D24606A8BA; Tue, 17 Nov 2026 13:14:46 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 49E991F000C9; Tue, 17 Nov 2026 13:14:45 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794921286; bh=0qKcuyhzLFuBHbczAbqx5crwyCe5DTKBouONLeSXJ7A=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=G64rw3CYHmgxRV/7GES39h1YULxbfVBT+cug1THdGAri/RqGKaMXNzkikasyR7m7O c7YS74i8mNWKuefEWuDB5xLPkDpyCWy321NqP7jfxtknrk8xl6sOq37Ipub/fE6EaL L3hOeyVbZt8N9E48dqn6qcFUEA/ccSwXT+MVKtIOFN6VmMSIt+AQ5h52ueJyQng8EK /5lPSC8APo+at6ba3BJOUVelxnSSpbUda5mHJgXHy+j5avTqXyNkFUMKxQ7XFYRcsI tVVwf4jvnuo3uMDIO/x5uqHpCU2rLUoGF3py7u1FAbVXjXYZV1+ZTOjo0Xo4hBCbS8 fVqdWv/zaS7pQ== X-Cc: nagadheeraj.rottela@amd.com, andrew+netdev@lunn.ch, davem@davemloft.net, kuba@kernel.org, pabeni@redhat.com, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, richardcochran@gmail.com, michal.simek@amd.com, bigeasy@linutronix.de, clrkwllms@kernel.org, rostedt@goodmis.org, edumazet@kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rt-devel@lists.linux.dev, git@amd.com, neelisrinivas18@gmail.com X-In-Reply-To: <20261113-patches_v2_external-v4-4-56bb26f042a4@amd.com> X-sashiko-severity: Low X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list