This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: ethernet performance <TCPIP guru question>
On Thu, Apr 25, 2002 at 05:36:02PM +0200, Roland Caßebohm wrote:
> The ethernet controller (integrated in the Samsung S3C4510
> (KS32C50100)) on my board does DMA too.
Yes, but it doesn't do scatter/gather, so you've still doing
memcpy() operations to transfer data between the BSD buffer
lists and the DMA buffers used by the 4510 DMA controller.
> The LEDs of the PHY-chip indicates 100 MBit/s, but I think
> something is wrong. Everytime when there is traffic on the net
> the LEDs indicates collisions, also if I have connected the two
> machines directly together.
It sounds like a half/full duplex problem. If the MAC is in
full duplex mode but the PHY is in half-duplex mode, you get
lots of "collisions" and dropped packets. Try forcing the MAC
to half-duplex mode, which will (AFAICT) work even if the PHY
is in full-duplex mode.
Also, if you're using the Ethernet driver I wrote, make sure
that software Ethernet CRC validation on receive packets is
disabled. The S3C4510 does Ethernet CRC in hardware (correctly).
I don't know what version of gcc you're using, but with 2.95.2
compiling the IP checksum routine on ARM7 with optimization
enabled results in regsiter-thrashing that causes -O2 or -O3
code to be about 100% larger and 50% slower than -O0 code.
I re-wrote IP checksum in assembly language and saw a big
improvement in CPU usage, and a modest improvement in
throughput. Holler if you want a copy to play with.
--
Grant Edwards
grante@visi.com
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss