This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PROCESSOR-SDK-DRA8X-TDA4X: VLAN setup issue in DRA829 and TDA4VM

Part Number: PROCESSOR-SDK-DRA8X-TDA4X
Other Parts Discussed in Thread: DRA829, TDA4VM

Setup:

TIDRA829/TITDA4VM target with TI SDK release 07.00.01 version connected to the Linux host machine via unmanaged switch. Latest SDK compiled with kernel config CONFIG_VLAN_8021Q enabled for both the boards. Below VLAN setup steps describes about frame based VLAN testing. Below steps and output behaviour are similar for both DRA829 and TDA4VM boards. 

Target:

VLAN setup creation in TIDRA829 target, run below commands step by step

  1. $ ip link add link eth0 name eth0.100 type vlan id 100
  2. $ ip addr add 100.65.100.31/24 dev eth0.100
  3. $ ip link set dev eth0.100 up

Verify VLAN setup in target using 'ifconfig' command,

$ifconfig

eth0 Link encap:Ethernet HWaddr 78:db:2f:e1:38:85
inet addr:192.168.1.31 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::7adb:2fff:fee1:3885/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:6329419 errors:0 dropped:0 overruns:0 frame:0
TX packets:12008110 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:6727694943 (6.2 GiB) TX bytes:15142185166 (14.1 GiB)

eth0.100 Link encap:Ethernet HWaddr 78:db:2f:e1:38:85
inet addr:100.65.100.31 Bcast:0.0.0.0 Mask:255.255.255.0
inet6 addr: fe80::7adb:2fff:fee1:3885/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5362704 errors:0 dropped:0 overruns:0 frame:0
TX packets:9838146 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:6565054000 (6.1 GiB) TX bytes:11819275392 (11.0 GiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:82 errors:0 dropped:0 overruns:0 frame:0
TX packets:82 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:6220 (6.0 KiB) TX bytes:6220 (6.0 KiB)

In the above output, it is verified that eth0.100 interface created with address 100.65.100.31 and netmask 255.255.255.0

Host:

VLAN setup creation in host, run below commands step by step

  1. $ ip link add link eth0 name eth0.100 type vlan id 100
  2. $ ip addr add 100.65.100.1/24 dev eth0.100
  3. $ ip link set dev eth0.100 up

Verify the VLAN setup in host using ifconfig command as mentioned above. 

Run iperf2 server in host,
$ ./iperf2 -s

output:

------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
[ 4] local 100.65.100.1 port 5001 connected with 100.65.100.31 port 37831
[ ID] Interval Transfer Bandwidth
[ 4] 0.0- 5.0 sec 561 MBytes 938 Mbits/sec
------------------------------------------------------------
Client connecting to 100.65.100.31, TCP port 5001
TCP window size: 280 KByte (default)
------------------------------------------------------------
[ 4] local 100.65.100.1 port 54458 connected with 100.65.100.31 port 5001
[ 4] 0.0- 5.5 sec 283 MBytes 431 Mbits/sec

 

Run iperf2 client in target,
$ ./iperf2 -c 100.65.100.1 -B 100.65.100.31 -r -t 5

------------------------------------------------------------
Server listening on TCP port 5001
Binding to local address 100.65.100.31
TCP window size: 128 KByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 100.65.100.1, TCP port 5001
Binding to local address 100.65.100.31
TCP window size: 536 KByte (default)
------------------------------------------------------------
[ 4] local 100.65.100.31 port 37831 connected with 100.65.100.1 port 5001
[ ID] Interval Transfer Bandwidth
[ 4] 0.0- 5.0 sec 561 MBytes 941 Mbits/sec
[ 4] local 100.65.100.31 port 5001 connected with 100.65.100.1 port 54458
[ 4] 0.0-10.0 sec 282 MBytes 236 Mbits/sec

 After execution of iperf test, In the TIDRA829 target, verify IP address of interface using ifconfig command and found that IP address removed after the test. Below logs taken from the TIDRA829 target.

eth0 Link encap:Ethernet HWaddr 78:db:2f:e1:38:85
inet addr:192.168.1.31 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::7adb:2fff:fee1:3885/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:6806567 errors:0 dropped:0 overruns:0 frame:0
TX packets:12965033 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:7190541952 (6.6 GiB) TX bytes:16385148227 (15.2 GiB)

eth0.100 Link encap:Ethernet HWaddr 78:db:2f:e1:38:85
inet6 addr: fe80::7adb:2fff:fee1:3885/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5802920 errors:0 dropped:0 overruns:0 frame:0
TX packets:10794904 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:7017387266 (6.5 GiB) TX bytes:13058378499 (12.1 GiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:82 errors:0 dropped:0 overruns:0 frame:0
TX packets:82 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:6220 (6.0 KiB) TX bytes:6220 (6.0 KiB)