Received: by 2002:a05:7208:3003:b0:81:def:69cd with SMTP id f3csp4258589rba; Tue, 2 Apr 2024 11:33:28 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXDFb1ZeWJMhtvTX+D/T7h698zd4PHf5ECyckyM+P6+vTm+xk/spNMMFayMtO1SEr4aEHxaDGFTB3qvE85PK06AtjaUBaU1aoKSlRsfSA== X-Google-Smtp-Source: AGHT+IHfbo2WPGaQkWtklHvXlOZ3jEN1RQr2lz+Xi1fPG8RF9BjxDbKKGRkPGPYpj28/mHcFMdNA X-Received: by 2002:a50:d657:0:b0:567:e0e:dda5 with SMTP id c23-20020a50d657000000b005670e0edda5mr290526edj.17.1712082808376; Tue, 02 Apr 2024 11:33:28 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712082808; cv=pass; d=google.com; s=arc-20160816; b=pWaGJKy7SfDWzVN4FTMzZyT/ZJfN/BllOOrVFQ+7m0LX/eGq4VvoZlmmwiY/3rBgHU QUTyZ5qbunRutkYaWA6MVWeaR+5tvHpbLamZVTPSbFpasc4NSlR50PZga+ydcye3eNOu /sPCXeQEKGEN9YkT2aIoybSaVPYfkTgIw4uIATJcVvpSL3CPa+J/baRmj8yhR0EdMACB K/qywNcbzuyKpkR5fqYmKebWeTLl2c+dD6kUfq6n1aXZFGoexbkWIDm/gTfSHIQ2QkH+ IccTR+RzUwwZVIthW3BK+mC8ciP0b92YdX6Hjb03/aPX2ta76+VbT42F9lD9ZBmp6Vzc 2XzQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=BbR4Blx6a1UKsvbC+9hUCk2GxkrF/kMc/PYHMiri4Js=; fh=gCxZa+0oEbgv+5BrNRTVpd5SyDf6MaEBXGxF5KE6Xuw=; b=ED0Hg4Hk8Gpc3lh8KNYcadxUbfGKIh0gh1+LWtoI3hHP6wSCym3gZJiR67JupnSt53 eH69JjWyE0S86tQJEH38rHPdQhGO8+AaEITzltfXOrpMRVpRiRAuWkdCBFDj9B7k1vNS 9J0eMO3tm8ZvGliYRNVjC+QqDj7q5NtipHqSIrybWnRYq9qXIJFMzZvrwhR6hMW8Iwt2 jNtRvVF2sZ8N3TRVHr8AJ/llDRhA7ipdfKjcabvjHDSYKZV3oZTAczRrvYloQgwhJGOp pd3YGFoefAhNsDAbP1LE6mc5XlbVThO9lDpKK7PvorTGVkyDAYaAGMAA+EEG7srYkJ9u 9VbQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=WrOsOdEx; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-128508-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-128508-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id s17-20020a508d11000000b0056dfbb6cbdfsi173592eds.102.2024.04.02.11.33.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Apr 2024 11:33:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-128508-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=WrOsOdEx; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-128508-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-128508-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 252961F232D4 for ; Tue, 2 Apr 2024 18:33:28 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7257F15B560; Tue, 2 Apr 2024 18:32:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="WrOsOdEx" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 8C78615B573; Tue, 2 Apr 2024 18:32:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712082775; cv=none; b=hR+j99a7Lil32FP8FffD7paxQMl/tGfLAGY10PwHyF6uuBfMu6TPqx9BW5kKXWwbCIlbgCZfq7cNwdo4nA3/FjM4nm7aD83gtSGmAd/6ZX7+myufPRoUlnTzIFKsLE+2qJ64xWE9m0m0lFS5cAALV/aQrf0feqa6sM+G1iJVmvA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712082775; c=relaxed/simple; bh=Tkc1wkxhjy4lTBWpmN6ywzBBN9sIhelXSsaqaqbZTRA=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=rNlP2DoXRWElgaWg08YGTEB0yzBPe0nm1V3LrDOMNjpPqXL5TJBVDCb4u+LNcootA2q/BrqIx7Fo5F0irE0/7io+SXgq2+oSn/PN6xScBgfZ+PK++cvtgHDn9ZfX/h9FdMYu63pAXOC7udZzA3O0m/LFQG1qDedvHGNHnItbB8w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=WrOsOdEx; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 86FCCC433F1; Tue, 2 Apr 2024 18:32:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1712082775; bh=Tkc1wkxhjy4lTBWpmN6ywzBBN9sIhelXSsaqaqbZTRA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WrOsOdEx9YsalLcENbahAGFye7mnX2y3D7cOgpoypb2pTm1URyl5GgAzWqnTSVOxX Z/IKX7ZVW90KNdO5s98eIUEROBRYoxQuJu9E28GVV/5UWZ0cXdHzUjFnzpm0Dzrwjl ceFOOODlI58CgTYbw3gyvgwavasfL4qHMAHtruHk5y1teu3oXDxEqgtstCrtHFLUpV VqDZdgz7y5cX/V9Trt98sOIUPbApm4WkOG1cD+JfLxuu88L9ILBOBEjrZLioliXP4t dlmyR41tYITuckKVL0K7wipww5qg/OqP1rVNE8bE5w7yeX2NOX8RAkcPhWwaUAlE+l JQQNd1AgZghMg== From: Krzysztof Kozlowski To: Robert Marko , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Krzysztof Kozlowski Subject: [PATCH 3/3] arm64: dts: marvell: espressobin-ultra: fix Ethernet Switch unit address Date: Tue, 2 Apr 2024 20:32:40 +0200 Message-Id: <20240402183240.49193-3-krzk@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240402183240.49193-1-krzk@kernel.org> References: <20240402183240.49193-1-krzk@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The Espressobin Ultra DTS includes Espressobin DTSI which defines ethernet-switch@1 node. The Ultra DTS overrides "reg" to 3, but that leaves still old unit address which conflicts with the new phy@1 node (W=1 dtc warning): armada-3720-espressobin.dtsi:148.29-203.4: Warning (unique_unit_address_if_enabled): /soc/internal-regs@d0000000/mdio@32004/ethernet-switch@1: duplicate unit-address (also used in node /soc/internal-regs@d0000000/mdio@32004/ethernet-phy@1) Fix this by deleting ethernet-switch@1 node and merging original node with code from Ultra DTS into new ethernet-switch@3. Signed-off-by: Krzysztof Kozlowski --- Not tested on hardware. --- .../marvell/armada-3720-espressobin-ultra.dts | 104 +++++++++++------- 1 file changed, 67 insertions(+), 37 deletions(-) diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts index 870bb380a40a..b3cc2b7b5d19 100644 --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts @@ -114,54 +114,84 @@ &usb3 { }; &mdio { + /* Switch is @3, not @1 */ + /delete-node/ ethernet-switch@1; extphy: ethernet-phy@1 { reg = <1>; reset-gpios = <&gpionb 2 GPIO_ACTIVE_LOW>; }; -}; -&switch0 { - reg = <3>; + switch0: ethernet-switch@3 { + compatible = "marvell,mv88e6085"; + reg = <3>; - reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>; + reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>; + dsa,member = <0 0>; - ethernet-ports { - switch0port1: ethernet-port@1 { - reg = <1>; - label = "lan0"; - phy-handle = <&switch0phy0>; + ethernet-ports { + #address-cells = <1>; + #size-cells = <0>; + + switch0port0: ethernet-port@0 { + reg = <0>; + label = "cpu"; + ethernet = <ð0>; + phy-mode = "rgmii-id"; + fixed-link { + speed = <1000>; + full-duplex; + }; + }; + + switch0port1: ethernet-port@1 { + reg = <1>; + label = "lan0"; + phy-handle = <&switch0phy0>; + }; + + switch0port2: ethernet-port@2 { + reg = <2>; + label = "lan1"; + phy-handle = <&switch0phy1>; + }; + + switch0port3: ethernet-port@3 { + reg = <3>; + label = "lan2"; + phy-handle = <&switch0phy2>; + }; + + switch0port4: ethernet-port@4 { + reg = <4>; + label = "lan3"; + phy-handle = <&switch0phy3>; + }; + + switch0port5: ethernet-port@5 { + reg = <5>; + label = "wan"; + phy-handle = <&extphy>; + phy-mode = "sgmii"; + }; }; - switch0port2: ethernet-port@2 { - reg = <2>; - label = "lan1"; - phy-handle = <&switch0phy1>; - }; + mdio { + #address-cells = <1>; + #size-cells = <0>; - switch0port3: ethernet-port@3 { - reg = <3>; - label = "lan2"; - phy-handle = <&switch0phy2>; - }; - - switch0port4: ethernet-port@4 { - reg = <4>; - label = "lan3"; - phy-handle = <&switch0phy3>; - }; - - switch0port5: ethernet-port@5 { - reg = <5>; - label = "wan"; - phy-handle = <&extphy>; - phy-mode = "sgmii"; - }; - }; - - mdio { - switch0phy3: ethernet-phy@14 { - reg = <0x14>; + switch0phy0: ethernet-phy@11 { + reg = <0x11>; + }; + switch0phy1: ethernet-phy@12 { + reg = <0x12>; + }; + switch0phy2: ethernet-phy@13 { + reg = <0x13>; + }; + switch0phy3: ethernet-phy@14 { + reg = <0x14>; + }; }; }; }; -- 2.34.1