[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <be74776d-7ed7-a92b-815d-f4604debe94a@phrozen.org>
Date: Tue, 13 Sep 2016 21:10:19 +0200
From: John Crispin <john@...ozen.org>
To: Andrew Lunn <andrew@...n.ch>,
Vivien Didelot <vivien.didelot@...oirfairelinux.com>
Cc: "David S. Miller" <davem@...emloft.net>,
Florian Fainelli <f.fainelli@...il.com>,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
qsdk-review@....qualcomm.com
Subject: Re: [PATCH 3/3] net-next: dsa: add new driver for qca8xxx family
On 13/09/2016 21:07, Andrew Lunn wrote:
>> Since the former alternative is prefered, we may want to remove the
>> latter soon from DSA. If this phy_port_map is needed for that case, it'd
>> be preferable not to add it.
>
> O.K, so maybe we should solve it the device tree way:
>
>
> &mdio0 {
> phy_port1: phy@0 {
> reg = <0>;
> };
>
> phy_port2: phy@1 {
> reg = <1>;
> };
>
> phy_port3: phy@2 {
> reg = <2>;
> };
>
> phy_port4: phy@3 {
> reg = <3>;
> };
>
> phy_port5: phy@4 {
> reg = <4>;
> };
>
> switch@0 {
> compatible = "qca,qca8337";
>
> #address-cells = <1>;
> #size-cells = <0>;
> reg = <30>;
>
> ports {
> port@11 {
> reg = <11>;
> label = "cpu";
> ethernet = <&gmac1>;
> phy-mode = "rgmii";
> };
>
> port@1 {
> reg = <1>;
> label = "lan1";
> phy-handle = <&phy_port1>;
> };
>
> port@2 {
> reg = <2>;
> label = "lan2";
> phy-handle = <&phy_port2>;
> };
>
> port@3 {
> reg = <3>;
> label = "lan3";
> phy-handle = <&phy_port3>;
> };
>
> port@4 {
> reg = <4>;
> label = "lan4";
> phy-handle = <&phy_port4>;
> };
> };
> };
> };
>
> and remove the phy_read() and phy_write() functions.
>
>
> Andrew
>
Hi Andrew
ok, will give it a spin in the morning and add a note to the binding doc
explaining this. thanks for taking the time !
John
Powered by blists - more mailing lists