Received: by 10.213.65.68 with SMTP id h4csp715763imn; Fri, 23 Mar 2018 14:19:21 -0700 (PDT) X-Google-Smtp-Source: AG47ELs1Bz7/+E20VgEoV/O0GIPs2ZENsQdH2/tSGqHHOy68i+5ojjdFwJ0BGVtl6woRvglADMju X-Received: by 2002:a17:902:b408:: with SMTP id x8-v6mr25002162plr.7.1521839961062; Fri, 23 Mar 2018 14:19:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521839961; cv=none; d=google.com; s=arc-20160816; b=d2rbAoJ1a3qXt1gw6jZbfW0QcGY1YOb+QBcCE3hYyEQ06ZjWtHmTyzTdMZzSlwCVv/ yCNDswD30oc+3kgMClOjYPH34poOV/yaSnpFXrrdDMiqCXSq0d/Yz5EQ6BR39s9eIr4z YTF2QzENn6tMgLu7i0uQfgru0foWwaYE9pCxk0aGky52g2l4K9sFAeEI1RebbSob5XhT U71GdanI7MNYEGAekxH1D5WX+Nd4UyAl3Ec9wjs2hm4aOf7g/+hAloPaGmeouO4e2awZ Ft1+4ZCpvN+kJBwoO3CejAtnJI4AoA90yyxpy2bz/Xva3JUKb5SkWV/pnatH3qfkDo14 0hjw== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=/s5wC0qI05F48i2qcZoHlKzT6rjDbiBhy/z50U3vEOY=; b=S3Uue//g/iz8V5wqsIkPQHH/kqM18fJA9tepkinQFbcox4pYOO6zJuk2Co9phQLNgy Sf1VWzk6PHPx+R44at/BdUUD+vKXFJ6NFaIxV3lt7CCBsuZ5cu7gCnzOfiZyU+YGTmYb yWKNPakN3fB7liz3vg5Y4I+bItk4IIHmQvK0CuDyP5L4hrumFwknf0zpGTCjeLVBN0eG R0D4rbfBZQILemhIEBDOaBgqylwZEvaiW3Ja6OgFyeauXLcIdBi8w8CSBOcddRRPY/p0 Ju4PNfla2NETsEePf8RqaqEFykCTyuBv2sOYAAe5A/Owp1LCEmefvK5Z9/2eyUFGp+QS 2Ntg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=rKBHzxRQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j10-v6si9915301plk.655.2018.03.23.14.19.06; Fri, 23 Mar 2018 14:19:21 -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=@gmail.com header.s=20161025 header.b=rKBHzxRQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752152AbeCWVSG (ORCPT + 99 others); Fri, 23 Mar 2018 17:18:06 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:36988 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751733AbeCWVSB (ORCPT ); Fri, 23 Mar 2018 17:18:01 -0400 Received: by mail-pf0-f196.google.com with SMTP id t16so982417pfh.4; Fri, 23 Mar 2018 14:18:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=/s5wC0qI05F48i2qcZoHlKzT6rjDbiBhy/z50U3vEOY=; b=rKBHzxRQXA7bwkmyYxtCSIefBRRdRcxRl0R+iY7icv499z+KeltfNrSTK4Z1dL2IiJ DTPEuggpcX5hx8/rbzv9YjfilbPVifSnkDiJLHN6sx+LAUSG+ZRghfRf0zT17wwC3Ugq jlNDz5gMwq+jYB/8WgD3LzJlrp6OI9IqvqMMHghq7IQECT/XU7KWy1qMnMkA925NDTqg c8x+h66ADqfJ59gq27wBXNi9Kr5N86kLotCWrKLQoNrB8kbhpCqYWEs3fP0ZR3icIvJX RhLIb/pvmQhwmjI2lVP5GXnBZDMwrHCeTFMYdn/5Fk1RZzc//VcJOQUvtYZ3GUbP9Bm4 gthQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=/s5wC0qI05F48i2qcZoHlKzT6rjDbiBhy/z50U3vEOY=; b=m2bHj67nb92ylZ48qWD+/ePHGd1XGPmWw3jC+rppbCVAiTS54vInu07o5Rs95Uni+Q OcStljjBmaCSU3VN9v7DfJ/T9wvyzD0EPIKVEz9kft8RLwp6SCOlhed/pPn82Sic3d5p mqwb1esK+a8dKuTcKAqWeW0XFW4QTd0dZw5v7WJVAjjRWdKFBKwCIGGFmpvbjZm/ENPW iDm+BKi20D2dc8OtmKhGoP0yIoM8pZRzS25jhBZLRJ2PzNB/uQ9yvy/qGz6OSvilP+JX UGc22qFXmBHV0ldTVtTYmGVSZE/wL84+x7iXSGipOdz5a4VvT67lfUACpO/r+JW0630q tIvg== X-Gm-Message-State: AElRT7Hlr2N4DyE7EuI4yZCV33hzf5FARG6B0o85Y+s087yaEXxJZ+Er s9mHYLr3SYm1PNi/q+rlq18= X-Received: by 10.99.127.88 with SMTP id p24mr7296951pgn.93.1521839880520; Fri, 23 Mar 2018 14:18:00 -0700 (PDT) Received: from [10.69.41.93] ([192.19.223.250]) by smtp.googlemail.com with ESMTPSA id l64sm21033666pfi.142.2018.03.23.14.17.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 23 Mar 2018 14:17:59 -0700 (PDT) Subject: Re: [PATCH net-next 6/8] MIPS: mscc: Add switch to ocelot To: Alexandre Belloni , "David S . Miller" Cc: Allan Nielsen , razvan.stefanescu@nxp.com, po.liu@nxp.com, Thomas Petazzoni , Andrew Lunn , netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mips@linux-mips.org, James Hogan References: <20180323201117.8416-1-alexandre.belloni@bootlin.com> <20180323201117.8416-7-alexandre.belloni@bootlin.com> From: Florian Fainelli Message-ID: Date: Fri, 23 Mar 2018 14:17:48 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180323201117.8416-7-alexandre.belloni@bootlin.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03/23/2018 01:11 PM, Alexandre Belloni wrote: > Ocelot has an integrated switch, add support for it. > > Cc: James Hogan > Signed-off-by: Alexandre Belloni > --- > arch/mips/boot/dts/mscc/ocelot.dtsi | 84 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 84 insertions(+) > > diff --git a/arch/mips/boot/dts/mscc/ocelot.dtsi b/arch/mips/boot/dts/mscc/ocelot.dtsi > index dd239cab2f9d..22a86373b1c9 100644 > --- a/arch/mips/boot/dts/mscc/ocelot.dtsi > +++ b/arch/mips/boot/dts/mscc/ocelot.dtsi > @@ -91,6 +91,69 @@ > status = "disabled"; > }; > > + switch@1010000 { > + #address-cells = <1>; > + #size-cells = <0>; > + compatible = "mscc,ocelot-switch"; > + reg = <0x1010000 0x10000>, > + <0x1030000 0x10000>, > + <0x1080000 0x100>, > + <0x10d0000 0x10000>, > + <0x11e0000 0x100>, > + <0x11f0000 0x100>, > + <0x1200000 0x100>, > + <0x1210000 0x100>, > + <0x1220000 0x100>, > + <0x1230000 0x100>, > + <0x1240000 0x100>, > + <0x1250000 0x100>, > + <0x1260000 0x100>, > + <0x1270000 0x100>, > + <0x1280000 0x100>, > + <0x1800000 0x80000>, > + <0x1880000 0x10000>; > + reg-names = "sys", "rew", "qs", "hsio", "port0", > + "port1", "port2", "port3", "port4", "port5", > + "port6", "port7", "port8", "port9", "port10", > + "qsys", "ana"; > + interrupts = <21 22>; > + interrupt-names = "xtr", "inj"; See my comment about the binding patch, this should be moved to a ports subnode so it is conforming to the existing DSA binding and makes it a lot easier to have all ports disabled by default at the .dsti level by not defini > + > + port0: port@0 { > + reg = <0>; > + }; > + port1: port@1 { > + reg = <1>; > + }; > + port2: port@2 { > + reg = <2>; > + }; > + port3: port@3 { > + reg = <3>; > + }; > + port4: port@4 { > + reg = <4>; > + }; > + port5: port@5 { > + reg = <5>; > + }; > + port6: port@6 { > + reg = <6>; > + }; > + port7: port@7 { > + reg = <7>; > + }; > + port8: port@8 { > + reg = <8>; > + }; > + port9: port@9 { > + reg = <9>; > + }; > + port10: port@10 { > + reg = <10>; > + }; > + }; > + > reset@1070008 { > compatible = "mscc,ocelot-chip-reset"; > reg = <0x1070008 0x4>; > @@ -113,5 +176,26 @@ > function = "uart2"; > }; > }; > + > + mdio0: mdio@107009c { > + #address-cells = <1>; > + #size-cells = <0>; > + compatible = "mscc,ocelot-miim"; > + reg = <0x107009c 0x36>, <0x10700f0 0x8>; > + interrupts = <14>; status = "disabled" by default? > + > + phy0: ethernet-phy@0 { > + reg = <0>; > + }; > + phy1: ethernet-phy@1 { > + reg = <1>; > + }; > + phy2: ethernet-phy@2 { > + reg = <2>; > + }; > + phy3: ethernet-phy@3 { > + reg = <3>; > + }; These PHYs should be defined at the board DTS level. -- Florian