From patchwork Wed Nov 16 20:01:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Moon X-Patchwork-Id: 21242 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp38629wrr; Wed, 16 Nov 2022 12:06:21 -0800 (PST) X-Google-Smtp-Source: AA0mqf6Smw33y9lwQfAe0WVXK09vytmnSaBtmsPiTmmEgIBhpUgql8CCX1mvsHXq4aXLz62z74sh X-Received: by 2002:aa7:df0d:0:b0:467:c68b:b06c with SMTP id c13-20020aa7df0d000000b00467c68bb06cmr13665507edy.428.1668629181709; Wed, 16 Nov 2022 12:06:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668629181; cv=none; d=google.com; s=arc-20160816; b=Z71keL8mc3H5Whh+n3LeumwBCnzOrNEp7d8e6A+W31fdC4M36ziVZAERu0KcTVKqwt 0/M0nzCRUM7jbjMEzwvO4EW3DYn/3HXcvs0v2SDey+SvnkiRo4NN9MJ2/OK2ydvV2jWx jndQbQbFKF7BvV1KUx7qmU0s53MrUFQURr4eduVPHI3qHFH0+C3zUurn0TWmmNqNA7g6 LC8J6Ii91cmnrcYZfpsBICjUuID5rwt5gceSBbRWWMSbRFuWD+I9imN2Sb0PiM94+3A5 VfvI43LDwRlhFTCMKCBiJdAOfJ7b/TWUGF/Xe++Ik7sLnu6NLWEph2rHFnpbEYwJFGe6 QL5Q== 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=gWHeg8M1ItPKLADHrX13a52utCw4BMmhpRsIIQk2Fck=; b=IfZg4X87yEEcLYVMzkLWCTgFm7qQ4YeQkyLmcTJ9INk65Sa3HtVlk6O+lPNuUoEb+F D22uAtaAbEMdvOYMdhYUu16ISHh6GqBg0XLQIA6so72Rh2p32w7V0dsSuANtZkoi07tr qKV96uZUHNI+G8YF/VORDJUTrs/BxJASfFERG4jPawf6Qxt5BJ3NgNNraLUt+3/NOUwu Ndw4ulE/91MvIDpsCq5dhET79ncFq+U5t6kg05+CmLGKom7F9HB5P4n6Y3k6i/0kBUqU JsIdtCqgcGKy3ytzibUK+OoltHvJFtt5Tn6tjOB8sYcvSNy4JO3Oa91/xZ9Qk8NBBNaV lroQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=XMsHoBVw; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id sd30-20020a1709076e1e00b00791a37e665esi16320494ejc.10.2022.11.16.12.05.57; Wed, 16 Nov 2022 12:06:21 -0800 (PST) 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=@gmail.com header.s=20210112 header.b=XMsHoBVw; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233670AbiKPUCh (ORCPT + 99 others); Wed, 16 Nov 2022 15:02:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33602 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238603AbiKPUC0 (ORCPT ); Wed, 16 Nov 2022 15:02:26 -0500 Received: from mail-pj1-x102c.google.com (mail-pj1-x102c.google.com [IPv6:2607:f8b0:4864:20::102c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BC9A63CCD; Wed, 16 Nov 2022 12:02:25 -0800 (PST) Received: by mail-pj1-x102c.google.com with SMTP id h14so17496154pjv.4; Wed, 16 Nov 2022 12:02:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=gWHeg8M1ItPKLADHrX13a52utCw4BMmhpRsIIQk2Fck=; b=XMsHoBVwkTCzyxRUnxAnS4OFKDbb1cNra2uUSHWdYCfwL9DGCbnSB80aMn0s2RiSv/ dzgPX4ZLZz7WWLKdqaz/iMX3PYvnXcUaA+GfcKYixqUqO1KRF6V8B041ZZiWqWvWJyRs KjxLQ3Vfcjq7dCBSBret8vz3d2bVmpMplOdSDnlrtGBX7rhcfTReRFbwKa2w6z8qipXe oNNaCNmgrlR5CcasYxh5HGGqk8bm9yBmpMm224JG/biPZESuByYdmSlCtPPPHnZAyWmS e1T9vGJOgXrxPr/+rnxsgCAuWmUYP8EJHeiZxmeC2YJN+4J1NmjeQn3fX8/s2XEpeBfr XUHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=gWHeg8M1ItPKLADHrX13a52utCw4BMmhpRsIIQk2Fck=; b=3hOI/UAI3J1wm7eT9Os5Rt41CTr8EFUFEq1glQefAxWBEauWPfZ3SpzWWqka+mxKDC sG1yqUog2c/9oQzIHvRoOOJbsGaBWruiv3AJVzeeQ2YBSVun2UR7AzKkJVR15HIscJbM goJvJyFzbXPUoXOn9jukw+41s0rYcID3Kf9Rgb1JiX7nNrxiGid4Vdph3SXgtvdNG+lD Pw9WrYBlMqEEc65ZEGTwYbFfvvArTc/fPCjdSJoakt21rNlgreIj+1K4+teghIg1J5E+ nILY/Zy/lkUO0Ab6oNCS/IWo9lODyBa0lNVlcz4gBEUGIBsudFneUZN4tO5WhEV1ysKf ukDw== X-Gm-Message-State: ANoB5pmxxK3fN69fihBZA9FVCeSvZe+jNt9eb1kw24yqv8mpVRxrmkSG D90zhmxccK80uHv15bIZUx1AIyfAwhn9Pg== X-Received: by 2002:a17:902:c94f:b0:188:712f:dfa5 with SMTP id i15-20020a170902c94f00b00188712fdfa5mr10049999pla.140.1668628945118; Wed, 16 Nov 2022 12:02:25 -0800 (PST) Received: from localhost.localdomain ([103.51.72.182]) by smtp.gmail.com with ESMTPSA id s18-20020a170903215200b00186a6b6350esm12423950ple.268.2022.11.16.12.02.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Nov 2022 12:02:24 -0800 (PST) From: Anand Moon To: Rob Herring , Krzysztof Kozlowski , Heiko Stuebner Cc: Anand Moon , Chukun Pan , Michael Riesch , Peter Geis , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [linux-next-v2 1/5] arm64: dts: rockchip: Fix gmac phy mode to rgmii on Rock 3A SBC. Date: Wed, 16 Nov 2022 20:01:43 +0000 Message-Id: <20221116200150.4657-2-linux.amoon@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221116200150.4657-1-linux.amoon@gmail.com> References: <20221116200150.4657-1-linux.amoon@gmail.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749684512706787111?= X-GMAIL-MSGID: =?utf-8?q?1749684512706787111?= On rk356x ethernet phy support reduced media independent interface (RMII) and reduced gigabit media independent interface (RGMII). So set the phy mode to rgmii to support clock delay, also add TX and RX delay for phy-mode. Fix following warning [ 7.365215] rk_gmac-dwmac fe010000.ethernet: Can not read property: tx_delay. [ 7.365219] rk_gmac-dwmac fe010000.ethernet: set tx_delay to 0x30 [ 7.365224] rk_gmac-dwmac fe010000.ethernet: Can not read property: rx_delay. [ 7.365228] rk_gmac-dwmac fe010000.ethernet: set rx_delay to 0x10 Signed-off-by: Anand Moon --- V2: Fix commit message and added the RX and TX clock delay. --- arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts b/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts index ea74ba32fbbd..e1c75532dcee 100644 --- a/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts +++ b/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts @@ -253,13 +253,16 @@ &gmac1 { assigned-clock-rates = <0>, <125000000>; clock_in_out = "output"; phy-handle = <&rgmii_phy1>; - phy-mode = "rgmii-id"; + phy-mode = "rgmii"; pinctrl-names = "default"; pinctrl-0 = <&gmac1m1_miim &gmac1m1_tx_bus2 &gmac1m1_rx_bus2 &gmac1m1_rgmii_clk &gmac1m1_rgmii_bus>; + + tx_delay = <0x4f>; + rx_delay = <0x26>; status = "okay"; };