Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 04 Mar 2014 16:50:31 -0700
From:      Ian Lepore <ian@FreeBSD.org>
To:        Svatopluk Kraus <onwahe@gmail.com>
Cc:        freebsd-arm@FreeBSD.org
Subject:   Re: Pandaboard ES and SD card
Message-ID:  <1393977031.1149.325.camel@revolution.hippie.lan>
In-Reply-To: <CAFHCsPXRXvN1XxnM9-B3iLZ%2BU=y6UgunQY8QBdyA0xESx3C1Bw@mail.gmail.com>
References:  <CAFHCsPXRXvN1XxnM9-B3iLZ%2BU=y6UgunQY8QBdyA0xESx3C1Bw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 2014-03-03 at 17:12 +0100, Svatopluk Kraus wrote:
> Hi,
> 
> I finally have found time to install FreeBSD 11.0-CURRENT on Pandaboard ES
> on my table. It's been installed to SD card.  When I boot to multiuser,
> it's very very slow. It looks that SD card write performance is very poor.
> When I boot to singleuser, it's OK. However, when I make root filesystem
> read-write by one command and immediately readonly by second one, the
> second one takes a few minutes to finish.
> 
> When I've digged in arm/ti/ti_mmchs.s, I've got following times for READ
> and WRITE commands:
> 
> typical read times (start & duration & command),
> ...
> [1393858258.909d4fb4650dcb70] [0.002f97afec8ba994] READ
> [1393858258.929795e2f7db5ec0] [0.002f90d496ec7d4c] READ
> [1393858258.9492673f18af4ec0] [0.002f9d607a66e41c] READ
> [1393858258.968d155674da0d5e] [0.002f937e2ea37cca] READ
> [1393858258.988790d78e6fd5a2] [0.002f9eb09b235414] READ
> [1393858258.9a78744ecab1413e] [0.002f90dded2a9cda] READ
> [1393858258.9c735a3cec62b616] [0.002f97cbef46083e] READ
> [1393858258.9e6ee0b8064ec2aa] [0.002f933cd2f09fe8] READ
> [1393858258.a069e2838966634a] [0.002f959262788368] READ
> [1393858258.a26467518add9a00] [0.002f8f9722ac4c70] READ
> [1393858258.a45e59f14fb6c986] [0.002f9d31cb304656] READ
> [1393858258.a659525d3e70bc98] [0.002f8ae2ad5e65e2] READ
> [1393858258.a853df0c0452931e] [0.002f9cd46cc30aca] READ
> ...
> 
> typical write times (start & duration & command).
> ...
> [1393856255.8be604dff29d07a0] [0.00d9cf712d331d58] WRITE
> [1393856255.8e9100859c4fedd2] [0.00da3f856cebe4e6] WRITE
> [1393856255.913c1530607b6288] [0.00da8f1a826cd93a] WRITE
> [1393856255.93e7b97bcc483d9a] [0.00dad6ced3832dbe] WRITE
> [1393856255.9693e68c8a1752c0] [0.2276ea0a1d732724] WRITE     <-
> [1393856255.badca6f90c5564ea] [0.22df71f44f623e3e] WRITE     <-
> [1393856255.df8e42a6890234a4] [0.24ae2f1172203ed0] WRITE     <-
> [1393856256.060e4c7acd0c290a] [0.00e76cb09c67c3ba] WRITE
> [1393856256.08c68da8b0554498] [0.00e7b1d75881776a] WRITE
> [1393856256.0b7f57d3eb15578e] [0.00e83c08cdfa8020] WRITE
> [1393856256.0e36d38be88f1e08] [0.00e882dd093ddf54] WRITE
> [1393856256.10f0762d8d8cbe10] [0.00e8c0f06a43a968] WRITE
> [1393856256.13aa6a2dc9ef5c9a] [0.00e938916637f4c8] WRITE
> [1393856256.1664fc08109773d4] [0.22b74fce5c0401e2] WRITE     <-
> [1393856256.3aedb9baa4273c8e] [0.2305517892cef37c] WRITE     <-
> [1393856256.5fc52a62081f2238] [0.24aaf338d2067a84] WRITE     <-
> [1393856256.8641d9129fd99066] [0.00e770cfadd3b168] WRITE
> [1393856256.88fae819e4c25a9c] [0.04d7472f5f571cbc] WRITE
> ...
> 
> Times are struct bintime printed in %lld.%016llx (sec.frac) format.
> 
> Writing times have got really big variation.
> Any idea or experience?
> 
> Svatopluk Kraus
> 
>  PS. Of course, I don't mention occasional "Spurious interrupt detected"
> print.

The ti_mmchs driver does all IO one sector at a time, and single-sector
writes are the worst case for sdcard performance.  I've seen
single-sector writes go as slow as 20K/sec.

Try switching to the ti_sdhci driver (switch the entry in files.omap4).
I don't know for sure that ti_sdhci will work with pandaboard, it's only
been tested on beaglebone that I know of.  But if it works you should
see read speeds around 16MB/sec and writes at about 7MB/sec.

The "mount -uw / ; mount -ur /" is a completely separate thing.  That
takes about 30 seconds on every sdcard-based system I have.  I don't
know why, but it's really annoying.  I don't think it's a driver thing,
it happens with several different drivers.

-- Ian





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