TS-4600 Ethernet: Difference between revisions

From embeddedTS Manuals
(Created page with "The Freescale Processor implements a 10/100 ethernet controller with support built into the Linux kernel. The TS-4600 includes an integrated Marvell Ethernet switch that allo...")
 
(Clean up, add note on behavior, expand information, remove unused information.)
 
Line 1: Line 1:
The Freescale Processor implements a 10/100 ethernet controller with support built into the Linux kernel.  The TS-4600 includes an integrated Marvell Ethernet switch that allows multiple interfaces from one 10/100 port.  This allows a total bandwidth of 100MB/s between both ports.
The CPU implements a 10/100 ethernet controller with support built into the Linux kernel.  This device also includes an integrated Marvell Ethernet switch that allows multiple interfaces from one 10/100 port.  This allows a total bandwidth of 100 MB/s between both ports.
 
{{Note|For the first few seconds after power on, the switched Ethernet ports are in switch mode and will forward STP packets. This can cause some switches to block this Ethernet port before the ports are set up in VLAN mode. Contact us for more details.}}
 


{|
{|
| [[File:EthSwitch.png]]
| [[File:EthSwitch.png]]
|}
|}
 
The default configuration will have the ports act as 2 individual ports on baseboards where this is supported.  When in this mode all network traffic should be directed to <source inline>eth0.1</source> and <source inline>eth0.2</source>, but not <source inline>eth0</source> which will not be forwarded outside of the switch.  When using the network with the VLAN mode, do not make any configuration changes to <source inline>eth0</source>, instead only use <source inline>eth0.1</source> or <source inline>eth0.2</source>. On baseboards where the second Ethernet port supports the VLAN ethernet (see note below), <source inline>/ts/config</source> can be modified to enable Switch mode of the two ports allowing them to behave as a layer 2 Ethernet switch transparently.
The default configuration will have the ports act as 2 individual ports on baseboards where this is supported.  When in this mode all network traffic should be directed to eth0.1 and eth0.2, but not eth0 which will not be forwarded outside of the switch.  On baseboards where the second port supports the VLAN ethernet, you can set soft jumper #2 to switch from vlan mode to switch mode.
<source lang=bash>
<source lang=bash>
tshwctl --setjp 2
## These boards include an onboard switch with 2 external ports.  By default
## the switch will detect if it is on a known baseboard that supports the second
## ethernet switch port, and set up VLAN rules to define eth0.1 and eth0.2.  The
## other option is to configure the switch to pass through the packets to eth0
## regarless of port.
## 2 Disable VLAN and pass through to eth0
## 1 Enable VLAN on all baseboards
## 0 Enable VLAN on supported baseboards (Default)
CFG_2ETH="2"
</source>
</source>
On the next boot the eth0.1 and eth0.2 ports will not be present.  In this case the switch is configured to transparently pass through packets rather than configuring the VLANs, so eth0 should be used.
On the next boot the <source inline>eth0.1</source> and <source inline>eth0.2</source> ports will not be present but only an <source inline>eth0</source>.  In this case the switch is configured to transparently pass through packets rather than configuring the VLANs.
 
{{Note|Some baseboards create 2 Ethernet ports using a USB Ethernet controller which will only transparently pass packets through the switch.  This includes the TS-8100, TS-8390, and TS-8900.}}


You can use standard Linux utilities such as ifconfig/ip to control eth0 and the vlan interfaces. See the [[#Configuring the Network]] section for more details.  For the specifics of this interface see the [http://www.marvell.com/application-processors/armada-100/assets/armada_16x_software_manual.pdf CPU manual].
{{Note|Some baseboards create 2 Ethernet ports using a USB Ethernet device rather than a connection to the switch IC. This means that the second Ethernet port is not connected to the switch IC and these ports can only ever be used as separate interfaces. Products that use USB Ethernet for the second port include the TS-8100, TS-8390, and TS-8900.}}


The switch ports can also use tshwctl to detect link and the negotiated link speed:
The switch ports can also use <source inline>tshwctl</source> to detect link and the negotiated link speed:
   root@ts4600-f7c0ff:~# tshwctl --ethinfo
   root@ts4600-f7c0ff:~# tshwctl --ethinfo
   baseboard_model=0xa
   baseboard_model=0xa
Line 26: Line 34:
   switchportb_link=1
   switchportb_link=1
   switchportb_speed=100FD
   switchportb_speed=100FD
Since the default is to configure for pass-through mode, when using the TS-4600 on a custom baseboard the Ethernet VLAN configuration will need to be enabled.  For example, to manually set the network up for VLAN:
<source lang=bash>
#!/bin/sh
vconfig add eth0 1
vconfig add eth0 2
tshwctl --ethvlan
ifconfig eth0 up
ifconfig eth0.1 up
ifconfig eth0.2 up
</source>
This can be added to /ts/init to be run automatically before booting Debian/OpenEmbedded.

Latest revision as of 16:48, 29 June 2020

The CPU implements a 10/100 ethernet controller with support built into the Linux kernel. This device also includes an integrated Marvell Ethernet switch that allows multiple interfaces from one 10/100 port. This allows a total bandwidth of 100 MB/s between both ports.

Note: For the first few seconds after power on, the switched Ethernet ports are in switch mode and will forward STP packets. This can cause some switches to block this Ethernet port before the ports are set up in VLAN mode. Contact us for more details.


EthSwitch.png

The default configuration will have the ports act as 2 individual ports on baseboards where this is supported. When in this mode all network traffic should be directed to eth0.1 and eth0.2, but not eth0 which will not be forwarded outside of the switch. When using the network with the VLAN mode, do not make any configuration changes to eth0, instead only use eth0.1 or eth0.2. On baseboards where the second Ethernet port supports the VLAN ethernet (see note below), /ts/config can be modified to enable Switch mode of the two ports allowing them to behave as a layer 2 Ethernet switch transparently.

## These boards include an onboard switch with 2 external ports.  By default
## the switch will detect if it is on a known baseboard that supports the second
## ethernet switch port, and set up VLAN rules to define eth0.1 and eth0.2.  The
## other option is to configure the switch to pass through the packets to eth0
## regarless of port.
## 2 Disable VLAN and pass through to eth0
## 1 Enable VLAN on all baseboards
## 0 Enable VLAN on supported baseboards (Default)
CFG_2ETH="2"

On the next boot the eth0.1 and eth0.2 ports will not be present but only an eth0. In this case the switch is configured to transparently pass through packets rather than configuring the VLANs.

Note: Some baseboards create 2 Ethernet ports using a USB Ethernet device rather than a connection to the switch IC. This means that the second Ethernet port is not connected to the switch IC and these ports can only ever be used as separate interfaces. Products that use USB Ethernet for the second port include the TS-8100, TS-8390, and TS-8900.

The switch ports can also use tshwctl to detect link and the negotiated link speed:

 root@ts4600-f7c0ff:~# tshwctl --ethinfo
 baseboard_model=0xa
 baseboard=8900
 baseboard_rev=A
 switch_model=88E6020
 switch_ports=a b 
 switchporta_link=0
 switchporta_speed=10HD
 switchportb_link=1
 switchportb_speed=100FD