From patchwork Sun Jan 22 22:02:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Blumenstingl X-Patchwork-Id: 9531485 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 1C6AE60431 for ; Sun, 22 Jan 2017 22:04:28 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3C3A27F90 for ; Sun, 22 Jan 2017 22:04:27 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E6F1A27DCE; Sun, 22 Jan 2017 22:04:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=no version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7D0D127CF9 for ; Sun, 22 Jan 2017 22:04:27 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cVQFJ-0002Wg-Us; Sun, 22 Jan 2017 22:04:21 +0000 Received: from mail-wm0-f68.google.com ([74.125.82.68]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cVQFG-0002Hx-28 for linux-amlogic@lists.infradead.org; Sun, 22 Jan 2017 22:04:20 +0000 Received: by mail-wm0-f68.google.com with SMTP id r144so21904315wme.0 for ; Sun, 22 Jan 2017 14:03:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=WWxwWHtg4Vffdw9MwOr3mVhLE2s7oG/T14wZmIPkbi8=; b=Jde8lG3d2vLhF1rdNGA/wQ6ywDlHj+tmmE8/Z2s0j0gpM2r3HFDj9BTLnkFQO/hSMS R+zzDl6wrVYb3kJ1plgDJ8OPSBHO87xLBGPQ1kDaCAakRNkFU9dfdEkJg8m+4ZZ5wyvd K/zkosrrmbqrgxNh2xK6/23z18vXwvVEqa4dwI85YpvHQ3nK1eVR9LcYy4x4pB1mNfu+ rQ94M2DeQl5fqEhewLZXcka9LdU218jOG6FagQeaDPK5D6579KBC8X0fpRsx/PSBn5uy eu9LgnRFW+aWGK2kzFyI+lQgEma20mvGyPoCrHvojem49EApBdlGVi47uXx3/i8R1ywq cZrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=WWxwWHtg4Vffdw9MwOr3mVhLE2s7oG/T14wZmIPkbi8=; b=GTJbg85JQHZ7GCBvxO6fbO8sYhvOt8TYumXAMaphvxvD113nY1s7EDeCxX7oOhoYbw GJhaJWSwY9dxAbVKV2a3lTdH7iHMG3a89BFAkieLwyB5o5qW8Mi9XSiJ1w5cauk0YmJI bGerbC4d23R0DBVWZEQo4tB4jd3zRybFjTs85wO5DumPgsxccWsvnZW3MptFkWLt4Tl6 ai+MY/CM8OXx3KWeSclQlkH+EY8bDd3KG9JajAX7ZhcFSpUIlEcw5Japz978epyP7xxn ZqUBVfwa0TQXztGrjE/cRglj59gxemdo0V8JwPJbIDLUWtEig9oyMHv8Ja3KfU5AUeFf bytg== X-Gm-Message-State: AIkVDXIQJqSzch9KJhFdG3ri/FnVoWmNYSd73TT1oFDEZHqolzQZNJxycEBKUk0WMopvxQ== X-Received: by 10.28.198.139 with SMTP id w133mr10666526wmf.80.1485122576397; Sun, 22 Jan 2017 14:02:56 -0800 (PST) Received: from blackbox.darklights.net (p200300DCD3E0200408A0F52CBA7B1138.dip0.t-ipconnect.de. [2003:dc:d3e0:2004:8a0:f52c:ba7b:1138]) by smtp.googlemail.com with ESMTPSA id 53sm11393859wrt.20.2017.01.22.14.02.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 22 Jan 2017 14:02:55 -0800 (PST) From: Martin Blumenstingl To: davem@davemloft.net, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-amlogic@lists.infradead.org Subject: [PATCH net-next v5 1/2] net: dt-bindings: add RGMII TX delay configuration to meson8b-dwmac Date: Sun, 22 Jan 2017 23:02:45 +0100 Message-Id: <20170122220246.13602-2-martin.blumenstingl@googlemail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170122220246.13602-1-martin.blumenstingl@googlemail.com> References: <20161217182119.4037-1-martin.blumenstingl@googlemail.com> <20170122220246.13602-1-martin.blumenstingl@googlemail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170122_140418_256876_DC3D439F X-CRM114-Status: UNSURE ( 9.14 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, narmstrong@baylibre.com, Martin Blumenstingl , khilman@baylibre.com, robh+dt@kernel.org, carlo@caione.org MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This allows configuring the RGMII TX clock delay. The RGMII clock is generated by underlying hardware of the the Meson 8b / GXBB DWMAC glue. The configuration depends on the actual hardware (no delay may be needed due to the design of the actual circuit, the PHY might add this delay, etc.). Signed-off-by: Martin Blumenstingl Tested-by: Neil Armstrong Acked-by: Rob Herring --- Documentation/devicetree/bindings/net/meson-dwmac.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/Documentation/devicetree/bindings/net/meson-dwmac.txt b/Documentation/devicetree/bindings/net/meson-dwmac.txt index 89e62ddc69ca..0703ad3f3c1e 100644 --- a/Documentation/devicetree/bindings/net/meson-dwmac.txt +++ b/Documentation/devicetree/bindings/net/meson-dwmac.txt @@ -25,6 +25,22 @@ Required properties on Meson8b and newer: - "clkin0" - first parent clock of the internal mux - "clkin1" - second parent clock of the internal mux +Optional properties on Meson8b and newer: +- amlogic,tx-delay-ns: The internal RGMII TX clock delay (provided + by this driver) in nanoseconds. Allowed values + are: 0ns, 2ns, 4ns, 6ns. + When phy-mode is set to "rgmii" then the TX + delay should be explicitly configured. When + not configured a fallback of 2ns is used. + When the phy-mode is set to either "rgmii-id" + or "rgmii-txid" the TX clock delay is already + provided by the PHY. In that case this + property should be set to 0ns (which disables + the TX clock delay in the MAC to prevent the + clock from going off because both PHY and MAC + are adding a delay). + Any configuration is ignored when the phy-mode + is set to "rmii". Example for Meson6: