From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pj2-f0.google.com (mail-pj2-f0.google.com [74.125.227.128]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E5962356770 for ; Sat, 1 Aug 2026 14:23:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.227.128 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785594212; cv=none; b=MFqFuO2WrCZ44unLecNCQVhgquRVWCxkH8FwZvDH/81egFvTv+FzQCYWA57xZrQHjRXo5vxGe8BjCCFd9n+CKnMzq7o/KfbX3PHjs3NnztG4/ssT159GY1n2cv4v31Fp8DfsA+OsnzzUjzAZLnWRkcVhp6ROQMIwWH4Jcsv//20= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785594212; c=relaxed/simple; bh=RQ8/bIf5S9U/FiX3uQoU1u6/FV6K7LLD2uqZys3J7EY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=CilrheD8KmXFH7NqYg4vY4AkrbChzCi09Eqnm5xaWKDA49Y2ji6JfIhXfnpgnzzcda+XoAB/wj0Kh7wH2ZbBuFIDPyXq16m+RxANnXRhw9g+iA0ynwysEUw7dgmgOJIoNDiim3h/+pS8urAf0ZQ6M5YGALd7BYI+VJ9MFzEFFZ8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=XAJ0FX53; arc=none smtp.client-ip=74.125.227.128 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="XAJ0FX53" Received: by mail-pj2-f0.google.com with SMTP id d9443c01a7336-2cc2c6e0688so14637945ad.0 for ; Sat, 01 Aug 2026 07:23:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1785594207; x=1786199007; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=v2tJApUzC1LEzp8M/eTL2SHChylQhCDDbwAQQxkGsv0=; b=XAJ0FX53IV3ce2ZuIOWMYtvkboF8ATRrIx1m/aKVq9BxORjbwnCw2j0Gb+KTU8s/D1 9uFWCSS36NHHxh98OqY/mlQ9kSi9YfYFpIAMym4YohVvpXQk/TW41yg6tT4t/9LmAcsS HoCH1HoXCxkkNM9sBJ+HXNQIwuAum8IhJFUKualC1mqPiJ/XdJJX3Ua5PQX2P+ttzHx3 XRTn/vPRUedYWRY0+eXej/f2jX5Bgi9wnkVSLNL8waZMLCJ2aRhy4bBZ5m3VKnu/wRvZ TlfhW0oroGxdvPuiTz9X0dSQE0/wIFbBaiuy9cIbJnpizwjwla//1gFhMkq4UgG92+ZG aoIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1785594207; x=1786199007; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=v2tJApUzC1LEzp8M/eTL2SHChylQhCDDbwAQQxkGsv0=; b=JmjEq8j6rLecvx7gnLmwJO6V0YzIYUJvzMorVumDHIz99YLg+IxU46FfyjAVwAa3B5 pBqMHqEzZrNV5cAotKym4Y+mibYcjtOdgDHtfbpKBi0eWaeAUSxnmcxz7C2nJFAnVNbr AcVq44hJ569TWOGLEfDY4NBkva20ySwu0AGr72ezdr2JximI+jiS5mPTmOD1PlCPsR/n DMtHIAmhurHVUzhHfXXAbyL82EzJg/oy4YmO1J6FN+hkQBikBCE6yyFAv6Ymuzg/VJ0w Ez+RX+jXRahD8T6MLdnIulIqj2sZgm2FJpRndawtgzk6/BLnqplwTLPM+yp/1j73ljUw IZrg== X-Forwarded-Encrypted: i=1; AHgh+Rpuy0dhJJ9CgbLkq+yqeu7q5o3WrVIv49Owidklm1Q8iRv62nRT3uxfLGI3jyOkcmppQnLhrlFtZiMKMQE=@vger.kernel.org X-Gm-Message-State: AOJu0YxYPPAkfDF+G6LN5JTxUoLZ0pFF72V9FLQMRLd/M2YmDX3ZhJF2 zcR+szLDRm7TCQHBleFLVIxR2OxmAPc042DORXHlOknqNMga/2xoeTzu X-Gm-Gg: AR+sD12guDC0ikhYvmhDWktB1qq4r2OjdUIbJbWbUbdJ/naG6xaqZ8QiItlccNe+QDQ tTqDFKoSb4Ba+pEOu+goU1BiR1C31U9oC6wnvCT7uK6RZm8AF+iZaNLUittldUaoTV5GHCSnLWG zBVlJgQtd2tnT65EHCSC4doD0QwjfIOqCetBhy4c6faWQSjobJuhzvxRERcgcPkDKDut+nsxUHp TU9WsEl5LxwkWN06VfwaHDm4du1MLJ7/H1vcAXD2YBdyLs4W1R+QPvbjGrv8D2eK7Lgx7x4BpXm PSUdcMuwraWI6d1+6ImUiRx4DEWw/zQ2FMg2ioPi2ZcSJYmFJVNeDRb1xjuXxx3iKtO/Xk0QG75 OBXx9il5sDLbTGP5XuW7f1RqSM3QqeKi2+rpMAdwy6y8XMOLl72CIMOEuTY18uNRQakBdHsKPcX oANhE9ItBhRivdQWwazOtpphNJPC4ywy0OnbmdUqShmmGHfYNE80Q2uF7ptZQVmac9fw== X-Received: by 2002:a17:903:2b07:b0:2cf:a5da:705e with SMTP id d9443c01a7336-2d052494227mr37113295ad.41.1785594206913; Sat, 01 Aug 2026 07:23:26 -0700 (PDT) Received: from server.lan ([103.213.4.16]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2d04ae5ac3dsm18043845ad.23.2026.08.01.07.23.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 01 Aug 2026 07:23:26 -0700 (PDT) From: Coia Prant To: Andrew Lunn , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Heiko Stuebner , Vinod Koul , Maxime Chevallier , Maxime Coquelin , Alexandre Torgue , Lad Prabhakar , Romain Gantois , Heiner Kallweit , Coia Prant Cc: Neil Armstrong , Russell King , Shawn Lin , David Heidelberg , netdev@vger.kernel.org, linux-rockchip@lists.infradead.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-phy@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-renesas-soc@vger.kernel.org Subject: [PATCH v2 02/10] dt-bindings: phy: rockchip: naneng-combphy: add rockchip,sgmii-mac-sel property Date: Sat, 1 Aug 2026 22:22:26 +0800 Message-ID: <20260801142244.679437-4-coiaprant@gmail.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260801142244.679437-2-coiaprant@gmail.com> References: <20260801142244.679437-2-coiaprant@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On RK3568, the SGMII interface can be routed to either GMAC0 or GMAC1 via the pipe_sgmii_mac_sel bit in the pipe GRF registers. Add the optional "rockchip,sgmii-mac-sel" property to allow the device tree to select which GMAC controller is used for SGMII. The property takes a value of 0 (GMAC0) or 1 (GMAC1). The hardware reset value is 1 (GMAC1), but this can be overridden by setting the property to 0 for boards where SGMII is connected to GMAC0. This is necessary for boards such as the Ariaboard Photonicat, where the SGMII interface is connected to GMAC0 and needs to be explicitly configured. Signed-off-by: Coia Prant --- .../bindings/phy/phy-rockchip-naneng-combphy.yaml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml b/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml index 379b08bd9e97a..8e898bce9af73 100644 --- a/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml +++ b/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml @@ -80,6 +80,15 @@ properties: description: Some additional pipe settings are accessed through GRF regs. + rockchip,sgmii-mac-sel: + $ref: /schemas/types.yaml#/definitions/uint32 + enum: [0, 1] + default: 1 + description: + Select gmac0 or gmac1 to be used as SGMII controller. + The hardware reset value is GMAC1 (1). Set this to 0 to route + SGMII to GMAC0. + "#phy-cells": const: 1 @@ -105,6 +114,10 @@ allOf: maxItems: 1 reset-names: maxItems: 1 + rockchip,sgmii-mac-sel: true + else: + properties: + rockchip,sgmii-mac-sel: false - if: properties: compatible: -- 2.47.3