Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2384276lqp; Sun, 24 Mar 2024 17:03:10 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVNvQudmKEBO2ki3s5XrWPI899Zf/pObIIulq1GS1YnTPTF3Jz778VbmU1CqYamMaotxGsBDj+YNI6NxPgNPF3crXk+7BqNjpuk1qoSpg== X-Google-Smtp-Source: AGHT+IH6FII2LVuvqZxm1xWzDqDnMqQt25YPw3/dNMfCnGJuVhyAf4c/t5fGxaveKEVAzhlM0Wjg X-Received: by 2002:a05:6a00:986:b0:6ea:9117:bc65 with SMTP id u6-20020a056a00098600b006ea9117bc65mr9164878pfg.6.1711324989866; Sun, 24 Mar 2024 17:03:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711324989; cv=pass; d=google.com; s=arc-20160816; b=NLx2BIEhhqSK4Qojjr/EWkAAzlZL1FCg3ySKmChwiGVDgkMWtSnWKJNyGQmAbT3qeS UPQ5CczmBiqgZhv8sYNDRwibUP8CkN6UVIIllRnSrjY/ugbTEup+p0NVxrbfoIxqukae PvJkkugs+0ELecPzEKBBTmxU83I/9hBaViwH5NpuF/v5K5Samq3fIPq0InS8ekY+djQ0 a0s/VDEvDQFPHK2FF3AaFGk5tpmCnZzK+FpiJz23zR1fQb+A546q4Jwt6enkeCBCOLQF g8ebOeywVEbP/s9/kjd0JU+pU56/5fYjCc3tjLRtnwz57GpIpsGVHGNLn+RxKIbCAl9I K2yg== 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=VexdJ3jZfQVa0P7sz1iKd6/IHmwhQzeO2IAuq1pQHz8=; fh=e1MieGgegnZZUlrSVs47G35DW8jtgqIGsLccy+kd46E=; b=RuJe1RKpIiFdWKVlmJ86JIpCz3ozXYasGD2ep3Xv9T+1NMdOMHvWy5+x8jzcTF9Bkp PvhJB9n/7X5s3oh7mbDDO7AedwnyzrPMMj4FN351snGV3LETAM4q8mhB8kIPYzBo2Pty inPxl94n/2tjbQ0LCfH3K1AKmBMF1iTwSsIYwfoZwI3AT0XVc9jMVZ7PKKD/d9WOKHc1 i0nfnT6J8t83O8i0yDdYJ5FaUQsDQnMfkzLTg39ljxbBP3xhEeh4JSvcHUwnkM2h83D8 uzDbVoBcDwt3ytZdSpnncbcthTDes3EVN/wEhhf7FSf0TzrzoHgGol/sorrSNDPPSXrk HGrg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=rPa9t2tK; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-113156-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-113156-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id fm9-20020a056a002f8900b006e5f7e04915si4034612pfb.159.2024.03.24.17.03.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Mar 2024 17:03:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-113156-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=rPa9t2tK; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-113156-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-113156-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 sv.mirrors.kernel.org (Postfix) with ESMTPS id ABA5B282C4E for ; Sun, 24 Mar 2024 23:32:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BD51217265E; Sun, 24 Mar 2024 22:39:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="rPa9t2tK" 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 C6EA5172635; Sun, 24 Mar 2024 22:39:18 +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=1711319958; cv=none; b=b950t6KY73cTw6OsYo5dpMAVQdq3v1PfFYdtL+C35AnWW6YsLMkn1Y9Bg1hQTCg6a8wePQHD02gvbYFB/T3j+ljuBe3jc0w6hHb47n+r/cfwXRtRerI08j2elR4R2FT7GEaNTwX0kpxKetOsUi/aKhi4wGiEuKCrSLz2Nv9c/8M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711319958; c=relaxed/simple; bh=qDdkBp52whbIdsEQJeQ73Fo2VF9QAYIUfc9LlJxEzNg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=YW1aAUOWy3k8KTHThpZwDiFaf6wcvS9qsbYIwb8qqUB6mutRsgaPLPDBBo0JXuSvVTqoL1jf3Vi5GqwYtGwSoZ3sSlqSsYhZ316ogtZPUQcwv9DmmzTLhLxwJDK8MRaVNAi4LxeX7UwNJURsGG+iAyjIJ7pXVyl6oSRS4Wtw0vY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=rPa9t2tK; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0DFFAC433C7; Sun, 24 Mar 2024 22:39:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1711319958; bh=qDdkBp52whbIdsEQJeQ73Fo2VF9QAYIUfc9LlJxEzNg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rPa9t2tKJr0nhCbPYgHzAS57oK111cezEV4sOEMkTIThMvXmdE1sYpZBv3Q3pflc1 XlPkFgf8xWIEDchuFOCaw9z5OX4eFfbpmLckFBVdx0Sw1Rz+ZuijsfAyMnqIhsaR9m 4DxhpZMBBS9YCw55Ua7hmoiOJOZlSlsi2mDXpIMdIe6Qdak4r2mHu911ATjXM5GzKz yoQ7VlDMDFG63VWo6EDa4WB5YK62fB8oPHUB6lZImzfVrOfTFRqTDn41lxOfdu6E5u MhQiiWw8WilEoZFnaLAlrr/bKUAU2rSGzYS7WAJ7cuL7OGke2FvUd7Jpjxxy1ybICa gwW6tDNtxzXrQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: =?UTF-8?q?Michal=20Vok=C3=A1=C4=8D?= , Shawn Guo , Sasha Levin Subject: [PATCH 6.8 265/715] ARM: dts: imx6dl-yapp4: Move the internal switch PHYs under the switch node Date: Sun, 24 Mar 2024 18:27:24 -0400 Message-ID: <20240324223455.1342824-266-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240324223455.1342824-1-sashal@kernel.org> References: <20240324223455.1342824-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit From: Michal Vokáč [ Upstream commit 79978bff2e4b8e05ebdf5fc3ee6b794002393484 ] We identified that the PHYs actually do not work since commit 7da7b84fee58 ("ARM: dts: imx6dl-yapp4: Move phy reset into switch node") as a coincidence of several circumstances. The reset signal is kept asserted by a pull-down resistor on the board unless it is deasserted by GPIO from the SoC. This is to keep the switch dead until it is configured properly by the kernel and user space. Prior to the referenced commit the switch was reset by the FEC driver and the reset GPIO was actively deasserted. The mdio-bus was scanned and the attached switch and its PHYs were found and configured. With the referenced commit the switch is reset by the qca8k driver. Because of another bug in the qca8k driver, functionality of the reset pin depends on its pre-kernel configuration. See commit c44fc98f0a8f ("net: dsa: qca8k: fix illegal usage of GPIO") The problem did not appear until we removed support for the switch and configuration of its reset pin from the bootloader. To fix that, properly describe the internal mdio-bus configuration of the qca8334 switch. The PHYs are internal to the switch and sit on its internal mdio-bus. Fixes: 7da7b84fee58 ("ARM: dts: imx6dl-yapp4: Move phy reset into switch node") Signed-off-by: Michal Vokáč Signed-off-by: Shawn Guo Signed-off-by: Sasha Levin --- .../boot/dts/nxp/imx/imx6dl-yapp4-common.dtsi | 23 ++++++++++++------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/arch/arm/boot/dts/nxp/imx/imx6dl-yapp4-common.dtsi b/arch/arm/boot/dts/nxp/imx/imx6dl-yapp4-common.dtsi index d2b3e09eb7df8..c32ea040fecdd 100644 --- a/arch/arm/boot/dts/nxp/imx/imx6dl-yapp4-common.dtsi +++ b/arch/arm/boot/dts/nxp/imx/imx6dl-yapp4-common.dtsi @@ -117,14 +117,6 @@ mdio { #address-cells = <1>; #size-cells = <0>; - phy_port2: phy@1 { - reg = <1>; - }; - - phy_port3: phy@2 { - reg = <2>; - }; - switch@10 { compatible = "qca,qca8334"; reg = <0x10>; @@ -149,15 +141,30 @@ fixed-link { eth2: port@2 { reg = <2>; label = "eth2"; + phy-mode = "internal"; phy-handle = <&phy_port2>; }; eth1: port@3 { reg = <3>; label = "eth1"; + phy-mode = "internal"; phy-handle = <&phy_port3>; }; }; + + mdio { + #address-cells = <1>; + #size-cells = <0>; + + phy_port2: ethernet-phy@1 { + reg = <1>; + }; + + phy_port3: ethernet-phy@2 { + reg = <2>; + }; + }; }; }; }; -- 2.43.0