Article View: linux.kernel.netdev
Article #20880Re: [PATCH net-next v7 2/7] dt-bindings: net: ftgmac100: Add AST2700 compatible
From: netdev-bot+sashiko
Date: Mon, 23 Nov 2026 10:13
Date: Mon, 23 Nov 2026 10:13
140 lines
12910 bytes
12910 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] Concern: the commit message for "dt-bindings: net: ftgmac100: Add
AST2700 compatible" says "ftgmac100_probe_dt() takes the NC-SI path…
- [Low] In "dt-bindings: net: ftgmac100: Add AST2700 compatible", the new
AST2700 conditional in…
- [Low] Concern: the binding adds `aspeed,ast2700-mac` as a standalone
compatible, but at this commit…
--
dt-bindings: net: ftgmac100: Add AST2700 compatible
This commit adds aspeed,ast2700-mac to the ftgmac100 binding. It allows the
reset line for it and adds it to the clocks/clock-names conditionals. It
also adds an AST2700-only rule that requires exactly one of phy-mode or
use-ncsi.
> Require exactly one of "phy-mode" or "use-ncsi" in the device tree
> when the AST2700 compatible is used. The driver only enforces
> "phy-mode" when NC-SI is not in use: ftgmac100_probe_dt() takes the
> NC-SI path before ftgmac100_mii_probe(), where the AST2700 phy-mode
> check lives, is ever reached.
[Severity: Low]
At this commit, ftgmac100_mii_probe() in
drivers/net/ethernet/faraday/ftgmac100.c has no AST2700 phy-mode check. It
falls back to RGMII when phy-mode is missing.
Does this paragraph refer to the check added later in the series by
"net: ftgmac100: Require phy-mode for AST2700"?
ftgmac100_mii_probe() {
...
err = of_get_phy_mode(np, &phy_intf);
if (err) {
if (priv->mac_id == FTGMAC100_AST2700) {
dev_err(priv->dev, "phy-mode is required for this SoC\n");
return -EINVAL;
}
...
}
After the full series is applied, the description matches the code. That
is because ftgmac100_probe_dt() returns through ftgmac100_probe_ncsi()
before it reaches ftgmac100_mii_probe(). Could the message say that a
following patch adds the check, so it is also accurate at this commit?
> diff --git a/Documentation/devicetree/bindings/net/faraday,ftgmac100.yaml b/Documentation/devicetree/bindings/net/faraday,ftgmac100.yaml
> index 9d352e3686aaf..95f4993939cf6 100644
> --- a/Documentation/devicetree/bindings/net/faraday,ftgmac100.yaml
> +++ b/Documentation/devicetree/bindings/net/faraday,ftgmac100.yaml
> @@ -16,6 +16,7 @@ properties:
> - aspeed,ast2400-mac
> - aspeed,ast2500-mac
> - aspeed,ast2600-mac
> + - aspeed,ast2700-mac
[Severity: Low]
At this commit, ftgmac100_of_match[] in
drivers/net/ethernet/faraday/ftgmac100.c has no entry for
aspeed,ast2700-mac. There is also no FTGMAC100_AST2700 mac_id and no
is_aspeed handling. Can a schema-valid AST2700 node bind to the driver at
this point?
The next patch in the series, "net: ftgmac100: Add AST2700 compatible
support", appears to fix this by adding:
{ .compatible = "aspeed,ast2700-mac",
.data = &ftgmac100_match_data_ast2700 },
It also adds FTGMAC100_AST2700 to the is_aspeed branch of
ftgmac100_probe(). Adding the binding before the driver is the usual
order, and no in-tree DTS uses this compatible yet. I'm mentioning it only
for completeness.
[ ... ]
> @@ -79,12 +80,24 @@ allOf:
> contains:
> enum:
> - aspeed,ast2600-mac
> + - aspeed,ast2700-mac
> then:
> properties:
> resets: true
> else:
> properties:
> resets: false
> + - if:
> + properties:
> + compatible:
> + contains:
> + const: aspeed,ast2700-mac
> + then:
> + oneOf:
> + - required:
> + - phy-mode
> + - required:
> + - use-ncsi
[Severity: Low]
oneOf fails when both subschemas match. Will an AST2700 node with both
phy-mode = "rmii" and use-ncsi then fail dtbs_check?
The driver accepts that combination. ftgmac100_probe_dt() checks use-ncsi
first:
if (of_get_property(np, "use-ncsi", NULL))
return ftgmac100_probe_ncsi(netdev, priv, pdev);
ftgmac100_probe_ncsi() then always connects with RMII and never reads
phy-mode:
err = phy_connect_direct(netdev, phydev, ftgmac100_adjust_link,
PHY_INTERFACE_MODE_RMII);
Existing nodes for this binding already use this pairing, for example
&mac2 and &mac3 in aspeed-bmc-asus-x4tf.dts:
phy-mode = "rmii";
use-ncsi;
The same pattern appears in aspeed-bmc-inventec-starscream.dts,
aspeed-bmc-nvidia-gb200nvl-bmc.dts and aspeed-bmc-quanta-s6q.dts.
The commit message's stated reason is to avoid rejecting nodes that only
have use-ncsi, and anyOf would do that too. Would anyOf fit better here?
If the goal is to stop a non-RMII mode from being used with NC-SI, a rule
like "if: required: [use-ncsi] then: properties: phy-mode: const: rmii"
could express that instead.
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261119-support_ast2700-v7-0-33c8ca2d0dd7%40aspeedtech.com
Technical Details
Message-ID:
<179542879318.3135.2219798604934758241@kernel.org>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-369232-linux-kernel-netdev=dewy.ruReferences:
<20261119-support_ast2700-v7-2-33c8ca2d0dd7@aspeedtech.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-369232-linux-kernel-netdev=dewy.ru From: netdev-bot+sashiko@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next v7 2/7] dt-bindings: net: ftgmac100: Add AST2700 compatible Date: Mon, 23 Nov 2026 10:13:13 +0000 Organization: Usenet Network Message-ID: <179542879318.3135.2219798604934758241@kernel.org> References: <20261119-support_ast2700-v7-2-33c8ca2d0dd7@aspeedtech.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="3849056"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:cyQVuS17wh+JwwvvDg12Cl22QTc= sha256:DrZrIFfT9FaT/l1rfwER5VWqzlR3Rb9MJ7GsvAY5KVc= sha1:HRKbKAogWE+ZRbvYJi8oeRCXm3c= sha256:Lj1HSFhjBE/n3Qr/bu6w0WbmYPRGY2kvqicDU/fXtzs= 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 0E1B9125D9D; Mon, 23 Nov 2026 13:13:33 +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 78pd0nMAcn_q; Mon, 23 Nov 2026 13:13:29 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-369232-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 sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id 38A66125D9A; Mon, 23 Nov 2026 13:13:21 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 2B1E8341B7; Mon, 23 Nov 2026 10:13:16 +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=1795428795; b=0apd+rJOtkDN4XN3qiG2X2cas41PkFRJ/pvQpeBjiYXaejnYoX7lEo+uAHkVYIqwpnRb rEBeIjV5CMFVuHbEdvcI+vggg2BOZJy6dkAz9qJzgTnOcSTqUCnG3fDQ19DJd09PPc53K 5hcEbhz6Ig4Fye4C10qGm/A6Q3jMRAwwPJIvEHHeak9CQN28guPyir3T7tkq9kvqaG99m S5B19mgc6noYKL66xCtM70W6+BuVJ2azkwoDfa0K4LbH13astaEiDCHzjPOn7gy2rpr2Z mYPaV71SY0VDdOLIHZHynGIZJJORUHxAZ8Z4EI4GzVMCdMteSG4RbmG0WwYfY+AP+1w== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795428795; 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=aCAKYfoCvQ9vLmGln50tXMVwiUj0VV55OA5yXQEIa6E=; b=03cOpvvsaTiDuWO5jrT1iR73ohqq+AVge3pWK6gvY5uMOPOi63A3OUagxFM+QOO5OQBs Lolpy7fNtDCkL0ifMTO0fMMcWLorlU7JEx+jI7JruxTyaQfUBeru0OH2nCCpwnDo4Cmod 7DrhSUXSZpnhI4i71OC6ebaV+2nd0sInuXOl01pWaJ7jD4JTXVNQrcnD1UycHAv+O/2hc zbkPNptZfkto+aDu8s1aMXV5l64E19vDMpBXc+Sb7AxOCZZkqn1+pWYWNkOfJCsT21RuH 9OEyYEkB9QfWcCbL1K8c49WGdldPF6vcd3TCxmA+1eKCNk7kI/8eZGUifs1hrKI+ipg== 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=o1f+q4HZ; 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 BE01D606A330; Mon, 23 Nov 2026 10:13:15 +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=o1f+q4HZ 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=1795428794; b=1u062Qn/9H4eT+gpKSnxpscUasN1vMCnKQzbmCnM4sI+tO0NAuJt0IGR1ClIAGzwzTMh YjWZ7k7WEeHzQFkf6vsg3CjEWuKi9IDPkNTCetKoqDl1R6swBg2ZhUxv7eblhh03DyU14 5edhDcH/Zfspp3x8Y1XREbEUy3jNrIGDlAeMpRpm0oYwkRrJPq5DNfv7VLqJXPSBAQFo/ 4NPZvElwOgF/UZpQrL6Gb6xLDcaKt7EMyai1rgB97g3huK+xFnapIdOMPkQcvgEWnuaSx v9LwGyP14nX9uA39rNH10NSUcrosE0nsuFzlkXMTaOlKFxqoix/+R8+aNeoZwvLrh+g== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795428794; 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=aCAKYfoCvQ9vLmGln50tXMVwiUj0VV55OA5yXQEIa6E=; b=LwzoI+4qaewB7nvKs/39JY3ikhpmgeD+daRDrR5BXIk3pheJWNFVqJrTvjYvHFztzCWl tezruowDBv6BSHNi5nX6RewPdgr+Yh36fIHaQXX6Pv43ffXnCzBMhe3P4QJlZEryJfy9F yZ6anqZ7l8hDsJpMJxyGFoBDf06x9iSAp5GqeDkHoqMvDdxphSME5Glp3iwC7uMvHVkk3 XH+iH8Qy2lvYj0saLslQWxBQwb324aRQEQcrxs0u9eGw4dF+OcB547wdCP/Qr3/W0l4Fx 8Z+/oTdKdDMLJBQZOQrW7/31y7TcWzDLeeFYY1XmFPxV1nIPn90a42AuusmtLGIiowQ== 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=o1f+q4HZ; 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 DF74E606A331; Mon, 23 Nov 2026 10:13:14 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 99F621F000CF; Mon, 23 Nov 2026 10:13:13 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1795428794; bh=aCAKYfoCvQ9vLmGln50tXMVwiUj0VV55OA5yXQEIa6E=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=o1f+q4HZI9J1syulAoNfTREYpzL4c2B8aSA66W94knoBv9IH4KYDmrLt7DJYkg3dO wlyKITCku7VK/cLSDHFWygw/b8smAASFVcF0UuSbsoAD4Yf3zvzWBmTQ6bpopJxCzI MpsxOg9Gw/cFv++LZ1gS+9x5sIxnPTZT+5KraLyyF0HHufVjOZZu0IdT1QjY9bAOHA 8WXy6EMMheMjMFcvIKjCG3im0ywkvB8uuLmL/ahnFGx35Axwm0aRpHAokwK4yL8JAv ze4LnQjttgyJz+ZrweR9/JETH3SZstqj4x4RzIQu2ZHZA5QYd7OkV4GwFNXN3TDYLT z7OI7+QGIYVTA== X-Cc: andrew+netdev@lunn.ch, davem@davemloft.net, kuba@kernel.org, pabeni@redhat.com, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, ratbert@faraday-tech.com, edumazet@kernel.org, hkallweit1@gmail.com, linux@armlinux.org.uk, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, andrew@lunn.ch X-In-Reply-To: <20261119-support_ast2700-v7-2-33c8ca2d0dd7@aspeedtech.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