From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751393AbdCVVM7 (ORCPT ); Wed, 22 Mar 2017 17:12:59 -0400 Received: from mail-qt0-f196.google.com ([209.85.216.196]:32899 "EHLO mail-qt0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750955AbdCVVMy (ORCPT ); Wed, 22 Mar 2017 17:12:54 -0400 Subject: Re: [PATCH] ARM: dts: sun7i: lamobo-r1: Fix CPU port RGMII settings To: Chen-Yu Tsai References: <20170319045039.6163-1-f.fainelli@gmail.com> Cc: linux-arm-kernel@vger.kernel.org, mo.ucina@gmail.com, Rob Herring , Mark Rutland , Russell King , Maxime Ripard , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "moderated list:ARM PORT" , open list From: Florian Fainelli Message-ID: <3d32f497-e875-2a55-5908-78de880640bc@gmail.com> Date: Wed, 22 Mar 2017 14:12:49 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Chen-Yu, On 03/21/2017 09:06 PM, Chen-Yu Tsai wrote: > Hi Florian, > > On Sun, Mar 19, 2017 at 12:50 PM, Florian Fainelli wrote: >> The CPU port of the BCM53125 is configured with RGMII (no delays) but >> this should actually be RGMII with transmit delay (rgmii-txid) because >> STMMAC takes care of inserting the transmitter delay. This fixes >> occasional packet loss encountered. >> >> Fixes: d7b9eaff5f0c ("ARM: dts: sun7i: Add BCM53125 switch nodes to the lamobo-r1 board") >> Reported-by: Hartmut Knaack >> Signed-off-by: Florian Fainelli >> --- >> arch/arm/boot/dts/sun7i-a20-lamobo-r1.dts | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/arch/arm/boot/dts/sun7i-a20-lamobo-r1.dts b/arch/arm/boot/dts/sun7i-a20-lamobo-r1.dts >> index 72ec0d5ae052..bbf1c8cbaac6 100644 >> --- a/arch/arm/boot/dts/sun7i-a20-lamobo-r1.dts >> +++ b/arch/arm/boot/dts/sun7i-a20-lamobo-r1.dts >> @@ -167,7 +167,7 @@ >> reg = <8>; >> label = "cpu"; >> ethernet = <&gmac>; >> - phy-mode = "rgmii"; >> + phy-mode = "rgmii-txid"; > > Just to clarify, the DT binding says: > > * "rgmii-txid" (RGMII with internal TX delay provided by the PHY, the MAC > should not add an TX delay in this case) > > I'm assuming this applies from the device node's point of view? > In this case the "PHY" is STMMAC, and the "MAC" is the switch chip? > Is that right? It's actually a MAC to MAC type of set up here, so the definition of the property kind of still applies, with the caveat that we need to make sure that if one side uses "rgmii", the other one uses "rgmii-txid" which is what is being done here. I think I typoed in the commit message in that it should read "STMMAC does not take care of inserting the transmitter delay here" which is why the switch must do it. Thanks! -- Florian