Static counters for ethernet shows Rx packets dropped Tx packet errors after network transfer

Bug #785549 reported by Harikrishna
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linaro-landing-team-samsung
Fix Released
High
Sangwook Lee

Bug Description

The static counters of Ethernet data transmission show RX packet drop while receiving and TX packet error while sending.
i.e the RX Packet dropped is increased on receive of data and the TX packet error increase after transmission.

Relevant log file is attached showing my observation.
The same in case of transfer between normal PC are having Rx packet drop and Tx error as 0

Revision history for this message
Harikrishna (s-hari) wrote :
Harikrishna (s-hari)
visibility: private → public
Changed in linaro-landing-team-samsung:
assignee: nobody → Sangwook Lee (sangwook)
status: New → Triaged
Changed in linaro-landing-team-samsung:
status: Triaged → In Progress
Revision history for this message
Sangwook Lee (sangwook) wrote :

This is my plan to tackle this problems.
let me analyse this problem in terms of network and kernel bandwidth.
1) Look into other interrupt frequencies based on OS Timer
2) need to check storage performance
( taking SD Card into consideration,maybe as mounting another memory file system..)
3) Where/who configure SRAM interface to SMSC..

Revision history for this message
Sangwook Lee (sangwook) wrote :

If you apply the attached patch, you can not see packet drops any more.

The purpose of this patch is to use 32-bit access function in smsc911x.c in terms of software.
I think that V310 CPU enables software 32-bit access function split into two 16-bit access function continuously.
Please note that SMC9115 is connected to V310 by 16bit data bus and 8bit address .

According to SMSC9115 datasheet,
it mentions that with PIO Burst Reads (nCS or nRD controlled), it can do 16work read cycle back to back.

This is testing with 32bit access function as transferring 954MB data from host target.
There is no error both RX and TX as referring to ifconfig.

===================================================
root@linaro:~# ping 192.168.0.10
PING 192.168.0.10 (192.168.0.10) 56(84) bytes of data.
64 bytes from 192.168.0.10: icmp_req=1 ttl=64 time=2.81 ms
64 bytes from 192.168.0.10: icmp_req=2 ttl=64 time=0.333 ms
64 bytes from 192.168.0.10: icmp_req=3 ttl=64 time=0.511 ms
^C
--- 192.168.0.10 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 0.333/1.221/2.819/1.132 ms
root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:192.168.0.20 Bcast:192.168.0.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:5 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:414 (414.0 B) TX bytes:378 (378.0 B)
          Interrupt:197

root@linaro:~# scp dev@192.168.0.10:/home/dev/linaro/tmp/sample954MB.tar .
dev@192.168.0.10's password:
sample954MB.tar 100% 954MB 3.5MB/s 04:30
root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:192.168.0.20 Bcast:192.168.0.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:702245 errors:0 dropped:82 overruns:0 frame:0
          TX packets:142584 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1048387260 (1.0 GB) TX bytes:10274318 (10.2 MB)
          Interrupt:197

====================================================

Revision history for this message
Harikrishna (s-hari) wrote :
Download full text (3.9 KiB)

By applying the above patch, there is no error both RX and TX as referring to ifconfig.
But the drop packet during RX is still there .
The above also show that ,dropped packet count in RX has increased after the transfer
 "RX packets:702245 errors:0 dropped:82 overruns:0 frame:0"

we can observe the same in the below log

===================================================

root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::280:ff:fe23:4567/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:18 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3806 (3.8 KB) TX bytes:5800 (5.8 KB)
          Interrupt:197

root@linaro:~# scp 10.10.10.24:/home/hari/Apps_Linux/root_* .
root@10.10.10.24's password:
root_ajitcramfs.tar 67% 513MB 6.3MB/s 00:38 ETACorrupted MAC on input.
Disconnecting: Packet corrupt
lost connection
root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::280:ff:fe23:4567/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:378883 errors:0 dropped:73 overruns:0 frame:0
          TX packets:71676 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:570907973 (570.9 MB) TX bytes:5089827 (5.0 MB)
          Interrupt:197

root@linaro:~# scp 10.10.10.24:/home/hari/Apps_Linux/root_* .
root@10.10.10.24's password:
root_ajitcramfs.tar 100% 758MB 6.2MB/s 02:02
root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::280:ff:fe23:4567/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:931510 errors:0 dropped:120 overruns:0 frame:0
          TX packets:184108 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1404253396 (1.4 GB) TX bytes:12997456 (12.9 MB)
          Interrupt:197

root@linaro:~# scp 10.10.10.24:/home/hari/Apps_Linux/root_* .
root@10.10.10.24's password:
root_ajitcramfs.tar 100% 758MB 6.6MB/s 01:55
root@linaro:~# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:80:00:23:45:67
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::280:ff:fe23:4567/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:1482567 errors:0 dropped:229 overruns:0 frame:0
          TX packets:292427 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:2236736621 (2.2 GB) TX bytes:20556379 (20.5 MB)
          Interrupt:197

root@linaro:~# scp root_ajitcramfs.tar 10.10.10.24...

Read more...

Revision history for this message
Harikrishna (s-hari) wrote :

The same can be observed on the origen board using the hwpack_linaro-lt-origen_20110822-0_armel_supported.tar.gz (having linaro linux 3.0 ).
It shows drop count on RX

 ifconfig
eth0 Link encap:Ethernet HWaddr 00:00:70:01:0e:2a
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::200:70ff:fe01:e2a/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:1957 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1009 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:913135 (913.1 KB) TX bytes:124112 (124.1 KB)

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:16436 Metric:1
          RX packets:71 errors:0 dropped:0 overruns:0 frame:0
          TX packets:71 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:7074 (7.0 KB) TX bytes:7074 (7.0 KB)

root@linaro-desktop:/# scp 10.10.10.24:/home/hari/hwpack* .
root@10.10.10.24's password:
hwpack_linaro-lt-origen_20110819-1108_armel_s 100% 3569KB 713.8KB/s 00:05
root@linaro-desktop:/# ifconfig
eth0 Link encap:Ethernet HWaddr 00:00:70:01:0e:2a
          inet addr:10.10.10.32 Bcast:10.10.10.255 Mask:255.255.255.128
          inet6 addr: fe80::200:70ff:fe01:e2a/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:4512 errors:0 dropped:9 overruns:0 frame:0
          TX packets:2463 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:4744254 (4.7 MB) TX bytes:225419 (225.4 KB)

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:16436 Metric:1
          RX packets:71 errors:0 dropped:0 overruns:0 frame:0
          TX packets:71 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:7074 (7.0 KB) TX bytes:7074 (7.0 KB)

root@linaro-desktop:/#

Changed in linaro-landing-team-samsung:
status: In Progress → Fix Released
Usman Ahmad (usman-ah)
Changed in linaro-landing-team-samsung:
milestone: none → 2011.10
Usman Ahmad (usman-ah)
Changed in linaro-landing-team-samsung:
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.