Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1024668yba; Thu, 4 Apr 2019 02:41:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqyziCUUE0sm+M3jUKQYRqx8/J8rdsyfVuFqeiXKjJBL9ogKeiDevRjoqQFfzXmYVYDRAdal X-Received: by 2002:a63:2a09:: with SMTP id q9mr4846706pgq.397.1554370873764; Thu, 04 Apr 2019 02:41:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554370873; cv=none; d=google.com; s=arc-20160816; b=YeyJi4CREr7tWcjq4nhJOQi+2DBU5gG7FbvcxSG27en2L41JzfehtGNzQYTlFxvF2I xAYR2zybrNh6HxxFj2PcFhLpXGVXLeJB3h0V1oaOHdXm4tREx8nz5spdZLMXHkEa7faO iPRrC5GS5o4ndfVSSpMiAqJdi0Od4uIybzAtxJkD72XxTKkq/74gfIDQ9VlfdFG9etcb c7lJCTpY5gy99EZFuSDtkcXS03qM8nDZJf4WY6b2CqyOTiVgfM7A7weVK+CVRmHUeY2C Ma2xgrujfc0skCrv2L9ZryQYRWA1GcUAEgdtoMPVOpbm1tPBWuAt4zDh2a/ZB5jY/F/f Bm8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=a/rL0Qe5R1HnQ5mjUzldCswmfbcJh1ZAUVeoK4R561E=; b=0vt5cUvjeyM0vHAK8Ukvc+bEtSd5ffgB6mKmgCYs+yFG/H32TSz61CgUEjydnEmCMl M7cF4bNsgDNDKVRXbH4drREgR3MW0gZ56ccIuSBHpcvyLiHrYqqSIiy2qQG3hC6OP5wr 6eDV+Vpuv2xULBpgvk6jkLiZOQ16EoY+pHgntVtcAOmAPWa+tM7TxCTSq6J0ZPQiyqRU d2M5mnK9KBjVefLRcNXz9v9Wy80F27c7lTgKWj5d0M4MRJB1fFchVc1oKOqOLMkzD521 B2zCWoN9jLDGm6PAFtfajDUPoxmyxKo+h7E+kk1OlSlwJpK0TMrOxmdbVntF4z/qbaQQ kuRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qVUs44oW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 124si10554367pgi.38.2019.04.04.02.40.58; Thu, 04 Apr 2019 02:41:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=qVUs44oW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731841AbfDDJDl (ORCPT + 99 others); Thu, 4 Apr 2019 05:03:41 -0400 Received: from mail.kernel.org ([198.145.29.99]:41376 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731831AbfDDJDk (ORCPT ); Thu, 4 Apr 2019 05:03:40 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9918B21872; Thu, 4 Apr 2019 09:03:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1554368619; bh=jknPlMK3zruLuWLgSr2M9pFe0YvwXgN/y0AaoCGFUTA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=qVUs44oWKUJuQ8h9ez3DNbiNFzDwJQYN5AYNo8XHTZ0llBinxZ3XzsHtN8RUOqoLa ui7cFVKH2b3vKC21koG+ApfpIIPCiW3kpBFg0Cf1n0WmgVtAfvg73URVbJJSUQNHwS 4LZGn1+ZMWTLttjlD75p3gZ59XdjzDtw4pU4s/Ko= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Martin Blumenstingl , Emiliano Ingrassia , =?UTF-8?q?Linus=20L=C3=BCssing?= , Kevin Hilman , Sasha Levin Subject: [PATCH 4.19 106/187] ARM: dts: meson8b: fix the Ethernet data line signals in eth_rgmii_pins Date: Thu, 4 Apr 2019 10:47:23 +0200 Message-Id: <20190404084608.248584879@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190404084603.119654039@linuxfoundation.org> References: <20190404084603.119654039@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit 29f0023d01f063feacfc404f0446905aee4f82ee ] According to the Odroid-C1+ schematics the Ethernet TXD1 signal is routed to GPIOH_5 and the TXD0 signal is routed to GPIOH_6. The public S805 datasheet shows that TXD0 can be routed to DIF_2_P and TXD1 can be routed to DIF_2_N instead. The pin groups eth_txd0_0 (GPIOH_6) and eth_txd0_1 (DIF_2_P) are both configured as Ethernet TXD0 and TXD1 data lines in meson8b.dtsi. At the same time eth_txd1_0 (GPIOH_5) and eth_txd1_1 (DIF_2_N) are configured as TXD0 and TXD1 data lines as well. This results in a bad Ethernet receive performance. Presumably this is due to the eth_txd0 and eth_txd1 signal being routed to the wrong pins. As a result of that data can only be transmitted on eth_txd2 and eth_txd3. However, I have no scope to fully confirm this assumption. The vendor u-boot sources for Odroid-C1 use the following Ethernet pinmux configuration: SET_CBUS_REG_MASK(PERIPHS_PIN_MUX_6, 0x3f4f); SET_CBUS_REG_MASK(PERIPHS_PIN_MUX_7, 0xf00000); This translates to the following pin groups in the mainline kernel: - register 6 bit 0: eth_rxd1 (DIF_0_P) - register 6 bit 1: eth_rxd0 (DIF_0_N) - register 6 bit 2: eth_rx_dv (DIF_1_P) - register 6 bit 3: eth_rx_clk (DIF_1_N) - register 6 bit 6: eth_tx_en (DIF_3_P) - register 6 bit 8: eth_ref_clk (DIF_3_N) - register 6 bit 9: eth_mdc (DIF_4_P) - register 6 bit 10: eth_mdio_en (DIF_4_N) - register 6 bit 11: eth_tx_clk (GPIOH_9) - register 6 bit 12: eth_txd2 (GPIOH_8) - register 6 bit 13: eth_txd3 (GPIOH_7) - register 7 bit 20: eth_txd0_0 (GPIOH_6) - register 7 bit 21: eth_txd1_0 (GPIOH_5) - register 7 bit 22: eth_rxd3 (DIF_2_P) - register 7 bit 23: eth_rxd2 (DIF_2_N) Drop the eth_txd0_1 and eth_txd1_1 groups from eth_rgmii_pins to fix the Ethernet transmit performance on Odroid-C1. Also add the eth_rxd2 and eth_rxd3 groups so we don't rely on the bootloader to set them up. iperf3 statistics before this change: - transmitting from Odroid-C1: 741 Mbits/sec (0 retries) - receiving on Odroid-C1: 199 Mbits/sec (1713 retries) iperf3 statistics after this change: - transmitting from Odroid-C1: 667 Mbits/sec (0 retries) - receiving on Odroid-C1: 750 Mbits/sec (0 retries) Fixes: b96446541d8390 ("ARM: dts: meson8b: extend ethernet controller description") Signed-off-by: Martin Blumenstingl Cc: Emiliano Ingrassia Cc: Linus Lüssing Tested-by: Emiliano Ingrassia Reviewed-by: Emiliano Ingrassia Signed-off-by: Kevin Hilman Signed-off-by: Sasha Levin --- arch/arm/boot/dts/meson8b.dtsi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/arm/boot/dts/meson8b.dtsi b/arch/arm/boot/dts/meson8b.dtsi index 08f7f6be7254..5b3e5c50c72f 100644 --- a/arch/arm/boot/dts/meson8b.dtsi +++ b/arch/arm/boot/dts/meson8b.dtsi @@ -207,9 +207,7 @@ groups = "eth_tx_clk", "eth_tx_en", "eth_txd1_0", - "eth_txd1_1", "eth_txd0_0", - "eth_txd0_1", "eth_rx_clk", "eth_rx_dv", "eth_rxd1", @@ -218,7 +216,9 @@ "eth_mdc", "eth_ref_clk", "eth_txd2", - "eth_txd3"; + "eth_txd3", + "eth_rxd3", + "eth_rxd2"; function = "ethernet"; }; }; -- 2.19.1