From: Andrew Lunn <andrew@lunn.ch>
To: Jacky Chou <jacky_chou@aspeedtech.com>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Po-Yu Chuang <ratbert@faraday-tech.com>,
Eric Dumazet <edumazet@kernel.org>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: 回覆: [PATCH net-next v2 3/6] net: ftgmac100: Enable AST2700 RMII support
Date: Thu, 8 Oct 2026 14:00:42 +0200 [thread overview]
Message-ID: <3eff4d4c-7376-4fc1-983e-396ccda08ef8@lunn.ch> (raw)
In-Reply-To: <SEYPR06MB513454E3CF42CCB62402E7F59D932@SEYPR06MB5134.apcprd06.prod.outlook.com>
> The applications of device tree in ftgmac100 have 'use-ncsi', 'fixed-link'/'phy-handle'
> and legacy mdio probing for AST2400/2500.
>
> The 'use-ncsi' will bind a fixed-link phy device on speed 100 and RMII, so it will include
> phydev for netdev.
> The 'fixed-link' also bind a fixed-link phy device for phydev in netdev.
> The 'phy-handle' will return the actual phy device instance for phydev.
> The legacy mdio method also returns phydev if the MAC node includes mdio in dts
> and find the phy device by mdc/mdio.
>
> Therefore, in the current code, the devices tree does not include 'phy-handle', 'use-ncsi',
> 'fixed-link and 'mdio' properties, the ftgmac100_probe_dt() still returns 0 as success at the
> end, and the phydev in netdev will be NULL.
>
> All applications in ftgmac100 must get the phy device handle, regardless of the actual
> phy device or the virtual fixed-link phy device.
>
> I would like to add a patch to adjust the ftgmac100_probe_dt(), once the
> device tree lacks one of them will return the corresponding error or no device error to
> make probing failed.
You cannot cause regressions with existing device, e.g.
aspeed-ast2500-evb.dts
&mac0 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_rgmii1_default &pinctrl_mdio1_default>;
};
No phy-handle, no use-ncsi.
So enforcing these must be limited to 2700.
It looks like you can test that some sort of PHY has been found. But
then please remove all tests which check that phydev is not NULL. And
include a good commit message why this is safe and will not cause
regressions.
Andrew
next prev parent reply other threads:[~2026-10-08 12:00 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-06 7:20 [PATCH net-next v2 0/6] net: ftgmac100: Add AST2700 support Jacky Chou
2026-10-06 7:20 ` [PATCH net-next v2 1/6] dt-bindings: net: ftgmac100: Add AST2700 compatible Jacky Chou
2026-10-06 7:20 ` [PATCH net-next v2 2/6] net: ftgmac100: Add AST2700 compatible support Jacky Chou
2026-10-06 16:22 ` Andrew Lunn
2026-10-06 7:20 ` [PATCH net-next v2 3/6] net: ftgmac100: Enable AST2700 RMII support Jacky Chou
2026-10-06 16:31 ` Andrew Lunn
2026-10-08 5:39 ` 回覆: " Jacky Chou
2026-10-08 12:00 ` Andrew Lunn [this message]
2026-10-08 12:10 ` 回覆: " Jacky Chou
2026-10-06 7:20 ` [PATCH net-next v2 4/6] net: ftgmac100: Require phy-mode for AST2700 Jacky Chou
2026-10-06 16:21 ` Andrew Lunn
2026-10-08 5:20 ` 回覆: " Jacky Chou
2026-10-06 7:20 ` [PATCH net-next v2 5/6] net: ftgmac100: Add AST2700 upper DMA address support Jacky Chou
2026-10-06 7:20 ` [PATCH net-next v2 6/6] net: ftgmac100: Allow building on ARM64 Jacky Chou
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3eff4d4c-7376-4fc1-983e-396ccda08ef8@lunn.ch \
--to=andrew@lunn.ch \
--cc=andrew+netdev@lunn.ch \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@kernel.org \
--cc=hkallweit1@gmail.com \
--cc=jacky_chou@aspeedtech.com \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=ratbert@faraday-tech.com \
--cc=robh@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®