We have a few versions of AM3517-powered dev kits, a CompuLab CM-T3517 and a Technexion TAM-3517, and are in the process of evaluating their Ethernet performance using a fairly current version of u-boot and the linux-omap kernel. So far the EMAC is performing nicely. We are seeing test TCP throughputs around the 80Mbps+ mark. The other adapter, based on the SMSC LAN911x attached via the GPMC, is not performing anywhere near that mark. It's averaging ~33 - 45Mbps tops.
Whenever we run any test, no matter how light, we notice a 1 - 2% of our packets are being dropped. As best we can tell, this clearly points to the GPMC interface not being setup properly. The result below came from a single 10 sec TCP iperf run.
eth0 Link encap:Ethernet HWaddr xx:xx:xx:xx:xx:xx
inet addr:192.168.x.2 Bcast:192.168.x.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:29210 errors:0 dropped:481 overruns:0 frame:0
TX packets:17366 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:44209380 (42.1 MiB) TX bytes:937744 (915.7 KiB)
Interrupt:57
We have noted that in u-boot, the default configuration for our setup, using CS5, is based on the old settings in <u-boot>/arch/arm/include/asm/arch-omap3/mem.h:
#define NET_GPMC_CONFIG1 0x00001000
#define NET_GPMC_CONFIG2 0x001e1e01
#define NET_GPMC_CONFIG3 0x00080300
#define NET_GPMC_CONFIG4 0x1c091c09
#define NET_GPMC_CONFIG5 0x04181f1f
#define NET_GPMC_CONFIG6 0x00000FCF
#define NET_GPMC_CONFIG7 0x00000f6c
Meanwhile, the newer versions of the gpmc-smsc911x driver (.<u-boot>/arch/arm/include/asm/arch-omap3/omap_gpmc.h) commonly used on popular parts such as the Gumstix Overo line are setting things up like this:
#define NET_LAN9221_GPMC_CONFIG1 0x00001000
#define NET_LAN9221_GPMC_CONFIG2 0x00060700
#define NET_LAN9221_GPMC_CONFIG3 0x00020201
#define NET_LAN9221_GPMC_CONFIG4 0x06000700
#define NET_LAN9221_GPMC_CONFIG5 0x0006090A
#define NET_LAN9221_GPMC_CONFIG6 0x87030000
#define NET_LAN9221_GPMC_CONFIG7 0x00000f6c
Everything in red is inconsistent. Looking through all the documentation we can find for our dev. kits, the Gumstix, etc. we believe everything should be basically setup the same. The schematics appear extremely close. Only a few minor differences. The Gumstix products are using the LAN9221 while the Twister is using the LAN9220, but those 2 parts share a datasheet from SMSC. So, I have to believe that we're basically using the same parts wired up the same way.
We are presently playing with our TAM-3517/Twister board. So these comments relate to that. We tried directly running running with these LAN9221 settings on that platform instead of the NET_GPMC ones. Unfortunately, that resulted in a nasty kernel oops. Oddly, the oops appeared during a USB step, complaining about 'khubd'. I can post it if it would be helpful, but it's a rather long one so I won't spam it here right now.
I started slowly playing with these settings a bit, mostly by swapping 1 line at a time, but as predicted things got quite weird quickly whenever I did that.
I haven't noticed any critical differences between the AM35xx's and the OM35xx's GPMC. Any thoughts on why there appears to be this variance between processors? Also, any recommended settings?