Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754269AbdHYQp3 (ORCPT ); Fri, 25 Aug 2017 12:45:29 -0400 Received: from mail-qt0-f193.google.com ([209.85.216.193]:33334 "EHLO mail-qt0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751905AbdHYQp1 (ORCPT ); Fri, 25 Aug 2017 12:45:27 -0400 Subject: Re: [PATCH] net: stmmac: Handle possible fixed-link with need_mdio_ids To: Andrew Lunn , Corentin Labbe Cc: peppe.cavallaro@st.com, alexandre.torgue@st.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170825144208.24503-1-clabbe.montjoie@gmail.com> <20170825162827.GA4207@lunn.ch> From: Florian Fainelli Message-ID: <0e914e7f-3231-66e4-07fb-dd0bea5838a8@gmail.com> Date: Fri, 25 Aug 2017 09:45:23 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170825162827.GA4207@lunn.ch> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1266 Lines: 46 On 08/25/2017 09:28 AM, Andrew Lunn wrote: > On Fri, Aug 25, 2017 at 04:42:08PM +0200, Corentin Labbe wrote: >> In case of fixed link, there are no mdio node. >> This patch add a test for fixed-link for bypassing MDIO node register. > > The two are not mutually exclusive. E.g. > vf610-zii-dev.dtsi/vf610-zii-dev-rev-b.dts. It has a fixed-link on > the FEC ethernet controller, and an Ethernet switch on the MDIO bus. > > If anybody ever wants to use a switch with the stmmac, this will be > required. This is already done in the Lamobo R1 DTS file so it would be nice not to break this use case: &gmac { pinctrl-names = "default"; pinctrl-0 = <&gmac_pins_rgmii_a>; phy-mode = "rgmii"; phy-supply = <®_gmac_3v3>; status = "okay"; fixed-link { speed = <1000>; full-duplex; }; mdio { compatible = "snps,dwmac-mdio"; #address-cells = <1>; #size-cells = <0>; switch: ethernet-switch@1e { compatible = "brcm,bcm53125"; reg = <30>; #address-cells = <1>; #size-cells = <0>; > > Andrew > -- Florian