From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=211.20.114.72 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1792496075; b=COA0nfDS6u7dOSx1hwSDfNSfOyQLZ+kB1KjUSy8mIkBZ+UWyjgtvExMpbTfNv26DNkTI LVjbieobhO4LuMXz21p57RybhcpCJon6/ZvVsM3i+pCIBgWXM3DkUp7Nb+Xv+ZpAvH4FV hk3Y41tnsi8abX3PUC6mEQ2sr6q+D//LqfxN9KZ2RgYFDRHoC1W9KMg1lzOGxTIbaVZNw eWhPCoSPbDp57SQGHtLTVZUUZKQ3WRCptRoV1iNWs0TZ0GPxN+7zCjRFhrpC0+dSsXekO MXijW9xXEKztrM8w3hJT3Y00F1trwSEbRnyarEDc5U/3jNlzs25BlaI8MSbwdwzPRKQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1792496075; h=DMARC-Filter:Received:Received:From:Date:Subject:MIME-Version: Content-Type:Content-Transfer-Encoding:Message-ID:References: In-Reply-To:To:CC:X-Mailer:X-Developer-Signature:X-Developer-Key; bh=YgiL9PYeUdMsQQJdZ2R1QPV9MD8KIpSSIKhcXP8qDRU=; b=t2K6vmeI5nBLg6PqcpUIAqtEXuJIuonzs5erYSPgL5mUWh6qlmkm3fYQKa3D2AxB6PK4 Np+oIcYeYW9XzWkxNlFZN1tyXH1dwLuNKk1rETyGCaII2MT5sVGF9Ud+OXVAZclaevU4A tJHpg6jcVaKMQ2tJHjDSlBlJKADoYNyZk9gAfTVdaLRUxyyygKzuAqMng1ZbBf67pfSn9 RDt0ZMWvC2mYtspXOkArUnRYOGbIfu6xadlYePqzyDiOrzbzYH83pi6HG9SGhX5G02Lg1 eIMMcalU71FP/o6DUoX51PzN6GYb/FSrXqfa/7rM7PdVdAbxIl8w/fr6yHRz/pXSI7w== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=aspeedtech.com; spf=pass smtp.mailfrom=aspeedtech.com; arc=none smtp.remote-ip=211.20.114.72 Received: from twmbx01.aspeedtech.com (mail.aspeedtech.com [211.20.114.72]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9E04E60A2604; Tue, 20 Oct 2026 11:34:31 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 9E04E60A2604 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=aspeedtech.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=aspeedtech.com Received: from TWMBX01.aspeed.com (192.168.0.62) by TWMBX01.aspeed.com (192.168.0.62) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 20 Oct 2026 19:34:13 +0800 Received: from [127.0.1.1] (192.168.10.13) by TWMBX01.aspeed.com (192.168.0.62) with Microsoft SMTP Server id 15.2.1748.10 via Frontend Transport; Tue, 20 Oct 2026 19:34:13 +0800 From: Jacky Chou Date: Tue, 20 Oct 2026 19:34:16 +0800 Subject: [PATCH net-next v4 5/7] net: ftgmac100: Require phy-mode for AST2700 X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-ID: <20261020-support_ast2700-v4-5-4d36b40939b3@aspeedtech.com> References: <20261020-support_ast2700-v4-0-4d36b40939b3@aspeedtech.com> In-Reply-To: <20261020-support_ast2700-v4-0-4d36b40939b3@aspeedtech.com> To: Andrew Lunn , "David S. Miller" , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Po-Yu Chuang , Eric Dumazet , "Heiner Kallweit" , Russell King , "Eric Dumazet" CC: , , , Jacky Chou , Andrew Lunn X-Mailer: b4 0.14.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1792496053; l=1341; i=jacky_chou@aspeedtech.com; s=20251031; h=from:subject:message-id; bh=1RAjtRaBnlESdbdb4uGZ6kTcr6R3XDz0Y1IoL5YzWHQ=; b=UdQXNxzOvSrVyLS0HL1LWYXkSktK1Pef97I3nfp566rYlh6UkoHPvSZENfJfqmYLNg4zNc398 8T/mnuLtHCFCQ6lFcgwJl4365if3b4GKdI0aM0zdjzpkx+hL8KD8ziZ X-Developer-Key: i=jacky_chou@aspeedtech.com; a=ed25519; pk=8XBx7KFM1drEsfCXTH9QC2lbMlGU4XwJTA6Jt9Mabdo= The driver currently defaults to RGMII when the "phy-mode" property is missing from the device tree. This default is no longer valid for AST2700, which also supports RMII via FTGMAC100_QUIRK_RMII_ENABLE. Make "phy-mode" a required property for AST2700 and fail probe with an error message if it is not specified, instead of silently defaulting to RGMII. Reviewed-by: Andrew Lunn Signed-off-by: Jacky Chou --- drivers/net/ethernet/faraday/ftgmac100.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/faraday/ftgmac100.c b/drivers/net/ethernet/faraday/ftgmac100.c index 9b7becb01726..5a578a62df67 100644 --- a/drivers/net/ethernet/faraday/ftgmac100.c +++ b/drivers/net/ethernet/faraday/ftgmac100.c @@ -1526,8 +1526,13 @@ static int ftgmac100_mii_probe(struct net_device *netdev) /* Default to RGMII. It's a gigabit part after all */ err = of_get_phy_mode(np, &phy_intf); - if (err) + if (err) { + if (priv->mac_id == FTGMAC100_AST2700) { + dev_err(priv->dev, "phy-mode is required for this SoC\n"); + return -EINVAL; + } phy_intf = PHY_INTERFACE_MODE_RGMII; + } /* Aspeed only supports these. I don't know about other IP * block vendors so I'm going to just let them through for -- 2.34.1