Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp3497737rwb; Mon, 7 Aug 2023 14:47:19 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEPymnYYODM5EzN3vsZqYNtK5FmkPq4ezfT4VgowcQ+oZ1+bkTwR3UX8VebTWtbuPV6JiW4 X-Received: by 2002:a17:90b:fca:b0:268:46fb:df32 with SMTP id gd10-20020a17090b0fca00b0026846fbdf32mr10519407pjb.34.1691444839573; Mon, 07 Aug 2023 14:47:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691444839; cv=none; d=google.com; s=arc-20160816; b=actJpGWhGlVwjBCs4o1k5je7m4FpSQNwE6K7SV1MjtyVHv7frd+vioVSc6hhMsflt2 lnhHY/sGJqyogrie2d7tQtV2uvdzHxT3/+bwugeO0B8oFOkA8d7Vk7+YkIGYuuI8gV2C pflzPgsAQ4zzT9ge2GCDen5YPuIwbutBWTrNN1HO4CE42y4D/u+yvZ5HqiUZJR/lC464 cEoagHo/DtxPnS5bbYqbAAo5SzUPsXWoaMBW/1+4a1bVgUOzcjnVCXefsdefmS6bSRti fxPAl2h/nT9aZn7Tt4br903h3GS8/4Dj/rICY8ij/mu0gkXuQOF8ecT02gBfDWfSCFev vpNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Mxzaq+NrM+rI9BGdN8+qRzAj37dK8WvIhI/Ftci2F5g=; fh=v6UDtM1LG1pNigs7Y52IFg78NWSS5jq/R3uih93pXmc=; b=YjIwgaFAmM0xeyPRWB3joDx9UKD2eXlmMd14pu9AZZIc3yP2KNochcat8YON+mjsoO yOf89OQw4gDRZxRiRNpF48dX4syYKkSmkrYczbl+8xiLOC8rshbRsQJpa8Cn3drMA+3D ntJez6WZEWDBN9GAs9kSJvOqwPFh6dAN4nQ6aw4unWAr9Wlh3aQzLukTmPAecQUnrqFw Ji9QCxdIwib0qlGK16+XjKgF6nB1Zup2G4nx1s3BLvrX4+CPmPYN92l2RfzBI6rw6qup NLpfgbdj/EeLFmzNNFfgJVVLYhhSIL+n/qbyRCxwu2aW9W/lcCUsibkXSBG0cgUfrbyp B0gw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20221208.gappssmtp.com header.s=20221208 header.b=mrigQd5C; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s8-20020a17090ad48800b0025c1ff9cd67si6404147pju.184.2023.08.07.14.47.07; Mon, 07 Aug 2023 14:47:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20221208.gappssmtp.com header.s=20221208 header.b=mrigQd5C; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231220AbjHGTfm (ORCPT + 99 others); Mon, 7 Aug 2023 15:35:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55992 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbjHGTf1 (ORCPT ); Mon, 7 Aug 2023 15:35:27 -0400 Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 53F63172B for ; Mon, 7 Aug 2023 12:35:25 -0700 (PDT) Received: by mail-wm1-x344.google.com with SMTP id 5b1f17b1804b1-3fe32016bc8so41478105e9.1 for ; Mon, 07 Aug 2023 12:35:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20221208.gappssmtp.com; s=20221208; t=1691436924; x=1692041724; 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; bh=Mxzaq+NrM+rI9BGdN8+qRzAj37dK8WvIhI/Ftci2F5g=; b=mrigQd5CL1Q/aazYd4Cn504gRfXGrDvfjmQBuRCQFNkgA339hiTI8zwK7rlb/s+Bo8 yN2+4j//ZlsvRAQiri65N+XkK25hlCNOm+4kB2lzlJzEs5oPgBpcfG49F8Ku5lfP+gi7 vwLfkkTZkZs3fjJT6nO5yRHeOfqFO1ZKRDxGUAqbR6BNqsldhRqXS9cBpxaAtYM3/+YB 3Kjokg0XYtz3n4h61lMQ4kp+F0NLgg03sNchk4/s1GFSvxJ2DyAiXPxcc+BwvhJifRZB 2fluab9kGUYWJmItqLqLC41zDLaXe+lgkmsufzV+8DuKbytAeZdyVZ+FhRyH7Y+ksxA2 887Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691436924; x=1692041724; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Mxzaq+NrM+rI9BGdN8+qRzAj37dK8WvIhI/Ftci2F5g=; b=WwqH6MRas+gzJn0tWTKmvuUfiWAvlizLBrTbWa4VGHFIJqIxlrLa12qWJ+0a5Vq+5a d+/GmaSyyKqOuKhWHSp5lc7xF8NdvMq1AeCJuehnAQpfIx9Zje//LyMNO7SA6K/3s5V+ ln2Mg2bmXwWPLZynKO2ZQog2gZPMn0kAX3J5O+QhqkLRQPU99BwkNoDfbzIfJvi+ngya m3R+mBJPzeXECcNgVHDhOo4+QArLq0VA0iXgU+7z04HvLtPW58E6DDEghmnUP05a3d1I WhkPSMbfhDr+OFM14kGVFhJ8zv2WVQJf60ABMbayXdHNE5xhzXFrLJgaD217ybreBggk I2mA== X-Gm-Message-State: AOJu0YzzEe21zbXpfzN5AyAOSweNJ5Cg5mfu+oZbfpMWOA5Omud6MxnW XGYZ9A4JGgV86q5/QsZG6kIpOw== X-Received: by 2002:a05:600c:2283:b0:3fc:a8:dc3c with SMTP id 3-20020a05600c228300b003fc00a8dc3cmr6692479wmf.37.1691436923905; Mon, 07 Aug 2023 12:35:23 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:b3d6:9e6:79d9:37cd]) by smtp.gmail.com with ESMTPSA id q9-20020a1ce909000000b003fc04d13242sm16061488wmc.0.2023.08.07.12.35.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Aug 2023 12:35:23 -0700 (PDT) From: Bartosz Golaszewski To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Alex Elder , Srini Kandagatla , Andrew Halaney Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 5/9] arm64: dts: qcom: sa8775p-ride: move the reset-gpios property of the PHY Date: Mon, 7 Aug 2023 21:35:03 +0200 Message-Id: <20230807193507.6488-6-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230807193507.6488-1-brgl@bgdev.pl> References: <20230807193507.6488-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski Device-tree bindings for MDIO define per-PHY reset-gpios as well as a global reset-gpios property at the MDIO node level which controlls all devices on the bus. The latter is most likely a workaround for the chicken-and-egg problem where we cannot read the ID of the PHY before bringing it out of reset but we cannot bring it out of reset until we've read its ID. I have proposed a solution for this problem in 2020 but it never got upstream. Now we have a workaround in place which allows us to hard-code the PHY id in the compatible property, thus skipping the ID scanning). Let's make the device-tree for sa8775p-ride slightly more correct by moving the reset-gpios property to the PHY node with its ID put into the PHY node's compatible. Link: https://lore.kernel.org/all/20200622093744.13685-1-brgl@bgdev.pl/ Signed-off-by: Bartosz Golaszewski --- arch/arm64/boot/dts/qcom/sa8775p-ride.dts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sa8775p-ride.dts b/arch/arm64/boot/dts/qcom/sa8775p-ride.dts index 38327aff18b0..1c471278d441 100644 --- a/arch/arm64/boot/dts/qcom/sa8775p-ride.dts +++ b/arch/arm64/boot/dts/qcom/sa8775p-ride.dts @@ -279,13 +279,12 @@ mdio { #address-cells = <1>; #size-cells = <0>; - reset-gpios = <&pmm8654au_2_gpios 8 GPIO_ACTIVE_LOW>; - reset-delay-us = <11000>; - reset-post-delay-us = <70000>; - sgmii_phy: phy@8 { + compatible = "ethernet-phy-id0141.0dd4"; reg = <0x8>; device_type = "ethernet-phy"; + reset-gpios = <&pmm8654au_2_gpios 8 GPIO_ACTIVE_LOW>; + reset-deassert-us = <70000>; }; }; -- 2.39.2