lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 15 Mar 2017 14:19:04 -0700
From:   Florian Fainelli <florian.fainelli@...adcom.com>
To:     Vivek Unune <npcomplete13@...il.com>
Cc:     Andrew Lunn <andrew@...n.ch>, hauke@...ke-m.de, zajec5@...il.com,
        bcm-kernel-feedback-list@...adcom.com, robh+dt@...nel.org,
        mark.rutland@....com, linux@...linux.org.uk,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH] ARM: dts: BCM5301X: Add support for Linksys EA9500

On 03/15/2017 01:18 PM, Vivek Unune wrote:
> Thanks Florian.
> 
> Let me try this out. First I'll try to figure out how to add a mdio node.
> 
> Over the weekend I was trying enable DSA driver, but did not see DSA
> under network. I'm using LEDE source with kernel 4.9. Nor did I see it
> when I tried 'make kernel_menuconfig'

(please don't top post on public mailing lists)

You need to enable SWITCHDEV to have DSA. AFAIR SWITCHDEV may depend on
EXPERT/EXPERIMENTAL as of 4.9 (or that was before).

> 
> Thanks again.
> 
> On Wed, Mar 15, 2017 at 3:49 PM, Florian Fainelli
> <florian.fainelli@...adcom.com> wrote:
>> On 03/15/2017 12:34 PM, Vivek Unune wrote:
>>> Andrew,
>>>
>>> I'm not entirely sure. But here is what I observed.
>>>
>>> Boot loader sets up both the switches. And I can use all 8 ports of the
>>> router when I boot Lede. Only the internal swich is detected and
>>> configurable via swconfig tool
>>> Internal switch is connected to CPU via port 5 same as Netgear R8000.
>>> The other bit here is that I looked through the GPL source and gpio pin
>>> 10 is labeled as EA9500_RST2LANSW_GPIO10_PIN/ResetSwitch. So when I
>>> performed a robo reset of the pin and 5 (labeled 1 thru 5 on the unit)
>>> of the 8 physical ports stopped working (no packets).
>>>
>>> If the external switch were to be connect via dedicated ethernet
>>> interface it should have shown up during the probe. Is in't it?
>>
>> Not necessarily, and probably not with LEDE which would treat the
>> external 53125 as a dumb switch and not even see it. With a mainline
>> kernel and the B53 DSA driver you would be able to represent both
>> switches in Device Tree and describe how they are cascading from each other.
>>
>> The potential Device Tree changes could look like this (based on your
>> explanation, but I am not sure) for your platform, assuming the 53125 is
>> actually exposing the front panel ports and that we did introduce a
>> "mdio" node which would be required to expose the external BCM53125 switch.
>>
>>
>> /* There is no MDIO node, there should be one */
>> &mdio {
>>         status = "okay";
>>
>>         switch@30 {
>>                 #address-cells = <1>;
>>                 #size-cells = <0>;
>>                 reset-gpios = <&gpio 10>;
>>                 reset-names = "robo_reset";
>>
>>                 ports {
>>                         #address-cells = <1>;
>>                         #size-cells = <0>;
>>
>>                         port@0 {
>>                                 reg = <0>;
>>                                 label = "lan1";
>>                         };
>>
>>                         port@1 {
>>                                 reg = <1>;
>>                                 label = "lan2";
>>                         };
>>
>>                         port@2 {
>>                                 reg = <2>;
>>                                 label = "lan3";
>>                         };
>>
>>                         port@3 {
>>                                 reg = <3>;
>>                                 label = "lan1";
>>                         };
>>
>>                         port@4 {
>>                                 reg = <4>;
>>                                 label = "wan";
>>                         };
>>
>>                        port@5 {
>>                                 reg = <5>;
>>                                 label = "cpu";
>>                                 ethernet = <&sw0port8>;
>>                                 fixed-link {
>>                                         speed = <1000>;
>>                                         full-duplex;
>>                                 };
>>                         };
>>                 };
>>         };
>> };
>>
>> &srab {
>>         status = "okay";
>>
>>         ports {
>>                 #address-cells = <1>;
>>                 #size-cells = <0>;
>>
>>                 port@5 {
>>                         reg = <5>;
>>                         label = "cpu";
>>                         ethernet = <&gmac0>;
>>                         fixed-link {
>>                                 speed = <1000>;
>>                                 full-duplex;
>>                         };
>>                 };
>>
>>                 sw0port8: port@8 {
>>                         reg = <8>;
>>                         label = "extswitch";
>>
>>                         fixed-link {
>>                                 speed = <1000>;
>>                                 full-duplex;
>>                         };
>>                 };
>>         };
>> };
>>
>>>
>>> Thanks,
>>>
>>> Vivek
>>>
>>>
>>> On Wed, Mar 15, 2017 at 2:52 PM Andrew Lunn <andrew@...n.ch
>>> <mailto:andrew@...n.ch>> wrote:
>>>
>>>     Hi Vivek
>>>
>>>     > - It has two switches in order to support 8 lan ports. Internal
>>>     switch is
>>>     >   BCM53012. The external switch BCM53125 currently works as "dumb
>>>     switch"
>>>
>>>     Do you know how the second switch is connected? Is it cascaded off the
>>>     internal switch? Or does it have a dedicated Ethernet interface?
>>>
>>>     Thanks
>>>             Andrew
>>>
>>
>>
>> --
>> Florian


-- 
Florian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ