Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 7 Jul 2013 13:17:32 +1000
From:      Peter Jeremy <peter@rulingia.com>
To:        Hans Petter Selasky <hselasky@c2i.net>
Cc:        freebsd-arm@freebsd.org
Subject:   USB Performance on Raspberry Pi
Message-ID:  <20130707031732.GS39302@server.rulingia.com>

next in thread | raw e-mail | index | archive | help

--sdEQJo40s7ofW8iR
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hi Hans,

USB performance on the Raspberry Pi is rather lacking.  This is important
because pretty much everything goes via USB.  Do you have any suggestions
on how to fix the bottlenecks?  I suspect one is that FreeBSD is using
PIO, whereas Linux is using DMA.

I've previously commented about the sawtooth pattern in ping times:
64 bytes from 192.168.123.231: icmp_seq=3D6 ttl=3D64 time=3D2.701 ms
64 bytes from 192.168.123.231: icmp_seq=3D7 ttl=3D64 time=3D1.465 ms
64 bytes from 192.168.123.231: icmp_seq=3D8 ttl=3D64 time=3D10.589 ms
64 bytes from 192.168.123.231: icmp_seq=3D9 ttl=3D64 time=3D9.688 ms
64 bytes from 192.168.123.231: icmp_seq=3D10 ttl=3D64 time=3D8.673 ms
64 bytes from 192.168.123.231: icmp_seq=3D11 ttl=3D64 time=3D7.330 ms
64 bytes from 192.168.123.231: icmp_seq=3D12 ttl=3D64 time=3D6.857 ms
64 bytes from 192.168.123.231: icmp_seq=3D13 ttl=3D64 time=3D5.946 ms
64 bytes from 192.168.123.231: icmp_seq=3D14 ttl=3D64 time=3D3.955 ms
64 bytes from 192.168.123.231: icmp_seq=3D15 ttl=3D64 time=3D2.079 ms
64 bytes from 192.168.123.231: icmp_seq=3D16 ttl=3D64 time=3D1.072 ms

Whereas pinging a Linux RPi gives:
round-trip min/avg/max/stddev =3D 0.276/0.373/0.455/0.049 ms

yongari@ gave me same patches for the SMSC NIC but they didn't have
any noticable effect.

And the network throughput is also well below what Linux can achieve.

If I connect an external USB disk to a Linux RPi, I get 20.6 MBps
read.  The same disk on FreeBSD RPi gives 6.3 MBps - with ~50%
interrupt time.

--=20
Peter Jeremy

--sdEQJo40s7ofW8iR
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (FreeBSD)

iEYEARECAAYFAlHY3cwACgkQ/opHv/APuIfCeQCgnwSDmyW8bWL8IdUKIt0h2vgd
StMAnRlieQOpcxqRFIWGza9bkgUc9HgC
=A3BZ
-----END PGP SIGNATURE-----

--sdEQJo40s7ofW8iR--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130707031732.GS39302>