From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pandora.armlinux.org.uk (pandora.armlinux.org.uk [78.32.30.218]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 49A6A33A003; Thu, 16 Oct 2025 14:58:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=78.32.30.218 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760626739; cv=none; b=oampWjMc8VuWOBuWSKhlQ3tlI5E5aN8RrNoWOnyGCKLT/0d9chNjEeo9vP2arZ7ke9eFr+Ww4iLcNHYrUziUg7S4sBDDZOK1/sbNO2FiPdU1dk14nHpevnJF490LH643pWg+9E/Z83TlXqOdlmS+5F9iMUNKyiUN0J2Kb3sC5Fw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760626739; c=relaxed/simple; bh=KcvoRU24NHWkD9NyILmMcK2gV/2qBEEKQRSifS45tL8=; h=In-Reply-To:References:From:To:Cc:Subject:MIME-Version: Content-Disposition:Content-Type:Message-Id:Date; b=dPXa62DmwFySoy2203u0uQBJY6YW8X0gCgtapcf65BKBdf9MsRV0ZDTYxLZvlhI7ylq+Qs2rDzl3lFWlPPUS2JnACNnAY8dfuJawjalhy/VtdMZYiToysSd5R9DOJoBnqVnhSLNN4244CiMuOmwM3q1+iL3KrD7N6f76D83xbiQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=armlinux.org.uk; spf=none smtp.mailfrom=armlinux.org.uk; dkim=pass (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b=C6w//HGX; arc=none smtp.client-ip=78.32.30.218 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=armlinux.org.uk Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="C6w//HGX" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Date:Sender:Message-Id:Content-Type: Content-Transfer-Encoding:MIME-Version:Subject:Cc:To:From:References: In-Reply-To:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=nncZ0AXhmzc7/NiLcTF1jzX+v3g0XKRPuyG12twUDVY=; b=C6w//HGXJIo4YeoCwKqlhB0Uzl aHMM2r/jvyPB18t4W8inTpq2Ok6wHSJf3SByTgWGo7mAR6yIuS6TOadke8K8jA/PtpqKctE5IG5Nr UiET2Bk9omHT/0c5K9j03/8krLZFjn9WMSUSF+z2A4xDVLdIJuRvKzpEat/8wPr+h7h6K9XZNCHmL AlnT8acCcfujnqKjy1HUO4wbSsrTD63NSld1Xive3sEAy479GuJwXD2bkmm4snMCThXUQnZXykG8J Ms6Q/WfOMnpD2u/gnlnfEVvts6iM92Xym7sPlHcf/XB7gK9hapgQ+Rl+cx6ED7EIT74RMesZ8RKVM Q6t7/qPA==; Received: from e0022681537dd.dyn.armlinux.org.uk ([fd8f:7570:feb6:1:222:68ff:fe15:37dd]:43238 helo=rmk-PC.armlinux.org.uk) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1v9P71-000000006S8-17lh; Thu, 16 Oct 2025 15:37:52 +0100 Received: from rmk by rmk-PC.armlinux.org.uk with local (Exim 4.98.2) (envelope-from ) id 1v9P6n-0000000Aom9-2LuZ; Thu, 16 Oct 2025 15:37:37 +0100 In-Reply-To: References: From: "Russell King (Oracle)" To: Andrew Lunn , Heiner Kallweit Cc: Abhishek Chauhan , Alexandre Torgue , Alexis Lothore , Andrew Lunn , Boon Khai Ng , Daniel Machon , "David S. Miller" , Drew Fustini , Emil Renner Berthing , Eric Dumazet , Faizal Rahim , Furong Xu <0x1207@gmail.com>, Inochi Amaoto , Jacob Keller , Jakub Kicinski , "Jan Petrous (OSS)" , Jisheng Zhang , Kees Cook , Kunihiko Hayashi , Lad Prabhakar , Ley Foon Tan , linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, Matthew Gerlach , Maxime Chevallier , Maxime Coquelin , Michal Swiatkowski , netdev@vger.kernel.org, Oleksij Rempel , Paolo Abeni , Rohan G Thomas , Shenwei Wang , Simon Horman , Song Yoong Siang , Swathi K S , Tiezhu Yang , Vinod Koul , Vladimir Oltean , Vladimir Oltean , Yu-Chun Lin Subject: [PATCH net-next v2 11/14] net: stmmac: do not require snps,ps-speed for SGMII Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Disposition: inline Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="utf-8" Message-Id: Sender: Russell King Date: Thu, 16 Oct 2025 15:37:37 +0100 SGMII mode does not require port-speed to be specified; this only switches SGMII to use the MAC configuration register speed settings and the actual value is irrelevant when the link comes up. As it seems the intention was to support "reverse SGMII" with this setting, but the code didn't actually configure that due to a typo, the warning and bad DT binding documentation has led people to specify snps,ps-speed in their DT files inappropriately. If mac_port_sel_speed is zero, then don't complain that the speed is invalid, as this means we're using "normal" SGMII. This does _not_ obsolete snps,ps-speed, nor does it change the behaviour of that property, with the exception of not making people mistakenly believe that they need to specify this option to use normal SGMII. There is no need to modify the binding. Reviewed-by: Andrew Lunn Signed-off-by: Russell King (Oracle) --- v2: add comment about why there's no requirement to change the DT binding. --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index 8f08366c25a4..79d09b40dbcc 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c @@ -1101,6 +1101,8 @@ static void stmmac_check_pcs_mode(struct stmmac_priv *priv) default: dev_warn(priv->device, "invalid port speed\n"); + fallthrough; + case 0: priv->hw->reverse_sgmii_enable = false; break; } -- 2.47.3