On Saturday 05 March 2011 00:55:29 Philippe De Muyter wrote:
I have read with interest your article in lwn, and decided to try your flashbench program to discover the characteristics of the CF card we use.
Unfortunately,
./flashbench -a -b 1K /dev/sdb
fails with endless :
time_read: Invalid argument
Looking with strace, I get e.g.:
pread64(3, 0xb3728000, 1, 1023410175) = -1 EINVAL (Invalid argument)
Is that a behavior you can explain (and fix) ?
Yes, there are two known problems that I need to fix:
1. flashbench uses O_DIRECT for talking to the device, which means that all accesses must be on multiples of full sectors based on the underlying device sector size. It should detect this
2. command line arguments currently need to be natural numbers. There is no parser for interpreting arguments like 1K or 4M as kilobytes and megabytes.
It should work when you do
./flashbench -a -b 1024 /dev/sdb
Arnd
Hi Arnd,
On Sat, Mar 05, 2011 at 10:16:45AM +0100, arnd.bergmann@linaro.org wrote:
On Saturday 05 March 2011 00:55:29 Philippe De Muyter wrote:
I have read with interest your article in lwn, and decided to try your flashbench program to discover the characteristics of the CF card we use.
Unfortunately,
./flashbench -a -b 1K /dev/sdb
fails with endless :
time_read: Invalid argument
Looking with strace, I get e.g.:
pread64(3, 0xb3728000, 1, 1023410175) = -1 EINVAL (Invalid argument)
Is that a behavior you can explain (and fix) ?
Yes, there are two known problems that I need to fix:
- flashbench uses O_DIRECT for talking to the device, which means that
all accesses must be on multiples of full sectors based on the underlying device sector size. It should detect this
- command line arguments currently need to be natural numbers. There
is no parser for interpreting arguments like 1K or 4M as kilobytes and megabytes.
Oops. Sorry and thanks for the quick answer.
It should work when you do
./flashbench -a -b 1024 /dev/sdb
Arnd
Of course it works better now, but I cannot get rid of an error message at startup :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 1024 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 339µs on 338µs post 339µs diff -694ns align 33554432 pre 340µs on 338µs post 337µs diff -687ns align 16777216 pre 339µs on 338µs post 338µs diff -768ns align 8388608 pre 337µs on 337µs post 339µs diff -686ns align 4194304 pre 340µs on 341µs post 341µs diff 77ns align 2097152 pre 339µs on 340µs post 337µs diff 2.23µs align 1048576 pre 340µs on 341µs post 339µs diff 2.09µs align 524288 pre 338µs on 341µs post 339µs diff 2.21µs align 262144 pre 341µs on 340µs post 339µs diff 572ns align 131072 pre 341µs on 339µs post 339µs diff -211ns align 65536 pre 340µs on 341µs post 337µs diff 2.29µs align 32768 pre 341µs on 343µs post 342µs diff 1.69µs align 16384 pre 342µs on 343µs post 341µs diff 1.97µs align 8192 pre 340µs on 341µs post 339µs diff 1.43µs align 4096 pre 342µs on 343µs post 340µs diff 2.22µs align 2048 pre 342µs on 343µs post 342µs diff 1.41µs tmp179:/home/lcr/flashbench #
I have stopped apparmor, but that didn't make the message disappear. Are the outputs still meaningfull ?
Philippe
On Monday 07 March 2011 16:31:36 Philippe De Muyter wrote:
Of course it works better now, but I cannot get rid of an error message at startup :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 1024 /dev/sdb sched_setscheduler: Operation not permitted
I think on some distros, doing a simple 'su' will not give you all the capabilies. Try 'su -' or 'sudo -s' instead.
align 67108864 pre 339µs on 338µs post 339µs diff -694ns align 33554432 pre 340µs on 338µs post 337µs diff -687ns align 16777216 pre 339µs on 338µs post 338µs diff -768ns align 8388608 pre 337µs on 337µs post 339µs diff -686ns align 4194304 pre 340µs on 341µs post 341µs diff 77ns align 2097152 pre 339µs on 340µs post 337µs diff 2.23µs align 1048576 pre 340µs on 341µs post 339µs diff 2.09µs align 524288 pre 338µs on 341µs post 339µs diff 2.21µs align 262144 pre 341µs on 340µs post 339µs diff 572ns align 131072 pre 341µs on 339µs post 339µs diff -211ns align 65536 pre 340µs on 341µs post 337µs diff 2.29µs align 32768 pre 341µs on 343µs post 342µs diff 1.69µs align 16384 pre 342µs on 343µs post 341µs diff 1.97µs align 8192 pre 340µs on 341µs post 339µs diff 1.43µs align 4096 pre 342µs on 343µs post 340µs diff 2.22µs align 2048 pre 342µs on 343µs post 342µs diff 1.41µs tmp179:/home/lcr/flashbench #
I have stopped apparmor, but that didn't make the message disappear. Are the outputs still meaningfull ?
The output is slightly strange, but not unheard of. The last column is the interesting one, and it shows that alignments over 8MB are different from alignments under 8 MB. I would assume that this device has an 8MB erase block, so you should pass --erasesize=$[8 * 1024 * 1024] to the other tests. You could run the -a test repeatedly and with other (larger) values of -b to be sure.
The most interesting test is the --open-au test. Try variations of
flashbench --open-au --open-au-nr=<NR> --erasesize=$[8 * 1024 * 1024] /dev/sdb [--random]
to find out the maximum value of <NR> that gives you the best performance, with and without --random.
Arnd
On Mon, Mar 07, 2011 at 06:03:05PM +0100, Arnd Bergmann wrote:
On Monday 07 March 2011 16:31:36 Philippe De Muyter wrote:
Of course it works better now, but I cannot get rid of an error message at startup :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 1024 /dev/sdb sched_setscheduler: Operation not permitted
I think on some distros, doing a simple 'su' will not give you all the capabilies. Try 'su -' or 'sudo -s' instead.
I am really logged as 'root'.
align 67108864 pre 339µs on 338µs post 339µs diff -694ns align 33554432 pre 340µs on 338µs post 337µs diff -687ns align 16777216 pre 339µs on 338µs post 338µs diff -768ns align 8388608 pre 337µs on 337µs post 339µs diff -686ns align 4194304 pre 340µs on 341µs post 341µs diff 77ns align 2097152 pre 339µs on 340µs post 337µs diff 2.23µs align 1048576 pre 340µs on 341µs post 339µs diff 2.09µs align 524288 pre 338µs on 341µs post 339µs diff 2.21µs align 262144 pre 341µs on 340µs post 339µs diff 572ns align 131072 pre 341µs on 339µs post 339µs diff -211ns align 65536 pre 340µs on 341µs post 337µs diff 2.29µs align 32768 pre 341µs on 343µs post 342µs diff 1.69µs align 16384 pre 342µs on 343µs post 341µs diff 1.97µs align 8192 pre 340µs on 341µs post 339µs diff 1.43µs align 4096 pre 342µs on 343µs post 340µs diff 2.22µs align 2048 pre 342µs on 343µs post 342µs diff 1.41µs tmp179:/home/lcr/flashbench #
I have stopped apparmor, but that didn't make the message disappear. Are the outputs still meaningfull ?
The output is slightly strange, but not unheard of. The last column is the interesting one, and it shows that alignments over 8MB are different from alignments under 8 MB. I would assume that this device has an 8MB erase block, so you should pass --erasesize=$[8 * 1024 * 1024] to the other tests. You could run the -a test repeatedly and with other (larger) values of -b to be sure.
The most interesting test is the --open-au test. Try variations of
flashbench --open-au --open-au-nr=<NR> --erasesize=$[8 * 1024 * 1024] /dev/sdb [--random]
to find out the maximum value of <NR> that gives you the best performance, with and without --random.
Here are the results :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 8192 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 1.49ms on 1.49ms post 1.49ms diff -2556ns align 33554432 pre 1.49ms on 1.49ms post 1.49ms diff -1001ns align 16777216 pre 1.49ms on 1.49ms post 1.49ms diff 1.29µs align 8388608 pre 1.49ms on 1.49ms post 1.48ms diff 1.52µs align 4194304 pre 1.49ms on 1.49ms post 1.49ms diff -3275ns align 2097152 pre 1.49ms on 1.49ms post 1.49ms diff -1312ns align 1048576 pre 1.49ms on 1.49ms post 1.49ms diff -70ns align 524288 pre 1.49ms on 1.49ms post 1.49ms diff -1565ns align 262144 pre 1.49ms on 1.49ms post 1.49ms diff 505ns align 131072 pre 1.49ms on 1.49ms post 1.49ms diff 582ns align 65536 pre 1.49ms on 1.49ms post 1.49ms diff 604ns align 32768 pre 1.49ms on 1.49ms post 1.49ms diff -2350ns align 16384 pre 1.49ms on 1.49ms post 1.49ms diff 3.01µs tmp179:/home/lcr/flashbench # ./flashbench -a -b 8192 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 1.49ms on 1.49ms post 1.49ms diff -2419ns align 33554432 pre 1.49ms on 1.49ms post 1.49ms diff -55ns align 16777216 pre 1.49ms on 1.49ms post 1.49ms diff -885ns align 8388608 pre 1.49ms on 1.49ms post 1.49ms diff -83ns align 4194304 pre 1.48ms on 1.49ms post 1.49ms diff 3.28µs align 2097152 pre 1.49ms on 1.49ms post 1.49ms diff -2336ns align 1048576 pre 1.49ms on 1.49ms post 1.49ms diff -762ns align 524288 pre 1.49ms on 1.49ms post 1.49ms diff 2.57µs align 262144 pre 1.49ms on 1.49ms post 1.49ms diff 1.53µs align 131072 pre 1.49ms on 1.49ms post 1.49ms diff 992ns align 65536 pre 1.49ms on 1.49ms post 1.49ms diff -936ns align 32768 pre 1.49ms on 1.49ms post 1.49ms diff -798ns align 16384 pre 1.49ms on 1.49ms post 1.49ms diff 1.36µs tmp179:/home/lcr/flashbench # ./flashbench -a -b 32768 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 5.41ms on 5.41ms post 5.41ms diff 2.23µs align 33554432 pre 5.42ms on 5.42ms post 5.41ms diff 2.13µs align 16777216 pre 5.41ms on 5.41ms post 5.41ms diff 2.23µs align 8388608 pre 5.41ms on 5.41ms post 5.41ms diff -3227ns align 4194304 pre 5.41ms on 5.41ms post 5.41ms diff 1.18µs align 2097152 pre 5.41ms on 5.41ms post 5.42ms diff -1046ns align 1048576 pre 5.41ms on 5.42ms post 5.42ms diff 1.78µs align 524288 pre 5.42ms on 5.42ms post 5.41ms diff 1.01µs try_align: Unknown error 86581938 tmp179:/home/lcr/flashbench # ./flashbench -a -b 32768 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 5.42ms on 5.42ms post 5.41ms diff 2.73µs align 33554432 pre 5.41ms on 5.41ms post 5.41ms diff 2.79µs align 16777216 pre 5.41ms on 5.41ms post 5.41ms diff -520ns align 8388608 pre 5.42ms on 5.41ms post 5.41ms diff -2059ns align 4194304 pre 5.41ms on 5.42ms post 5.41ms diff 4.26µs align 2097152 pre 5.41ms on 5.41ms post 5.41ms diff -1450ns align 1048576 pre 5.41ms on 5.41ms post 5.41ms diff 1.23µs align 524288 pre 5.41ms on 5.41ms post 5.41ms diff 2.67µs align 262144 pre 5.41ms on 5.42ms post 5.41ms diff 2.58µs align 131072 pre 5.41ms on 5.41ms post 5.41ms diff -143ns align 65536 pre 5.42ms on 5.42ms post 5.42ms diff 2.49µs tmp179:/home/lcr/flashbench # ./flashbench -a -b 65536 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 10.7ms on 10.7ms post 10.7ms diff 6.15µs align 33554432 pre 10.7ms on 10.7ms post 10.7ms diff 218ns align 16777216 pre 10.7ms on 10.7ms post 10.7ms diff -1817ns align 8388608 pre 10.7ms on 10.7ms post 10.7ms diff -3450ns align 4194304 pre 10.7ms on 10.7ms post 10.7ms diff 794ns align 2097152 pre 10.7ms on 10.7ms post 10.7ms diff 3.33µs align 1048576 pre 10.7ms on 10.7ms post 10.7ms diff -1295ns align 524288 pre 10.7ms on 10.7ms post 10.7ms diff 906ns align 262144 pre 10.7ms on 10.7ms post 10.7ms diff 617ns align 131072 pre 10.7ms on 10.7ms post 10.7ms diff 548ns tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=1 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 5.53M/s 4MiB 5.57M/s 2MiB 5.57M/s 1MiB 5.57M/s 512KiB 5.57M/s 256KiB 5.56M/s 128KiB 5.56M/s 64KiB 5.47M/s 32KiB 5.31M/s 16KiB 5M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=2 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 5.55M/s 4MiB 5.52M/s 2MiB 5.56M/s 1MiB 5.57M/s 512KiB 5.56M/s 256KiB 5.56M/s 128KiB 5.56M/s 64KiB 5.45M/s 32KiB 5.31M/s 16KiB 5M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=3 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 2.7M/s 4MiB 4.44M/s 2MiB 5.06M/s 1MiB 5.32M/s 512KiB 5.48M/s 256KiB 5.51M/s 128KiB 5.53M/s 64KiB 5.46M/s 32KiB 5.3M/s 16KiB 4.99M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=4 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 3.42M/s 4MiB 4.72M/s 2MiB 5.18M/s 1MiB 5.38M/s 512KiB 5.12M/s 256KiB 4.06M/s 128KiB 2.89M/s 64KiB 1.8M/s 32KiB 1.02M/s 16KiB 546K/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=1 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.57M/s 4MiB 5.57M/s 2MiB 5.57M/s 1MiB 5.57M/s 512KiB 5.09M/s 256KiB 4.39M/s 128KiB 4.31M/s 64KiB 3.57M/s 32KiB 3.18M/s 16KiB 2.66M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=2 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.2M/s 4MiB 5.39M/s 2MiB 5.53M/s 1MiB 5.53M/s 512KiB 4.79M/s 256KiB 3.95M/s 128KiB 3.37M/s 64KiB 2.49M/s 32KiB 1.95M/s 16KiB 1.48M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=3 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 2.56M/s 4MiB 4.33M/s 2MiB 5.07M/s 1MiB 5.33M/s 512KiB 4.81M/s 256KiB 3.93M/s 128KiB 3.17M/s 64KiB 2.32M/s 32KiB 1.51M/s 16KiB 1.22M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=4 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 3.32M/s 4MiB 4.64M/s 2MiB 5.17M/s 1MiB 5.39M/s 512KiB 4.73M/s 256KiB 3.68M/s 128KiB 2.84M/s 64KiB 2.05M/s 32KiB 1.36M/s 16KiB 972K/s tmp179:/home/lcr/flashbench #
Philippe
On Monday 07 March 2011, Philippe De Muyter wrote:
On Mon, Mar 07, 2011 at 06:03:05PM +0100, Arnd Bergmann wrote:
Here are the results :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 8192 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 1.49ms on 1.49ms post 1.49ms diff -2556ns align 33554432 pre 1.49ms on 1.49ms post 1.49ms diff -1001ns align 16777216 pre 1.49ms on 1.49ms post 1.49ms diff 1.29µs align 8388608 pre 1.49ms on 1.49ms post 1.48ms diff 1.52µs
The -a tests are still inconclusive. What kind of device is this? What is the total size? (in /proc/partitions) For a USB device, what is the output of lsusb? For a SD card, can you put the card into a builtin SD card reader and do 'head /sys/block/mmcblk0/device/*'?
tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=3 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 2.7M/s 4MiB 4.44M/s 2MiB 5.06M/s 1MiB 5.32M/s 512KiB 5.48M/s 256KiB 5.51M/s 128KiB 5.53M/s 64KiB 5.46M/s 32KiB 5.3M/s 16KiB 4.99M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=4 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 3.42M/s 4MiB 4.72M/s 2MiB 5.18M/s 1MiB 5.38M/s 512KiB 5.12M/s 256KiB 4.06M/s 128KiB 2.89M/s 64KiB 1.8M/s 32KiB 1.02M/s 16KiB 546K/s
This at least is a clear result: The device can have 3 AUs open simultaneously, but not four. The performance using 512 KiB byte blocks is still ok, so the AU size might actually be as small as this.
tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=1 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.57M/s 4MiB 5.57M/s 2MiB 5.57M/s 1MiB 5.57M/s 512KiB 5.09M/s 256KiB 4.39M/s 128KiB 4.31M/s 64KiB 3.57M/s 32KiB 3.18M/s 16KiB 2.66M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=2 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.2M/s 4MiB 5.39M/s 2MiB 5.53M/s 1MiB 5.53M/s 512KiB 4.79M/s 256KiB 3.95M/s 128KiB 3.37M/s 64KiB 2.49M/s 32KiB 1.95M/s 16KiB 1.48M/s
In random access, you see the performance drop already with one AU, which is a hint that the AU size is actually smaller. What you could try next is vary the erasesize argument with --random --open-au-nr=3.
When you pass the correct size, you should see the same result that you see without --random, i.e. it's always fast with --open-au-nr=3 but much slower with --open-au-nr=4.
Arnd
On Tue, Mar 08, 2011 at 02:41:03PM +0100, Arnd Bergmann wrote:
On Monday 07 March 2011, Philippe De Muyter wrote:
On Mon, Mar 07, 2011 at 06:03:05PM +0100, Arnd Bergmann wrote:
Here are the results :
tmp179:/home/lcr/flashbench # ./flashbench -a -b 8192 /dev/sdb sched_setscheduler: Operation not permitted align 67108864 pre 1.49ms on 1.49ms post 1.49ms diff -2556ns align 33554432 pre 1.49ms on 1.49ms post 1.49ms diff -1001ns align 16777216 pre 1.49ms on 1.49ms post 1.49ms diff 1.29µs align 8388608 pre 1.49ms on 1.49ms post 1.48ms diff 1.52µs
The -a tests are still inconclusive. What kind of device is this? What is the total size? (in /proc/partitions) For a USB device, what is the output of lsusb? For a SD card, can you put the card into a builtin SD card reader and do 'head /sys/block/mmcblk0/device/*'?
It is a 2GB compactflash card. I do not remember the brand and model. I'll look them up tomorrow.
From `dmesg':
[ 1.202196] ata3.00: CFA: PIO, 20100202, max PIO4 [ 1.202241] ata3.00: 3980592 sectors, multi 0: LBA [ 1.202284] ata3.00: applying bridge limits [ 1.208129] ata3.00: configured for PIO4 [ 1.243481] scsi 2:0:0:0: Direct-Access ATA PIO 2010 PQ: 0 ANSI: 5 [ 1.243754] sd 2:0:0:0: [sdb] 3980592 512-byte logical blocks: (2.03 GB/1.89 GiB) [ 1.243838] sd 2:0:0:0: [sdb] Write Protect is off [ 1.243886] sd 2:0:0:0: [sdb] Mode Sense: 00 3a 00 00 [ 1.243948] sd 2:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA [ 1.245062] sdb: sdb1
From /proc/partitions:
8 16 1990296 sdb 8 17 1989760 sdb1
From `smartctl --all -T permissive /dev/sdb':
smartctl 5.40 2010-10-16 r3189 [i686-pc-linux-gnu] (SUSE RPM) Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF INFORMATION SECTION === Device Model: PIO Serial Number: 20100716 CF100BA8 Firmware Version: 20100202 User Capacity: 2,038,063,104 bytes Device is: Not in smartctl database [for details use: -P showall] ATA Version is: 4 ATA Standard is: Exact ATA specification draft version not indicated Local Time is: Tue Mar 8 15:37:58 2011 CET SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 85-87 don't show if SMART is enabled. A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options. tmp179:~ # smartctl --all -T permissive /dev/sdb smartctl 5.40 2010-10-16 r3189 [i686-pc-linux-gnu] (SUSE RPM) Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF INFORMATION SECTION === Device Model: PIO Serial Number: 20100716 CF100BA8 Firmware Version: 20100202 User Capacity: 2,038,063,104 bytes Device is: Not in smartctl database [for details use: -P showall] ATA Version is: 4 ATA Standard is: Exact ATA specification draft version not indicated Local Time is: Tue Mar 8 15:38:44 2011 CET SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 85-87 don't show if SMART is enabled. Checking to be sure by trying SMART RETURN STATUS command. SMART support is: Available - device has SMART capability. SMART support is: Enabled
=== START OF READ SMART DATA SECTION === SMART overall-health self-assessment test result: PASSED
General SMART Values: Offline data collection status: (0x26) Offline data collection activity is in a Reserved state. Auto Offline Data Collection: Disabled. Total time to complete Offline data collection: ( 3) seconds. Offline data collection capabilities: (0x00) Offline data collection not supported. SMART capabilities: (0x0002) Does not save SMART data before entering power-saving mode. Supports SMART auto save timer. Error logging capability: (0x00) Error logging NOT supported. No General Purpose Logging support.
SMART Attributes Data Structure revision number: 1 Vendor Specific SMART Attributes with Thresholds: ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE 1 Raw_Read_Error_Rate 0x0000 100 100 000 Old_age Offline - 0 2 Throughput_Performance 0x0000 100 100 000 Old_age Offline - 0 5 Reallocated_Sector_Ct 0x0000 100 100 000 Old_age Offline - 0 7 Seek_Error_Rate 0x0000 100 100 000 Old_age Offline - 0 8 Seek_Time_Performance 0x0000 100 100 000 Old_age Offline - 0 12 Power_Cycle_Count 0x0000 100 100 000 Old_age Offline - 39 195 Hardware_ECC_Recovered 0x0000 100 100 000 Old_age Offline - 0 196 Reallocated_Event_Count 0x0000 100 100 000 Old_age Offline - 0 197 Current_Pending_Sector 0x0000 100 100 000 Old_age Offline - 0 198 Offline_Uncorrectable 0x0000 100 100 000 Old_age Offline - 0 199 UDMA_CRC_Error_Count 0x0000 100 100 000 Old_age Offline - 0 200 Multi_Zone_Error_Rate 0x0000 100 100 000 Old_age Offline - 0
Warning: device does not support Error Logging Error SMART Error Log Read failed: Input/output error Smartctl: SMART Error Log Read Failed Warning: device does not support Self Test Logging Error SMART Error Self-Test Log Read failed: Input/output error Smartctl: SMART Self Test Log Read Failed Device does not support Selective Self Tests/Logging
tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=3 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 2.7M/s 4MiB 4.44M/s 2MiB 5.06M/s 1MiB 5.32M/s 512KiB 5.48M/s 256KiB 5.51M/s 128KiB 5.53M/s 64KiB 5.46M/s 32KiB 5.3M/s 16KiB 4.99M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=4 --erasesize=$[8 * 1024 * 1024] /dev/sdb sched_setscheduler: Operation not permitted 8MiB 3.42M/s 4MiB 4.72M/s 2MiB 5.18M/s 1MiB 5.38M/s 512KiB 5.12M/s 256KiB 4.06M/s 128KiB 2.89M/s 64KiB 1.8M/s 32KiB 1.02M/s 16KiB 546K/s
This at least is a clear result: The device can have 3 AUs open simultaneously, but not four. The performance using 512 KiB byte blocks is still ok, so the AU size might actually be as small as this.
tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=1 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.57M/s 4MiB 5.57M/s 2MiB 5.57M/s 1MiB 5.57M/s 512KiB 5.09M/s 256KiB 4.39M/s 128KiB 4.31M/s 64KiB 3.57M/s 32KiB 3.18M/s 16KiB 2.66M/s tmp179:/home/lcr/flashbench # ./flashbench --open-au --open-au-nr=2 --erasesize=$[8 * 1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 8MiB 5.2M/s 4MiB 5.39M/s 2MiB 5.53M/s 1MiB 5.53M/s 512KiB 4.79M/s 256KiB 3.95M/s 128KiB 3.37M/s 64KiB 2.49M/s 32KiB 1.95M/s 16KiB 1.48M/s
In random access, you see the performance drop already with one AU, which is a hint that the AU size is actually smaller. What you could try next is vary the erasesize argument with --random --open-au-nr=3.
When you pass the correct size, you should see the same result that you see without --random, i.e. it's always fast with --open-au-nr=3 but much slower with --open-au-nr=4.
Here are some more results :
tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.31M/s 1MiB 5.44M/s 512KiB 5.13M/s 256KiB 4.45M/s 128KiB 4.45M/s 64KiB 4.03M/s 32KiB 3.56M/s 16KiB 3.08M/s tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.57M/s 512KiB 5.57M/s 256KiB 5.25M/s 128KiB 4.45M/s 64KiB 5.05M/s 32KiB 4.72M/s 16KiB 4.35M/s tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[512 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 512KiB 5.49M/s 256KiB 5.3M/s 128KiB 4.84M/s 64KiB 5.14M/s 32KiB 4.81M/s 16KiB 4.34M/s tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[256 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 256KiB 5.5M/s 128KiB 5.49M/s 64KiB 5.32M/s 32KiB 4.84M/s 16KiB 4.41M/s tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[128 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 128KiB 5.5M/s 64KiB 5.33M/s 32KiB 5.04M/s 16KiB 4.54M/s tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[64 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 64KiB 5.33M/s 32KiB 5.04M/s 16KiB 4.54M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.29M/s 1MiB 5.43M/s 512KiB 4.85M/s 256KiB 3.91M/s 128KiB 3.35M/s 64KiB 3.61M/s 32KiB 3.08M/s 16KiB 2.62M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.29M/s 512KiB 5.1M/s 256KiB 4.28M/s 128KiB 4.55M/s 64KiB 4.94M/s 32KiB 4.62M/s 16KiB 4.34M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[512 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 512KiB 5.52M/s 256KiB 5.11M/s 128KiB 4.78M/s 64KiB 5.05M/s 32KiB 4.85M/s 16KiB 4.34M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[256 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 256KiB 5.5M/s 128KiB 5.49M/s 64KiB 4.97M/s 32KiB 4.72M/s 16KiB 4.34M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[128 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 128KiB 5.5M/s 64KiB 5.31M/s 32KiB 5.03M/s 16KiB 4.41M/s tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[64 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 64KiB 5.33M/s 32KiB 5.03M/s 16KiB 4.54M/s tmp179:~ #
Philippe
On Tuesday 08 March 2011, Philippe De Muyter wrote:
On Tue, Mar 08, 2011 at 02:41:03PM +0100, Arnd Bergmann wrote:
The -a tests are still inconclusive. What kind of device is this? What is the total size? (in /proc/partitions) For a USB device, what is the output of lsusb? For a SD card, can you put the card into a builtin SD card reader and do 'head /sys/block/mmcblk0/device/*'?
It is a 2GB compactflash card. I do not remember the brand and model. I'll look them up tomorrow.
From `dmesg': [ 1.202196] ata3.00: CFA: PIO, 20100202, max PIO4 [ 1.202241] ata3.00: 3980592 sectors, multi 0: LBA [ 1.202284] ata3.00: applying bridge limits [ 1.208129] ata3.00: configured for PIO4 [ 1.243481] scsi 2:0:0:0: Direct-Access ATA PIO 2010 PQ: 0 ANSI: 5 [ 1.243754] sd 2:0:0:0: [sdb] 3980592 512-byte logical blocks: (2.03 GB/1.89 GiB) From /proc/partitions: 8 16 1990296 sdb 8 17 1989760 sdb1
Fascinating, so the size is actually not a multiple of any significant block, which means that it either uses a completely different algorithm or it has a segment size that is slightly smaller or bigger.
I noticed that the partition starts at sector 514, which is just slightly over 512, and the drive size is a multiple of 504 sectors long, which is just slightly lower than 512. Flashbench does not handle this yet, but I plan to add support for this because I have recently encountered a USB stick that uses 4128 KB segments.
One thing that you can try is to run
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot gnuplot -p -e 'plot "output.plot"'
This will show you the time to read 3 blocks of 8 KB starting at 2^14 addresses 8KB apart. Normally, the boundaries between segments will show up as periodic dots above one or two relatively straight lines. Looking at the offsets in the output.plot text file will show you exactly where these are.
When you pass the correct size, you should see the same result that you see without --random, i.e. it's always fast with --open-au-nr=3 but much slower with --open-au-nr=4.
Here are some more results :
tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.31M/s 1MiB 5.44M/s 512KiB 5.13M/s 256KiB 4.45M/s 128KiB 4.45M/s 64KiB 4.03M/s 32KiB 3.56M/s 16KiB 3.08M/s
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.29M/s 1MiB 5.43M/s 512KiB 4.85M/s 256KiB 3.91M/s 128KiB 3.35M/s 64KiB 3.61M/s 32KiB 3.08M/s 16KiB 2.62M/s
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.29M/s 512KiB 5.1M/s 256KiB 4.28M/s 128KiB 4.55M/s 64KiB 4.94M/s 32KiB 4.62M/s 16KiB 4.34M/s
Ok, so at 2 MB you see a noticeable slowdown with nr=4, but not at smaller sizes. Since the test areas are always a segment apart, that would indicate that 8 MB is the correct segment size, but it's still guesswork because the effect is not very strong.
Thanks for your persistence, I very much appreciate your help and I hope we get down to the real design of this card.
Arnd
On Tue, Mar 08, 2011 at 05:20:04PM +0100, Arnd Bergmann wrote:
On Tuesday 08 March 2011, Philippe De Muyter wrote:
On Tue, Mar 08, 2011 at 02:41:03PM +0100, Arnd Bergmann wrote:
The -a tests are still inconclusive. What kind of device is this? What is the total size? (in /proc/partitions) For a USB device, what is the output of lsusb? For a SD card, can you put the card into a builtin SD card reader and do 'head /sys/block/mmcblk0/device/*'?
It is a 2GB compactflash card. I do not remember the brand and model. I'll look them up tomorrow.
From `dmesg': [ 1.202196] ata3.00: CFA: PIO, 20100202, max PIO4 [ 1.202241] ata3.00: 3980592 sectors, multi 0: LBA [ 1.202284] ata3.00: applying bridge limits [ 1.208129] ata3.00: configured for PIO4 [ 1.243481] scsi 2:0:0:0: Direct-Access ATA PIO 2010 PQ: 0 ANSI: 5 [ 1.243754] sd 2:0:0:0: [sdb] 3980592 512-byte logical blocks: (2.03 GB/1.89 GiB) From /proc/partitions: 8 16 1990296 sdb 8 17 1989760 sdb1
Fascinating, so the size is actually not a multiple of any significant block, which means that it either uses a completely different algorithm or it has a segment size that is slightly smaller or bigger.
I noticed that the partition starts at sector 514, which is just slightly over 512, and the drive size is a multiple of 504 sectors long, which is just slightly lower than 512. Flashbench does not handle this yet, but I plan to add support for this because I have recently encountered a USB stick that uses 4128 KB segments.
I have worked with many CompactFlash cards, none of which had a size which was a power of 2 :
Size in bytes Label 1008451584 Kingston 1GB 3.3V ASSY IN TAIWAN CF/1GB 1024966656 Sony CompactFlash 66x 10MB/s [Read] 1GB 1025482752 Kingston Digital Memory Card 1024 MB CF/1024
1996259328 Kingston ultimate 2GB 266X 2029805568 Kingston 2GB 2038063104 Transcend ultra 2GB Industrial 2048901120 Sony CompactFlash 66x 10MB/s [Read] 2GB 2096898048 innoDisk Industrial CF card iCF 4000 2GB Industrial
4017807360 Kingston 4GB CF/4GB 4076642304 Kingston ultimate 4GB 266X CF/4GB-U2
I have always thought that they reserved some blocks for firmware or bad block handling.
The one that I test here is a 'Transcend ultra 2GB Industrial'
One thing that you can try is to run
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot
I did that, but the output.plot file is empty :(
gnuplot -p -e 'plot "output.plot"'
This will show you the time to read 3 blocks of 8 KB starting at 2^14 addresses 8KB apart. Normally, the boundaries between segments will show up as periodic dots above one or two relatively straight lines. Looking at the offsets in the output.plot text file will show you exactly where these are.
When you pass the correct size, you should see the same result that you see without --random, i.e. it's always fast with --open-au-nr=3 but much slower with --open-au-nr=4.
Here are some more results :
tmp179:~ # ./flashbench --open-au --open-au-nr=3 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.31M/s 1MiB 5.44M/s 512KiB 5.13M/s 256KiB 4.45M/s 128KiB 4.45M/s 64KiB 4.03M/s 32KiB 3.56M/s 16KiB 3.08M/s
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[2048 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 2MiB 5.29M/s 1MiB 5.43M/s 512KiB 4.85M/s 256KiB 3.91M/s 128KiB 3.35M/s 64KiB 3.61M/s 32KiB 3.08M/s 16KiB 2.62M/s
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.29M/s 512KiB 5.1M/s 256KiB 4.28M/s 128KiB 4.55M/s 64KiB 4.94M/s 32KiB 4.62M/s 16KiB 4.34M/s
Ok, so at 2 MB you see a noticeable slowdown with nr=4, but not at smaller sizes. Since the test areas are always a segment apart, that would indicate that 8 MB is the correct segment size, but it's still guesswork because the effect is not very strong.
Thanks for your persistence, I very much appreciate your help and I hope we get down to the real design of this card.
Thanks for you quick replies.
Philippe
On Wednesday 09 March 2011, Philippe De Muyter wrote:
I have worked with many CompactFlash cards, none of which had a size which was a power of 2 :
I have not seen a drive size which is a power of two, but the USB and SD drives are normally a multiple of full segments, which are each a power of two in size, which does not seem to be the case for your CF cards. However, all your cards are a multiple of 516096 bytes, which is the maximum number of sectors per head (63) multiplied with the number of on an ATA device. Apparently, the CF cards must waste a little space to fit the ATA spec.
If the theory is correct, adding 516095 bytes and rounding down to full multiples of 512 KB gives the most likely actual size of the drive. For the 2GB and 4GB card, this turns out to be a multiple of 8MB, for the 1GB cards, it's less clear, but 1GB NAND flash chips often have only 256KB or 128KB segments, while the larger cards normally have 2MB segments or larger (depending on the number of chips and planes).
Size in bytes Label 1008451584 Kingston 1GB 3.3V ASSY IN TAIWAN CF/1GB
1008730112 = 2M * 481
1024966656 Sony CompactFlash 66x 10MB/s [Read] 1GB
1024983040 = 512K * 1955 (could be anything)
1025482752 Kingston Digital Memory Card 1024 MB CF/1024
1025507328 = 2M * 489
1996259328 Kingston ultimate 2GB 266X
1996488704 = 8M * 238
2029805568 Kingston 2GB
2030043136 = 8M * 242
2038063104 Transcend ultra 2GB Industrial
2038431744 = 8M * 243
2048901120 Sony CompactFlash 66x 10MB/s [Read] 2GB
2048917504 = 2M * 977
2096898048 innoDisk Industrial CF card iCF 4000 2GB Industrial
2097152000 = 8M * 250
4017807360 Kingston 4GB CF/4GB
4018143232 = 8M * 479
4076642304 Kingston ultimate 4GB 266X CF/4GB-U2
4076863488 = 8M * 486
Thanks for sharing the list!
The one that I test here is a 'Transcend ultra 2GB Industrial'
Ok, the 8MB segment size is confirmed by the drive size (modulo cylinder size).
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot
I did that, but the output.plot file is empty :(
I tried to reproduce it here, and accidentally pasted the '>' from the email into the command line, which resulted in bash overwriting the flashbench command with an empty shell script. Maybe you did the same? Deleting and rebuilding flashbench fixed it here.
Arnd
Hello Arnd,
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot
I did that, but the output.plot file is empty :(
I tried to reproduce it here, and accidentally pasted the '>' from the email into the command line, which resulted in bash overwriting the flashbench command with an empty shell script. Maybe you did the same? Deleting and rebuilding flashbench fixed it here.
No, here flashbench runs and creates output.plot if it does not exist before, but does not write anything into it.
I'll look into the sources to see what happens.
Philippe
On Wed, Mar 09, 2011 at 06:45:41PM +0100, Philippe De Muyter wrote:
Hello Arnd,
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot
I did that, but the output.plot file is empty :(
I tried to reproduce it here, and accidentally pasted the '>' from the email into the command line, which resulted in bash overwriting the flashbench command with an empty shell script. Maybe you did the same? Deleting and rebuilding flashbench fixed it here.
No, here flashbench runs and creates output.plot if it does not exist before, but does not write anything into it.
I'll look into the sources to see what happens.
OK, the culprit is
returnif (time);
in try_scatter_io.
I have printed the values of time, and I get a range of similar values, followed by a negative value :(
... time = 4230719 time = 4233873 time = 4230636 time = -4290735028
At that point try_scatter_io returns without ouputting anything.
Philippe
On Wednesday 09 March 2011 19:20:38 Philippe De Muyter wrote:
On Wed, Mar 09, 2011 at 06:45:41PM +0100, Philippe De Muyter wrote:
Hello Arnd,
flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o output.plot
I did that, but the output.plot file is empty :(
I tried to reproduce it here, and accidentally pasted the '>' from the email into the command line, which resulted in bash overwriting the flashbench command with an empty shell script. Maybe you did the same? Deleting and rebuilding flashbench fixed it here.
No, here flashbench runs and creates output.plot if it does not exist before, but does not write anything into it.
I'll look into the sources to see what happens.
OK, the culprit is
returnif (time);
in try_scatter_io.
I have printed the values of time, and I get a range of similar values, followed by a negative value :(
... time = 4230719 time = 4233873 time = 4230636 time = -4290735028
At that point try_scatter_io returns without ouputting anything.
Ah, thanks.
I should really commit all the patches I got. Someone else reported this earlier, but it only happens on ARM systems, which are 32 bit. PCs are normally 64 bit, so the type conversion problem does not happen.
I've uploaded the fix now.
Arnd
Hello Arnd
I've uploaded the fix now.
I have tried twice with your fix. Of course it works better, but it still terminates abnormally, after a long run time and in a different way :
tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 153651144 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 22:52 /tmp/output.plot tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 152931315 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 23:00 /tmp/output.plot tmp179:~ #
Philippe
On Thursday 10 March 2011, Philippe De Muyter wrote:
I have tried twice with your fix. Of course it works better, but it still terminates abnormally, after a long run time and in a different way :
tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 153651144 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 22:52 /tmp/output.plot tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 152931315 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 23:00 /tmp/output.plot tmp179:~ #
I can't reproduce this here, and have no real explanation either. The code checks if the number is below zero after a conversion to 32 bit int, which is clearly is not.
Does it work with a smaller count= number?
Arnd
On Fri, Mar 11, 2011 at 05:19:36PM +0100, Arnd Bergmann wrote:
On Thursday 10 March 2011, Philippe De Muyter wrote:
I have tried twice with your fix. Of course it works better, but it still terminates abnormally, after a long run time and in a different way :
tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 153651144 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 22:52 /tmp/output.plot tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=100 /dev/sdb -o /tmp/output.plot sched_setscheduler: Operation not permitted try_scatter_io: Unknown error 152931315 tmp179:~ # ls -l /tmp/output.plot -rw-r--r-- 1 root root 0 Mar 9 23:00 /tmp/output.plot tmp179:~ #
I can't reproduce this here, and have no real explanation either. The code checks if the number is below zero after a conversion to 32 bit int, which is clearly is not.
Does it work with a smaller count= number?
I'll try that.
I had also suspected a clock going backwards, but that was not the problem.
Philippe
On Fri, Mar 11, 2011 at 05:46:30PM +0100, Philippe De Muyter wrote: [...]
try_scatter_io: Unknown error 153651144
[...]
I had also suspected a clock going backwards, but that was not the problem.
I have found the problem. Reading your code, you use CLOCK_REALTIME.
From the man page : "CLOCK_REALTIME [...] represents seconds and
nanoseconds since the Epoch. When its time is changed, [...] timers for an absolute point in time are affected. [...] CLOCK_MONOTONIC: Clock that [...] represents monotonic time since some unspecified starting point."
I knew I had no ntp client running, but I wrote the small program below :
#define _POSIX_C_SOURCE 199309L
#include <time.h> #include <stdio.h>
main(int argc, char **argv) { struct timespec ts0, tsi, tsj; int duration = 3600;
if (argc >= 2) sscanf(argv[1], "%d", &duration); printf("running for %d seconds\n", duration);
clock_gettime(CLOCK_REALTIME, &ts0);
clock_gettime(CLOCK_REALTIME, &tsi); do { clock_gettime(CLOCK_REALTIME, &tsj); if (tsj.tv_sec < tsi.tv_sec || tsj.tv_sec == tsi.tv_sec && tsj.tv_nsec < tsi.tv_nsec) printf("clock goes backward : %d.%09u %d.%09u\n", tsi.tv_sec, tsi.tv_nsec, tsj.tv_sec, tsj.tv_nsec); tsi = tsj; } while (tsi.tv_sec < ts0.tv_sec + duration); }
First time, I had let it run for 10 minutes, and nothing happened, hence what I wrote before : "that was not the problem".
I then let it run longer (1 hour), and I got : tmp179:~ # ./check_clock_realtime clock goes backward : 1299957301.487201455 1299957301.315750417 clock goes backward : 1299958201.663430282 1299958201.492589443 clock goes backward : 1299959101.669746997 1299959101.498847436 clock goes backward : 1299960001.670239257 1299960001.499414368 tmp179:~ #
So every 15 minutes, there is a little backwards step. This is with a newly installed opensuse 11.4 (RC1).
I finally found the culprit there : tmp179:~ # cat /etc/cron.d/novell.ntp-synchronize -*/15 * * * * root /etc/init.d/ntp ntptimeset &>/dev/null tmp179:~ #
I have modified your source to use CLOCK_MONOTONIC instead of CLOCK_REALTIME, and with the command : ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=50 /dev/sdb -o /tmp/output.plot I got the attached result. What do you think of it ?
Philippe
On Monday 14 March 2011, Philippe De Muyter wrote:
I finally found the culprit there : tmp179:~ # cat /etc/cron.d/novell.ntp-synchronize -*/15 * * * * root /etc/init.d/ntp ntptimeset &>/dev/null tmp179:~ #
I have modified your source to use CLOCK_MONOTONIC instead of CLOCK_REALTIME,
Ok, good to know.
and with the command : ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=50 /dev/sdb -o /tmp/output.plot I got the attached result. What do you think of it ?
Unfortunately, not much result again. The only result that is obvious is the bump between 16 and 20 MB, which is an indication that this is an open allocation unit, and is slightly slower to read than others. I see this as a hint that the erase block size is actually 4 MB, not 8 MB, and that the erase block sizes start at full multiples of their size (as is normally the case).
To verify this, you could write to a single block in another erase block, e.g. using dd if=/dev/zero of=/dev/sdb bs=64K seek=128 count=1, and see how the picture changes. To speed up the process, you can lower scatter-span to 1 (only do one block at a time) and scatter-order to 12 (do only the first 32 MB, i.e. 8kb*2^12, instead of the first 128 MB of the drive). You can probably also do a much lower repeat count, e.g. 10, since the effect appears to be quite visible.
About 92% of the requests took between 4.21 and 4.23 ms to complete, which is fairly uniform, the other 8% were significantly faster at around 3.99 ms. I'm sure that there is a reason for this, but I don't understand it.
Arnd
On Mon, Mar 14, 2011 at 04:56:22PM +0100, Arnd Bergmann wrote:
Unfortunately, not much result again. The only result that is obvious is the bump between 16 and 20 MB, which is an indication that this is an open allocation unit, and is slightly slower to read than others. I see this as a hint that the erase block size is actually 4 MB, not 8 MB, and that the erase block sizes start at full multiples of their size (as is normally the case).
To verify this, you could write to a single block in another erase block, e.g. using dd if=/dev/zero of=/dev/sdb bs=64K seek=128 count=1, and
Do you mean :
tmp179:~ # time dd if=/dev/zero of=/dev/sdb bs=64K seek=128 count=1 1+0 records in 1+0 records out 65536 bytes (66 kB) copied, 0.0155327 s, 4.2 MB/s
real 0m0.017s user 0m0.002s sys 0m0.000s tmp179:~ #
see how the picture changes. To speed up the process, you can lower scatter-span to 1 (only do one block at a time) and scatter-order to 12 (do only the first 32 MB, i.e. 8kb*2^12, instead of the first 128 MB of the drive). You can probably also do a much lower repeat count, e.g. 10, since the effect appears to be quite visible.
tmp179:~ # ./flashbench -s --scatter-span=1 --scatter-order=12 --blocksize=4096 --count=10 /dev/sdb -o /tmp/output2.plot sched_setscheduler: Operation not permitted tmp179:~ #
result is attached
About 92% of the requests took between 4.21 and 4.23 ms to complete, which is fairly uniform, the other 8% were significantly faster at around 3.99 ms. I'm sure that there is a reason for this, but I don't understand it.
You can suggest more tests, now that flashbecnh does not terminate abnormally anymore.
Philippe
On Mon, Mar 14, 2011 at 04:56:22PM +0100, Arnd Bergmann wrote:
On Monday 14 March 2011, Philippe De Muyter wrote:
I finally found the culprit there : tmp179:~ # cat /etc/cron.d/novell.ntp-synchronize -*/15 * * * * root /etc/init.d/ntp ntptimeset &>/dev/null tmp179:~ #
I have modified your source to use CLOCK_MONOTONIC instead of CLOCK_REALTIME,
Ok, good to know.
and with the command : ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=8192 --count=50 /dev/sdb -o /tmp/output.plot I got the attached result. What do you think of it ?
Unfortunately, not much result again. The only result that is obvious is the bump between 16 and 20 MB, which is an indication that this is an open allocation unit, and is slightly slower to read than others. I see this as a hint that the erase block size is actually 4 MB, not 8 MB, and that the erase block sizes start at full multiples of their size (as is normally the case).
To verify this, you could write to a single block in another erase block, e.g. using dd if=/dev/zero of=/dev/sdb bs=64K seek=128 count=1, and see how the picture changes.
I redid the first test after your above 'dd' command and got the attached file.
tmp179:~ # ./flashbench -s --scatter-span=3 --scatter-order=14 --blocksize=4096 --count=50 /dev/sdb -o /tmp/output3.plot sched_setscheduler: Operation not permitted tmp179:~ #
Philippe
On Monday 14 March 2011, Philippe De Muyter wrote:
I redid the first test after your above 'dd' command and got the attached file.
Ok, got it. Now it's much clearer: you have written 64K to the position 8MB, and everything between 8 MB and 9 MB can be clearly seen as slower than the data before and after, but still faster than the range from 16 to 20 MB. When you use the gnuplot UI, you can zoom into that area.
That is a very strong hint that the erase block size is indeed 1 MB.
I would suggest you redo the --open-au tests based on that. You had this:
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.29M/s 512KiB 5.1M/s 256KiB 4.28M/s 128KiB 4.55M/s 64KiB 4.94M/s 32KiB 4.62M/s 16KiB 4.34M/s
It indicates that assuming 1 MB allocation units (erase blocks), the card can do random access on at least four of them.
I'd suggest you continue this test with larger numbers for --open-au-nr until you hit the cut-off. I'd assume that it's clearer than the previous numbers, too.
The other test you can do is finding the FAT area, using ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random
This should show you if the card has any hardwired optimizations for storing the FAT in the beginning of the medium. Each column reflects one (1MB) AU, so anything that is optimized for the FAT will have different characteristics here than the normal ones.
Arnd
On Mon, Mar 14, 2011 at 06:13:16PM +0100, Arnd Bergmann wrote:
On Monday 14 March 2011, Philippe De Muyter wrote:
I redid the first test after your above 'dd' command and got the attached file.
Ok, got it. Now it's much clearer: you have written 64K to the position 8MB, and everything between 8 MB and 9 MB can be clearly seen as slower than the data before and after, but still faster than the range from 16 to 20 MB. When you use the gnuplot UI, you can zoom into that area.
That is a very strong hint that the erase block size is indeed 1 MB.
I would suggest you redo the --open-au tests based on that. You had this:
tmp179:~ # ./flashbench --open-au --open-au-nr=4 --erasesize=$[1024 * 1024] /dev/sdb --random sched_setscheduler: Operation not permitted 1MiB 5.29M/s 512KiB 5.1M/s 256KiB 4.28M/s 128KiB 4.55M/s 64KiB 4.94M/s 32KiB 4.62M/s 16KiB 4.34M/s
It indicates that assuming 1 MB allocation units (erase blocks), the card can do random access on at least four of them.
I'd suggest you continue this test with larger numbers for --open-au-nr until you hit the cut-off. I'd assume that it's clearer than the previous numbers, too.
The other test you can do is finding the FAT area, using ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random
This should show you if the card has any hardwired optimizations for storing the FAT in the beginning of the medium. Each column reflects one (1MB) AU, so anything that is optimized for the FAT will have different characteristics here than the normal ones.
Here are the raw results :
tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr= $i --erasesize=$[1024 * 1024] /dev/sdb --random; done 1 1MiB 5.53M/s 512KiB 5.53M/s 256KiB 5.3M/s 128KiB 4.65M/s 64KiB 5.07M/s 32KiB 4.74M/s 16KiB 4.38M/s 2 1MiB 5.14M/s 512KiB 5.19M/s 256KiB 4.78M/s 128KiB 4.67M/s 64KiB 4.89M/s 32KiB 4.61M/s 16KiB 4.32M/s 3 1MiB 5.27M/s 512KiB 5.3M/s 256KiB 4.95M/s 128KiB 4.66M/s 64KiB 4.93M/s 32KiB 4.63M/s 16KiB 4.32M/s 4 1MiB 5.53M/s 512KiB 5.19M/s 256KiB 4.52M/s 128KiB 4.65M/s 64KiB 5.04M/s 32KiB 4.5M/s 16KiB 4.3M/s 5 1MiB 5.22M/s 512KiB 5.2M/s 256KiB 4.6M/s 128KiB 4.73M/s 64KiB 4.22M/s 32KiB 3.8M/s 16KiB 3.25M/s 6 1MiB 5.27M/s 512KiB 5.08M/s 256KiB 4.11M/s 128KiB 3.28M/s 64KiB 4.05M/s 32KiB 3.52M/s 16KiB 3M/s 7 1MiB 5.07M/s 512KiB 5.13M/s 256KiB 4.1M/s 128KiB 3.17M/s 64KiB 3.37M/s 32KiB 2.87M/s 16KiB 2.28M/s 8 1MiB 5.24M/s 512KiB 5.03M/s 256KiB 4.13M/s 128KiB 3.13M/s 64KiB 3.18M/s 32KiB 2.02M/s 16KiB 2.41M/s 9 1MiB 5.22M/s 512KiB 4.95M/s 256KiB 4.07M/s 128KiB 3.05M/s 64KiB 2.99M/s 32KiB 1.9M/s 16KiB 2.19M/s 10 1MiB 5.3M/s 512KiB 4.87M/s 256KiB 4.03M/s 128KiB 2.98M/s 64KiB 2.85M/s 32KiB 1.8M/s 16KiB 2.03M/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random 1MiB 4.76M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 512KiB 5.02M/s 4.71M/s 4.42M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.9M/s 4.77M/s 256KiB 4.38M/s 4.43M/s 4.59M/s 4.46M/s 4.59M/s 4.59M/s 4.59M/s 4.59M/s 4.9M/s 4.9M/s 128KiB 4.3M/s 4.67M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.51M/s 4.57M/s 4.65M/s 64KiB 4.73M/s 4.58M/s 4.64M/s 4.62M/s 4.64M/s 4.64M/s 4.63M/s 4.63M/s 4.59M/s 4.62M/s 32KiB 4.45M/s 4.44M/s 4.45M/s 4.45M/s 4.44M/s 4.46M/s 4.45M/s 4.44M/s 4.43M/s 4.63M/s 16KiB 4.35M/s 4.26M/s 4.27M/s 4.27M/s 4.27M/s 4.27M/s 4.2M/s 4.26M/s 4.26M/s 4.26M/s tmp179:~ #
Philippe
On Tuesday 15 March 2011, Philippe De Muyter wrote:
On Mon, Mar 14, 2011 at 06:13:16PM +0100, Arnd Bergmann wrote: Here are the raw results :
tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr= $i --erasesize=$[1024 * 1024] /dev/sdb --random; done ... 4 1MiB 5.53M/s 512KiB 5.19M/s 256KiB 4.52M/s 128KiB 4.65M/s 64KiB 5.04M/s 32KiB 4.5M/s 16KiB 4.3M/s 5 1MiB 5.22M/s 512KiB 5.2M/s 256KiB 4.6M/s 128KiB 4.73M/s 64KiB 4.22M/s 32KiB 3.8M/s 16KiB 3.25M/s 6 1MiB 5.27M/s 512KiB 5.08M/s 256KiB 4.11M/s 128KiB 3.28M/s 64KiB 4.05M/s 32KiB 3.52M/s 16KiB 3M/s
It's not completely clear from the data, but I think the difference between 4 and 5 is significant, so I'd mark this card down as having four 1MB segments open, with a question mark. It may be doing something slightly smarter, because I would expect a much sharper drop in performance.
tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random 1MiB 4.76M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 512KiB 5.02M/s 4.71M/s 4.42M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.9M/s 4.77M/s 256KiB 4.38M/s 4.43M/s 4.59M/s 4.46M/s 4.59M/s 4.59M/s 4.59M/s 4.59M/s 4.9M/s 4.9M/s 128KiB 4.3M/s 4.67M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.51M/s 4.57M/s 4.65M/s 64KiB 4.73M/s 4.58M/s 4.64M/s 4.62M/s 4.64M/s 4.64M/s 4.63M/s 4.63M/s 4.59M/s 4.62M/s 32KiB 4.45M/s 4.44M/s 4.45M/s 4.45M/s 4.44M/s 4.46M/s 4.45M/s 4.44M/s 4.43M/s 4.63M/s 16KiB 4.35M/s 4.26M/s 4.27M/s 4.27M/s 4.27M/s 4.27M/s 4.2M/s 4.26M/s 4.26M/s 4.26M/s
The first column seems different from all the other ones, so I'd assume that the card is meant for FAT16 with the FAT stored in the first megabyte, which is reasonable for a 2 GB card.
The one number that is currently missing is the page size. Can you rerun the findfat test with --blocksize=512?
I have added the other data from your test to https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCard... and hope that you are still motivated to do similar tests on other cards. That should be much faster now.
I'll also retest my own two CF cards for comparison.
Thanks for all your help!
Arnd
On Tue, Mar 15, 2011 at 02:48:43PM +0100, Arnd Bergmann wrote:
On Tuesday 15 March 2011, Philippe De Muyter wrote:
On Mon, Mar 14, 2011 at 06:13:16PM +0100, Arnd Bergmann wrote: Here are the raw results :
tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr= $i --erasesize=$[1024 * 1024] /dev/sdb --random; done ... 4 1MiB 5.53M/s 512KiB 5.19M/s 256KiB 4.52M/s 128KiB 4.65M/s 64KiB 5.04M/s 32KiB 4.5M/s 16KiB 4.3M/s 5 1MiB 5.22M/s 512KiB 5.2M/s 256KiB 4.6M/s 128KiB 4.73M/s 64KiB 4.22M/s 32KiB 3.8M/s 16KiB 3.25M/s 6 1MiB 5.27M/s 512KiB 5.08M/s 256KiB 4.11M/s 128KiB 3.28M/s 64KiB 4.05M/s 32KiB 3.52M/s 16KiB 3M/s
It's not completely clear from the data, but I think the difference between 4 and 5 is significant, so I'd mark this card down as having four 1MB segments open, with a question mark. It may be doing something slightly smarter, because I would expect a much sharper drop in performance.
tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random 1MiB 4.76M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 5.53M/s 512KiB 5.02M/s 4.71M/s 4.42M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.77M/s 4.9M/s 4.77M/s 256KiB 4.38M/s 4.43M/s 4.59M/s 4.46M/s 4.59M/s 4.59M/s 4.59M/s 4.59M/s 4.9M/s 4.9M/s 128KiB 4.3M/s 4.67M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.55M/s 4.51M/s 4.57M/s 4.65M/s 64KiB 4.73M/s 4.58M/s 4.64M/s 4.62M/s 4.64M/s 4.64M/s 4.63M/s 4.63M/s 4.59M/s 4.62M/s 32KiB 4.45M/s 4.44M/s 4.45M/s 4.45M/s 4.44M/s 4.46M/s 4.45M/s 4.44M/s 4.43M/s 4.63M/s 16KiB 4.35M/s 4.26M/s 4.27M/s 4.27M/s 4.27M/s 4.27M/s 4.2M/s 4.26M/s 4.26M/s 4.26M/s
The first column seems different from all the other ones, so I'd assume that the card is meant for FAT16 with the FAT stored in the first megabyte, which is reasonable for a 2 GB card.
The one number that is currently missing is the page size. Can you rerun the findfat test with --blocksize=512?
Here you are :
tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random --blocksize=512 sched_setscheduler: Operation not permitted 1MiB 5.45M/s 5.53M/s 5.55M/s 5.55M/s 5.54M/s 5.55M/s 4.77M/s 4.77M/s 4.44M/s 4.77M/s 512KiB 5.04M/s 5.2M/s 5.04M/s 4.79M/s 4.92M/s 4.92M/s 4.61M/s 4.61M/s 4.85M/s 4.85M/s 256KiB 4.4M/s 4.44M/s 4.6M/s 4.47M/s 4.91M/s 4.92M/s 4.6M/s 4.6M/s 4.6M/s 4.61M/s 128KiB 4.31M/s 4.69M/s 4.57M/s 4.57M/s 4.57M/s 4.57M/s 4.41M/s 4.52M/s 4.59M/s 4.66M/s 64KiB 4.74M/s 4.59M/s 4.66M/s 4.64M/s 4.66M/s 4.66M/s 4.64M/s 4.64M/s 4.61M/s 4.64M/s 32KiB 4.46M/s 4.45M/s 4.47M/s 4.47M/s 4.45M/s 4.47M/s 4.46M/s 4.47M/s 4.44M/s 4.45M/s 16KiB 4.27M/s 4.28M/s 4.28M/s 4.28M/s 4.27M/s 4.27M/s 4.27M/s 4.21M/s 4.27M/s 4.27M/s 8KiB 3.31M/s 3.35M/s 3.35M/s 3.34M/s 3.35M/s 3.32M/s 3.35M/s 3.35M/s 3.35M/s 3.35M/s 4KiB 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2KiB 1.44M/s 1.43M/s 1.43M/s 1.43M/s 1.43M/s 1.43M/s 1.42M/s 1.43M/s 1.43M/s 1.43M/s 1KiB 798K/s 799K/s 801K/s 800K/s 799K/s 798K/s 801K/s 799K/s 800K/s 800K/s 512B 423K/s 422K/s 423K/s 422K/s 423K/s 422K/s 423K/s 422K/s 424K/s 423K/s tmp179:~ #
I have added the other data from your test to https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCard... and hope that you are still motivated to do similar tests on other cards. That should be much faster now.
No problem. Do you describe somewhere, or better, let flashbench implement it, the steps to test a card ?
Here are the first results for "Kingston 4GB 133X elite pro CF/4GB-S2":
tmp179:~ # cat /proc/partitions major minor #blocks name 8 32 3940272 sdc 8 33 3936240 sdc1 tmp179:~ # ./flashbench -a -b 1024 /dev/sdc sched_setscheduler: Operation not permitted align 134217728 pre 507µs on 760µs post 481µs diff 266µs align 67108864 pre 504µs on 754µs post 481µs diff 262µs align 33554432 pre 505µs on 753µs post 479µs diff 261µs align 16777216 pre 506µs on 753µs post 480µs diff 260µs align 8388608 pre 506µs on 754µs post 479µs diff 261µs align 4194304 pre 505µs on 758µs post 479µs diff 266µs align 2097152 pre 505µs on 756µs post 480µs diff 263µs align 1048576 pre 505µs on 673µs post 485µs diff 178µs align 524288 pre 510µs on 671µs post 484µs diff 174µs align 262144 pre 506µs on 674µs post 483µs diff 180µs align 131072 pre 507µs on 666µs post 486µs diff 170µs align 65536 pre 497µs on 668µs post 478µs diff 181µs align 32768 pre 503µs on 666µs post 480µs diff 174µs align 16384 pre 497µs on 668µs post 481µs diff 179µs align 8192 pre 503µs on 666µs post 478µs diff 176µs align 4096 pre 493µs on 491µs post 489µs diff 171ns align 2048 pre 481µs on 487µs post 489µs diff 2.21µs tmp179:~ #
I'll also retest my own two CF cards for comparison.
Thanks for all your help!
It has been a pleasure.
Philippe
On Tuesday 15 March 2011, Philippe De Muyter wrote:
On Tue, Mar 15, 2011 at 02:48:43PM +0100, Arnd Bergmann wrote:
tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[1024 * 1024] /dev/sdb --random --blocksize=512 sched_setscheduler: Operation not permitted 1MiB 5.45M/s 5.53M/s 5.55M/s 5.55M/s 5.54M/s 5.55M/s 4.77M/s 4.77M/s 4.44M/s 4.77M/s 512KiB 5.04M/s 5.2M/s 5.04M/s 4.79M/s 4.92M/s 4.92M/s 4.61M/s 4.61M/s 4.85M/s 4.85M/s 256KiB 4.4M/s 4.44M/s 4.6M/s 4.47M/s 4.91M/s 4.92M/s 4.6M/s 4.6M/s 4.6M/s 4.61M/s 128KiB 4.31M/s 4.69M/s 4.57M/s 4.57M/s 4.57M/s 4.57M/s 4.41M/s 4.52M/s 4.59M/s 4.66M/s 64KiB 4.74M/s 4.59M/s 4.66M/s 4.64M/s 4.66M/s 4.66M/s 4.64M/s 4.64M/s 4.61M/s 4.64M/s 32KiB 4.46M/s 4.45M/s 4.47M/s 4.47M/s 4.45M/s 4.47M/s 4.46M/s 4.47M/s 4.44M/s 4.45M/s 16KiB 4.27M/s 4.28M/s 4.28M/s 4.28M/s 4.27M/s 4.27M/s 4.27M/s 4.21M/s 4.27M/s 4.27M/s 8KiB 3.31M/s 3.35M/s 3.35M/s 3.34M/s 3.35M/s 3.32M/s 3.35M/s 3.35M/s 3.35M/s 3.35M/s 4KiB 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2.33M/s 2KiB 1.44M/s 1.43M/s 1.43M/s 1.43M/s 1.43M/s 1.43M/s 1.42M/s 1.43M/s 1.43M/s 1.43M/s 1KiB 798K/s 799K/s 801K/s 800K/s 799K/s 798K/s 801K/s 799K/s 800K/s 800K/s 512B 423K/s 422K/s 423K/s 422K/s 423K/s 422K/s 423K/s 422K/s 424K/s 423K/s tmp179:~ #
Ok, it seems that the page size 4 KB here, since writing anything smaller than 4 KB gets only half the performance, i.e. it takes the same time to write the entire 4 KB page as it takes to write only 512 bytes when the raw NAND writes 4 KB anyway.
No problem. Do you describe somewhere, or better, let flashbench implement it, the steps to test a card ?
I should extend the README file that comes with flashbench, but haven't gotten to that. The basic steps are always:
1. find out erase block size 2. find number of open erase blocks (random and linear) 3. find possible FAT optimized area 4. get identification from card (name, size, usb id) where applicable
Here are the first results for "Kingston 4GB 133X elite pro CF/4GB-S2":
tmp179:~ # cat /proc/partitions major minor #blocks name 8 32 3940272 sdc 8 33 3936240 sdc1 tmp179:~ # ./flashbench -a -b 1024 /dev/sdc sched_setscheduler: Operation not permitted align 134217728 pre 507µs on 760µs post 481µs diff 266µs align 67108864 pre 504µs on 754µs post 481µs diff 262µs align 33554432 pre 505µs on 753µs post 479µs diff 261µs align 16777216 pre 506µs on 753µs post 480µs diff 260µs align 8388608 pre 506µs on 754µs post 479µs diff 261µs align 4194304 pre 505µs on 758µs post 479µs diff 266µs align 2097152 pre 505µs on 756µs post 480µs diff 263µs align 1048576 pre 505µs on 673µs post 485µs diff 178µs align 524288 pre 510µs on 671µs post 484µs diff 174µs align 262144 pre 506µs on 674µs post 483µs diff 180µs align 131072 pre 507µs on 666µs post 486µs diff 170µs align 65536 pre 497µs on 668µs post 478µs diff 181µs align 32768 pre 503µs on 666µs post 480µs diff 174µs align 16384 pre 497µs on 668µs post 481µs diff 179µs align 8192 pre 503µs on 666µs post 478µs diff 176µs align 4096 pre 493µs on 491µs post 489µs diff 171ns align 2048 pre 481µs on 487µs post 489µs diff 2.21µs
Excellent: Here you can see very clearly by looking at the final column that the card has a 2 MB erase block size and a 4 KB page size.
Doing the tests --findfat and --open-au tests with --erasesize=$[2 * 1024 * 1024] and --blocksize=4096 should be very straightforward on this one. My personal guess from having worked with Kingston SD cards is that that it will be much worse than the Transcend card.
Arnd
On Tue, Mar 15, 2011 at 04:38:06PM +0100, Arnd Bergmann wrote:
I should extend the README file that comes with flashbench, but haven't gotten to that. The basic steps are always:
- find out erase block size
- find number of open erase blocks (random and linear)
- find possible FAT optimized area
- get identification from card (name, size, usb id) where applicable
Here are the first results for "Kingston 4GB 133X elite pro CF/4GB-S2":
tmp179:~ # cat /proc/partitions major minor #blocks name 8 32 3940272 sdc 8 33 3936240 sdc1 tmp179:~ # ./flashbench -a -b 1024 /dev/sdc sched_setscheduler: Operation not permitted align 134217728 pre 507µs on 760µs post 481µs diff 266µs align 67108864 pre 504µs on 754µs post 481µs diff 262µs align 33554432 pre 505µs on 753µs post 479µs diff 261µs align 16777216 pre 506µs on 753µs post 480µs diff 260µs align 8388608 pre 506µs on 754µs post 479µs diff 261µs align 4194304 pre 505µs on 758µs post 479µs diff 266µs align 2097152 pre 505µs on 756µs post 480µs diff 263µs align 1048576 pre 505µs on 673µs post 485µs diff 178µs align 524288 pre 510µs on 671µs post 484µs diff 174µs align 262144 pre 506µs on 674µs post 483µs diff 180µs align 131072 pre 507µs on 666µs post 486µs diff 170µs align 65536 pre 497µs on 668µs post 478µs diff 181µs align 32768 pre 503µs on 666µs post 480µs diff 174µs align 16384 pre 497µs on 668µs post 481µs diff 179µs align 8192 pre 503µs on 666µs post 478µs diff 176µs align 4096 pre 493µs on 491µs post 489µs diff 171ns align 2048 pre 481µs on 487µs post 489µs diff 2.21µs
Excellent: Here you can see very clearly by looking at the final column that the card has a 2 MB erase block size and a 4 KB page size.
Doing the tests --findfat and --open-au tests with --erasesize=$[2 * 1024 * 1024] and --blocksize=4096 should be very straightforward on this one. My personal guess from having worked with Kingston SD cards is that that it will be much worse than the Transcend card.
Here you are :
Just a small remark : when I run --open-au with a high --open-au-nr= value (here higher than 4 or 5), it takes a very very long time to complete for the smaller block size.
tmp179:~ # smartctl --all -T permissive /dev/sdc smartctl 5.40 2010-10-16 r3189 [i686-pc-linux-gnu] (SUSE RPM) Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF INFORMATION SECTION === Device Model: ELITE PRO CF CARD 4GB Serial Number: 5B921800 Firmware Version: Ver2.21K User Capacity: 4,034,838,528 bytes Device is: Not in smartctl database [for details use: -P showall] ATA Version is: [No Information Found] ATA Standard is: [No Information Found] Local Time is: Tue Mar 15 17:25:49 2011 CET SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 82-83 don't show if SMART supported. SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 85-87 don't show if SMART is enabled. Checking to be sure by trying SMART RETURN STATUS command. SMART support is: Unknown - Try option -s with argument 'on' to enable it. A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options. tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[2 * 1024 * 1024] --blocksize=4096 /dev/sdc --random; done 1 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 3.2M/s 256KiB 2.69M/s 128KiB 2.99M/s 64KiB 3.66M/s 32KiB 3M/s 16KiB 2.66M/s 8KiB 2.08M/s 4KiB 1.29M/s 2 sched_setscheduler: Operation not permitted 2MiB 4.08M/s 1MiB 4.07M/s 512KiB 3.19M/s 256KiB 2.68M/s 128KiB 3.01M/s 64KiB 3.66M/s 32KiB 3M/s 16KiB 2.66M/s 8KiB 2.08M/s 4KiB 1.29M/s 3 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 3.2M/s 256KiB 2.69M/s 128KiB 3M/s 64KiB 3.66M/s 32KiB 3.01M/s 16KiB 2.67M/s 8KiB 2.08M/s 4KiB 1.29M/s 4 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 3.2M/s 256KiB 2.69M/s 128KiB 3M/s 64KiB 3.67M/s 32KiB 3.01M/s 16KiB 2.67M/s 8KiB 2.09M/s 4KiB 1.3M/s 5 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.74M/s 512KiB 2.69M/s 256KiB 1.54M/s 128KiB 924K/s 64KiB 450K/s 32KiB 232K/s 16KiB 116K/s 8KiB 52.9K/s 4KiB 26.7K/s 6 sched_setscheduler: Operation not permitted 2MiB 4.08M/s 1MiB 3.65M/s 512KiB 2.62M/s 256KiB 1.53M/s 128KiB 908K/s 64KiB 448K/s 32KiB 231K/s 16KiB 117K/s 8KiB 53.7K/s 4KiB 27K/s 7 sched_setscheduler: Operation not permitted 2MiB 4.08M/s 1MiB 3.58M/s 512KiB 2.56M/s 256KiB 1.5M/s 128KiB 894K/s 64KiB 446K/s 32KiB 230K/s 16KiB 116K/s 8KiB 53.7K/s 4KiB 27K/s 8 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.53M/s 512KiB 2.52M/s 256KiB 1.48M/s 128KiB 875K/s 64KiB 442K/s 32KiB 228K/s 16KiB 115K/s 8KiB 53.8K/s 4KiB 27K/s 9 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.49M/s 512KiB 2.48M/s 256KiB 1.48M/s 128KiB 863K/s 64KiB 439K/s 32KiB 227K/s 16KiB 115K/s 8KiB 53.8K/s 4KiB 27K/s 10 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.46M/s 512KiB 2.46M/s 256KiB 1.47M/s 128KiB 857K/s 64KiB 439K/s 32KiB 226K/s 16KiB 115K/s 8KiB 53.6K/s 4KiB 26.9K/s tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[2 * 1024 * 1024] --blocksize=4096 /dev/sdc; done 1 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.06M/s 512KiB 4.07M/s 256KiB 4.06M/s 128KiB 4.06M/s 64KiB 4.01M/s 32KiB 3.82M/s 16KiB 3.56M/s 8KiB 3.06M/s 4KiB 2.01M/s 2 sched_setscheduler: Operation not permitted 2MiB 4.08M/s 1MiB 4.06M/s 512KiB 4.07M/s 256KiB 4.07M/s 128KiB 4.07M/s 64KiB 4.01M/s 32KiB 3.82M/s 16KiB 3.56M/s 8KiB 3.13M/s 4KiB 2.01M/s 3 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 4.07M/s 256KiB 4.07M/s 128KiB 4.07M/s 64KiB 4.01M/s 32KiB 3.82M/s 16KiB 3.56M/s 8KiB 3.12M/s 4KiB 2.01M/s 4 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 4.07M/s 256KiB 4.07M/s 128KiB 4.07M/s 64KiB 4.01M/s 32KiB 3.82M/s 16KiB 3.55M/s 8KiB 3.13M/s 4KiB 2.01M/s 5 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.74M/s 512KiB 2.72M/s 256KiB 1.76M/s 128KiB 1.03M/s 64KiB 554K/s 32KiB 282K/s 16KiB 141K/s 8KiB 53.8K/s 4KiB 27.1K/s 6 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.65M/s 512KiB 2.63M/s 256KiB 1.69M/s 128KiB 986K/s 64KiB 534K/s 32KiB 276K/s 16KiB 137K/s 8KiB 54.2K/s 4KiB 27.3K/s 7 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.58M/s 512KiB 2.58M/s 256KiB 1.65M/s 128KiB 957K/s 64KiB 517K/s 32KiB 266K/s 16KiB 134K/s 8KiB 54.2K/s 4KiB 27.3K/s 8 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.54M/s 512KiB 2.53M/s 256KiB 1.62M/s 128KiB 938K/s 64KiB 506K/s 32KiB 260K/s 16KiB 130K/s 8KiB 54.4K/s 4KiB 27.3K/s 9 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.49M/s 512KiB 2.5M/s 256KiB 1.59M/s 128KiB 921K/s 64KiB 496K/s 32KiB 256K/s 16KiB 128K/s 8KiB 54.4K/s 4KiB 27.3K/s 10 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.46M/s 512KiB 2.47M/s 256KiB 1.57M/s 128KiB 907K/s 64KiB 488K/s 32KiB 252K/s 16KiB 127K/s 8KiB 54.2K/s 4KiB 27.3K/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[2 * 1024 * 1024] /dev/sdc --random --blocksize=512 sched_setscheduler: Operation not permitted 2MiB 3.14M/s 4.07M/s 4.07M/s 4.07M/s 4.07M/s 4.06M/s 4.06M/s 4.06M/s 2.53M/s 4.08M/s 1MiB 3.64M/s 3.65M/s 3.15M/s 3.15M/s 3.34M/s 3.34M/s 3.33M/s 3.34M/s 3.34M/s 3.35M/s 512KiB 2.67M/s 2.68M/s 2.68M/s 2.66M/s 2.61M/s 2.6M/s 2.6M/s 2.62M/s 2.62M/s 2.63M/s 256KiB 2.33M/s 2.33M/s 2.34M/s 2.34M/s 2.33M/s 2.31M/s 2.32M/s 2.33M/s 2.32M/s 2.3M/s 128KiB 2.81M/s 2.8M/s 2.82M/s 2.8M/s 2.81M/s 2.82M/s 2.81M/s 2.81M/s 2.8M/s 2.82M/s 64KiB 3.44M/s 3.46M/s 3.44M/s 3.46M/s 3.45M/s 3.43M/s 3.44M/s 3.45M/s 3.46M/s 3.43M/s 32KiB 3.11M/s 3.1M/s 3.09M/s 3.09M/s 3.11M/s 3.09M/s 3.1M/s 3.08M/s 3.1M/s 3.09M/s 16KiB 2.65M/s 2.65M/s 2.64M/s 2.64M/s 2.64M/s 2.65M/s 2.64M/s 2.66M/s 2.65M/s 2.64M/s 8KiB 1.69M/s 2.06M/s 2.07M/s 2.06M/s 2.06M/s 2.09M/s 2.1M/s 2.09M/s 2.1M/s 2.12M/s 4KiB 1.31M/s 1.32M/s 1.31M/s 1.32M/s 1.31M/s 1.31M/s 1.31M/s 1.32M/s 1.33M/s 1.31M/s 2KiB 806K/s 806K/s 793K/s 792K/s 805K/s 793K/s 800K/s 795K/s 801K/s 797K/s 1KiB 445K/s 449K/s 449K/s 446K/s 452K/s 448K/s 447K/s 447K/s 448K/s 450K/s 512B 237K/s 235K/s 234K/s 234K/s 235K/s 235K/s 237K/s 237K/s 236K/s 235K/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[2 * 1024 * 1024] /dev/sdc --random sched_setscheduler: Operation not permitted 2MiB 3.16M/s 4.06M/s 4.08M/s 4.08M/s 4.08M/s 2.63M/s 4.06M/s 2.63M/s 4.07M/s 2.62M/s 1MiB 3.63M/s 3.63M/s 3.64M/s 3.63M/s 3.34M/s 3.34M/s 3.33M/s 3.35M/s 3.34M/s 3.35M/s 512KiB 2.66M/s 2.66M/s 2.67M/s 2.67M/s 2.6M/s 2.61M/s 2.61M/s 2.61M/s 2.61M/s 2.61M/s 256KiB 2.34M/s 2.32M/s 2.31M/s 2.33M/s 2.32M/s 2.31M/s 2.29M/s 2.32M/s 2.32M/s 2.31M/s 128KiB 2.8M/s 2.8M/s 2.81M/s 2.81M/s 2.8M/s 2.81M/s 2.81M/s 2.78M/s 2.81M/s 2.81M/s 64KiB 3.43M/s 3.44M/s 3.46M/s 3.42M/s 3.44M/s 3.45M/s 3.43M/s 3.43M/s 3.43M/s 3.45M/s 32KiB 3.07M/s 3.09M/s 3.08M/s 3.09M/s 3.07M/s 3.09M/s 3.08M/s 3.08M/s 3.07M/s 3.08M/s 16KiB 2.61M/s 2.63M/s 2.63M/s 2.63M/s 2.63M/s 2.63M/s 2.61M/s 2.61M/s 2.64M/s 2.63M/s tmp179:~ #
Philippe
On Wednesday 16 March 2011, Philippe De Muyter wrote:
Just a small remark : when I run --open-au with a high --open-au-nr= value (here higher than 4 or 5), it takes a very very long time to complete for the smaller block size.
Yes, this is the main thing that flashbench is good for: pinpoint the exact pattern that drives a card into its worst-case scenario.
Every row writes exactly one erase block, but when the card runs out of open blocks, a single access in there causes it to garbage- collect another block, the scenario described in this animation: https://lwn.net/Articles/428799/.
In earlier version of flashbench, I would do the --open-au test automatically for a number of settings, like your one-line script does. However, I could not find a good way to stop at the right point, so I decided to make it more manual.
tmp179:~ # smartctl --all -T permissive /dev/sdc smartctl 5.40 2010-10-16 r3189 [i686-pc-linux-gnu] (SUSE RPM) Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF INFORMATION SECTION === Device Model: ELITE PRO CF CARD 4GB Serial Number: 5B921800 Firmware Version: Ver2.21K User Capacity: 4,034,838,528 bytes
Could you also do 'hdparm -i /dev/sdc'? I've added another column in the table for the highest supported PIO/DMA modes.
Are you using UDMA mode?
4 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 4.07M/s 512KiB 3.2M/s 256KiB 2.69M/s 128KiB 3M/s 64KiB 3.67M/s 32KiB 3.01M/s 16KiB 2.67M/s 8KiB 2.09M/s 4KiB 1.3M/s 5 sched_setscheduler: Operation not permitted 2MiB 4.07M/s 1MiB 3.74M/s 512KiB 2.69M/s 256KiB 1.54M/s 128KiB 924K/s 64KiB 450K/s 32KiB 232K/s 16KiB 116K/s 8KiB 52.9K/s 4KiB 26.7K/s
Ok, excellent. It's very clear here that the opmimum I/O size is 64 KB and that 5 open allocation units are not supported, but 4 are. Since the numbers are almost identical between the --random and linear tests, the algorithm used here can write pages randomly within the erase block.
tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[2 * 1024 * 1024] /dev/sdc --random --blocksize=512 sched_setscheduler: Operation not permitted 2MiB 3.14M/s 4.07M/s 4.07M/s 4.07M/s 4.07M/s 4.06M/s 4.06M/s 4.06M/s 2.53M/s 4.08M/s 1MiB 3.64M/s 3.65M/s 3.15M/s 3.15M/s 3.34M/s 3.34M/s 3.33M/s 3.34M/s 3.34M/s 3.35M/s 512KiB 2.67M/s 2.68M/s 2.68M/s 2.66M/s 2.61M/s 2.6M/s 2.6M/s 2.62M/s 2.62M/s 2.63M/s 256KiB 2.33M/s 2.33M/s 2.34M/s 2.34M/s 2.33M/s 2.31M/s 2.32M/s 2.33M/s 2.32M/s 2.3M/s 128KiB 2.81M/s 2.8M/s 2.82M/s 2.8M/s 2.81M/s 2.82M/s 2.81M/s 2.81M/s 2.8M/s 2.82M/s 64KiB 3.44M/s 3.46M/s 3.44M/s 3.46M/s 3.45M/s 3.43M/s 3.44M/s 3.45M/s 3.46M/s 3.43M/s 32KiB 3.11M/s 3.1M/s 3.09M/s 3.09M/s 3.11M/s 3.09M/s 3.1M/s 3.08M/s 3.1M/s 3.09M/s 16KiB 2.65M/s 2.65M/s 2.64M/s 2.64M/s 2.64M/s 2.65M/s 2.64M/s 2.66M/s 2.65M/s 2.64M/s 8KiB 1.69M/s 2.06M/s 2.07M/s 2.06M/s 2.06M/s 2.09M/s 2.1M/s 2.09M/s 2.1M/s 2.12M/s 4KiB 1.31M/s 1.32M/s 1.31M/s 1.32M/s 1.31M/s 1.31M/s 1.31M/s 1.32M/s 1.33M/s 1.31M/s 2KiB 806K/s 806K/s 793K/s 792K/s 805K/s 793K/s 800K/s 795K/s 801K/s 797K/s 1KiB 445K/s 449K/s 449K/s 446K/s 452K/s 448K/s 447K/s 447K/s 448K/s 450K/s 512B 237K/s 235K/s 234K/s 234K/s 235K/s 235K/s 237K/s 237K/s 236K/s 235K/s
Nothing to see regarding the FAT here, but the page size is 4 KB: writing 2 KB blocks is roughly have the throughput of 8 KB, and every lower row further halves this number, while anything above 4 KB is just slightly slower than the row above it.
All in all, the card is much better than any Kingston SD card I've seen, especially the 4KB page size means that it's actually usable with ext3. The total throughput is really low though, but that may be a result of the interface speed.
Arnd
On Thu, Mar 17, 2011 at 11:36:10AM +0100, Arnd Bergmann wrote:
Could you also do 'hdparm -i /dev/sdc'? I've added another column in the table for the highest supported PIO/DMA modes.
Here you are (card is now called sdb) : tmp179:~ # hdparm -i /dev/sdb
/dev/sdb:
Model=ELITE PRO CF CARD 4GB, FwRev=Ver2.21K, SerialNo=5B921800 Config={ HardSect NotMFM Fixed DTR>10Mbs } RawCHS=7818/16/63, TrkSize=32256, SectSize=512, ECCbytes=4 BuffType=DualPort, BuffSize=1kB, MaxMultSect=1, MultSect=off CurCHS=7818/16/63, CurSects=7880544, LBA=yes, LBAsects=7880544 IORDY=no, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120} PIO modes: pio0 pio1 pio2 pio3 pio4 DMA modes: mdma0 mdma1 mdma2 UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5 AdvancedPM=no
* signifies the current active mode
tmp179:~ #
Are you using UDMA mode?
How can I find out ? I put the card in the slot and let linux decide.
tmp179:~ # time dd if=/dev/sdb bs=2M of=/dev/null 1923+1 records in 1923+1 records out 4034838528 bytes (4.0 GB) copied, 89.579 s, 45.0 MB/s
real 1m29.612s user 0m0.002s sys 0m5.923s tmp179:~ # time dd if=/dev/zero bs=2M of=/dev/sdb dd: writing `/dev/sdb': No space left on device 1924+0 records in 1923+0 records out 4034838528 bytes (4.0 GB) copied, 185.682 s, 21.7 MB/s
real 3m6.010s user 0m0.001s sys 0m3.036s tmp179:~ # dmesg [...] [692014.258018] ata3: hard resetting link [692014.867054] ata3: SATA link up 1.5 Gbps (SStatus 113 SControl 300) [692014.873211] ata3.00: ATA-0: ELITE PRO CF CARD 4GB, Ver2.21K, max UDMA/100 [692014.873219] ata3.00: 7880544 sectors, multi 0: LBA [692014.873224] ata3.00: applying bridge limits [692014.876197] ata3.00: configured for UDMA/100 [692014.876216] ata3: EH complete [692014.876224] ata3.00: detaching (SCSI 2:0:0:0) [692014.879109] sd 2:0:0:0: [sdb] Stopping disk [692014.879426] scsi 2:0:0:0: Direct-Access ATA ELITE PRO CF CAR Ver2 PQ: 0 ANSI: 5 [692014.879571] sd 2:0:0:0: Attached scsi generic sg1 type 0 [692014.879634] sd 2:0:0:0: [sdb] 7880544 512-byte logical blocks: (4.03 GB/3.75 GiB) [692014.879694] sd 2:0:0:0: [sdb] Write Protect is off [692014.879702] sd 2:0:0:0: [sdb] Mode Sense: 00 3a 00 00 [692014.879725] sd 2:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA [692014.881541] sdb: unknown partition table [692014.881704] sd 2:0:0:0: [sdb] Attached SCSI disk tmp179:~ #
Philippe
On Thursday 17 March 2011, Philippe De Muyter wrote:
PIO modes: pio0 pio1 pio2 pio3 pio4 DMA modes: mdma0 mdma1 mdma2 UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5 AdvancedPM=no
- signifies the current active mode
Ok, thanks!
Are you using UDMA mode?
How can I find out ? I put the card in the slot and let linux decide.
In the list above, you can see the * next to the active mode. The card is evidently using UDMA5, meaning it can get up to 100 MB/s in terms of interface speed. This makes the 4 MB/s maximum throughput even more disappointing, but means that your host system is able to drive cards in very fast modes.
A lot of cards apparently only support the slower PIO modes, and with a PCMCIA adapter, you would only get pio0 with 3.3 MB/s maximum interface speed.
Arnd
On Thu, Mar 17, 2011 at 01:29:27PM +0100, Arnd Bergmann wrote:
In the list above, you can see the * next to the active mode. The card is evidently using UDMA5, meaning it can get up to 100 MB/s in terms of interface speed. This makes the 4 MB/s maximum throughput even more disappointing, but means that your host system is able to drive cards in very fast modes.
A lot of cards apparently only support the slower PIO modes, and with a PCMCIA adapter, you would only get pio0 with 3.3 MB/s maximum interface speed.
OK, thanks
Here is another (older) one. Package says : "Sony CompactFlash 66x 10MB/s [Read] 1GB" and on reverse side "NCFB1G"
tmp179:~ # hdparm -i /dev/sdc
/dev/sdc:
Model=Sony NCFB1G, FwRev=HDX 4.07, SerialNo=110621A1797H5232 Config={ HardSect NotMFM Removeable DTR>10Mbs nonMagnetic } RawCHS=1986/16/63, TrkSize=0, SectSize=576, ECCbytes=4 BuffType=DualPort, BuffSize=1kB, MaxMultSect=4, MultSect=off CurCHS=1986/16/63, CurSects=2001888, LBA=yes, LBAsects=2001888 IORDY=no, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120} PIO modes: pio0 pio1 pio2 pio3 pio4 DMA modes: mdma0 mdma1 *mdma2 AdvancedPM=no Drive conforms to: Unspecified: ATA/ATAPI-4
* signifies the current active mode
tmp179:~ # ./flashbench -a -b 1024 /dev/sdc sched_setscheduler: Operation not permitted align 33554432 pre 588µs on 867µs post 567µs diff 289µs align 16777216 pre 577µs on 876µs post 568µs diff 303µs align 8388608 pre 588µs on 732µs post 573µs diff 151µs align 4194304 pre 582µs on 722µs post 566µs diff 148µs align 2097152 pre 582µs on 724µs post 567µs diff 149µs align 1048576 pre 583µs on 723µs post 566µs diff 148µs align 524288 pre 582µs on 722µs post 566µs diff 148µs align 262144 pre 577µs on 584µs post 571µs diff 10.1µs align 131072 pre 577µs on 584µs post 571µs diff 10.4µs align 65536 pre 577µs on 584µs post 571µs diff 9.98µs align 32768 pre 575µs on 586µs post 572µs diff 13.2µs align 16384 pre 577µs on 587µs post 574µs diff 11.1µs align 8192 pre 571µs on 579µs post 571µs diff 7.57µs align 4096 pre 567µs on 574µs post 566µs diff 7.31µs align 2048 pre 566µs on 573µs post 566µs diff 6.57µs tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[512 * 1024] --blocksize=8192 /dev/sdc --random; done 1 sched_setscheduler: Operation not permitted 512KiB 5.39M/s 256KiB 12.7M/s 128KiB 10.2M/s 64KiB 10.3M/s 32KiB 9.35M/s 16KiB 7.42M/s 8KiB 6.53M/s 2 sched_setscheduler: Operation not permitted 512KiB 12.9M/s 256KiB 13M/s 128KiB 10.6M/s 64KiB 8.92M/s 32KiB 8.08M/s 16KiB 6.78M/s 8KiB 4.62M/s 3 sched_setscheduler: Operation not permitted 512KiB 12.9M/s 256KiB 13M/s 128KiB 11.6M/s 64KiB 8.2M/s 32KiB 7.13M/s 16KiB 6.05M/s 8KiB 4.37M/s 4 sched_setscheduler: Operation not permitted 512KiB 12.9M/s 256KiB 8.07M/s 128KiB 2.8M/s 64KiB 1.26M/s 32KiB 604K/s 16KiB 298K/s 8KiB 148K/s 5 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 6.1M/s 128KiB 2.75M/s 64KiB 1.25M/s 32KiB 604K/s 16KiB 298K/s 8KiB 148K/s 6 sched_setscheduler: Operation not permitted 512KiB 12.9M/s 256KiB 6.04M/s 128KiB 2.74M/s 64KiB 1.25M/s 32KiB 605K/s 16KiB 299K/s 8KiB 148K/s 7 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.99M/s 128KiB 2.73M/s 64KiB 1.25M/s 32KiB 605K/s 16KiB 299K/s 8KiB 149K/s 8 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.99M/s 128KiB 2.71M/s 64KiB 1.25M/s 32KiB 606K/s 16KiB 299K/s 8KiB 149K/s 9 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.94M/s 128KiB 2.71M/s 64KiB 1.25M/s 32KiB 607K/s 16KiB 299K/s 8KiB 149K/s 10 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.91M/s 128KiB 2.7M/s 64KiB 1.25M/s 32KiB 607K/s 16KiB 299K/s 8KiB 149K/s tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[512 * 1024] --blocksize=8192 /dev/sdc; done 1 sched_setscheduler: Operation not permitted 512KiB 5.3M/s 256KiB 12.8M/s 128KiB 12.9M/s 64KiB 11.8M/s 32KiB 10.1M/s 16KiB 7.82M/s 8KiB 6.85M/s 2 sched_setscheduler: Operation not permitted 512KiB 12.9M/s 256KiB 13M/s 128KiB 13.1M/s 64KiB 12.2M/s 32KiB 10.7M/s 16KiB 8.6M/s 8KiB 6.82M/s 3 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 13M/s 128KiB 13.1M/s 64KiB 12.3M/s 32KiB 10.9M/s 16KiB 8.87M/s 8KiB 6.8M/s 4 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 7.52M/s 128KiB 2.79M/s 64KiB 1.26M/s
32KiB 608K/s 16KiB 300K/s 8KiB 149K/s 5 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 6.16M/s 128KiB 2.77M/s 64KiB 1.26M/s 32KiB 608K/s 16KiB 300K/s 8KiB 149K/s 6 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 6.04M/s 128KiB 2.74M/s 64KiB 1.26M/s 32KiB 608K/s 16KiB 300K/s 8KiB 149K/s 7 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 6.02M/s 128KiB 2.74M/s 64KiB 1.26M/s 32KiB 608K/s 16KiB 300K/s 8KiB 149K/s 8 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.98M/s 128KiB 2.72M/s 64KiB 1.25M/s 32KiB 608K/s 16KiB 300K/s 8KiB 149K/s 9 sched_setscheduler: Operation not permitted 512KiB 13M/s 256KiB 5.98M/s 128KiB 2.72M/s 64KiB 1.26M/s 32KiB 609K/s 16KiB 301K/s 8KiB 149K/s 10 sched_setscheduler: Operation not permitted 512KiB 13.1M/s 256KiB 5.93M/s 128KiB 2.7M/s 64KiB 1.25M/s 32KiB 609K/s 16KiB 301K/s 8KiB 149K/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[512 * 1024] /dev/sdcsched_setscheduler: Operation not permitted 512KiB 5.62M/s 5.21M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 256KiB 13.1M/s 13.1M/s 13.2M/s 13.2M/s 13.1M/s 13.1M/s 13.2M/s 13.1M/s 13.2M/s 13.2M/s 128KiB 13.2M/s 13.2M/s 13.2M/s 13.3M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.3M/s 13.3M/s 64KiB 12.5M/s 12.5M/s 12.5M/s 12.5M/s 12.6M/s 12.5M/s 12.5M/s 12.4M/s 12.6M/s 12.5M/s 32KiB 11.3M/s 11.2M/s 11.2M/s 11.3M/s 11.5M/s 11.3M/s 11.5M/s 11.2M/s 11.3M/s 11.2M/s 16KiB 9.28M/s 9.59M/s 9.41M/s 9.49M/s 9.27M/s 9.51M/s 9.35M/s 9.41M/s 9.3M/s 9.32M/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[512 * 1024] /dev/sdcsched_setscheduler: Operation not permitted 512KiB 13.1M/s 5.17M/s 13.2M/s 13.2M/s 13.1M/s 13.2M/s 13.1M/s 13.2M/s 13.1M/s 13.2M/s 256KiB 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.1M/s 13.1M/s 13.2M/s 13.2M/s 128KiB 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.3M/s 64KiB 12.6M/s 12.5M/s 12.6M/s 12.6M/s 12.5M/s 12.6M/s 12.5M/s 12.3M/s 12.5M/s 12.6M/s 32KiB 11.4M/s 11.4M/s 11.2M/s 11.2M/s 11.3M/s 11.2M/s 11.3M/s 11.3M/s 11.2M/s 11.1M/s 16KiB 9.29M/s 9.38M/s 9.29M/s 9.26M/s 9.29M/s 9.27M/s 9.23M/s 9.26M/s 9.22M/s 9.32M/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[512 * 1024] --blocksize=8192 /dev/sdc sched_setscheduler: Operation not permitted 512KiB 13M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 256KiB 13.1M/s 13.2M/s 13.2M/s 13.1M/s 13.1M/s 13.2M/s 13.1M/s 13.2M/s 13.2M/s 13.1M/s 128KiB 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.3M/s 13.3M/s 13.2M/s 64KiB 12.5M/s 12.5M/s 12.5M/s 12.5M/s 12.5M/s 12.6M/s 12.6M/s 12.4M/s 12.6M/s 12.5M/s 32KiB 11.2M/s 11.2M/s 11.3M/s 11.5M/s 11.3M/s 11.5M/s 11.3M/s 11.3M/s 11.2M/s 11.1M/s 16KiB 9.01M/s 9.38M/s 9.37M/s 9.52M/s 9.28M/s 9.47M/s 9.33M/s 9.4M/s 9.29M/s 9.31M/s 8KiB 6.82M/s 6.83M/s 6.81M/s 6.8M/s 6.84M/s 6.81M/s 6.78M/s 6.78M/s 6.82M/s 6.88M/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[512 * 1024] --blocksize=1024 /dev/sdc sched_setscheduler: Operation not permitted 512KiB 13.1M/s 13.2M/s 13.1M/s 5.17M/s 13.1M/s 13.1M/s 13.1M/s 13.1M/s 13.2M/s 13.1M/s 256KiB 13.2M/s 13.1M/s 13.2M/s 13.2M/s 13.1M/s 13.2M/s 13.1M/s 13.2M/s 13.2M/s 13.2M/s 128KiB 13.2M/s 13.2M/s 13.3M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.2M/s 13.3M/s 64KiB 12.6M/s 12.5M/s 12.5M/s 12.5M/s 12.5M/s 12.6M/s 12.5M/s 12.5M/s 12.5M/s 12.4M/s 32KiB 11.2M/s 11.3M/s 11.2M/s 11.2M/s 11.2M/s 11.2M/s 11.2M/s 11.2M/s 11.3M/s 11.2M/s 16KiB 9.34M/s 9.17M/s 9.22M/s 9.25M/s 9.38M/s 9.31M/s 9.34M/s 9.32M/s 9.26M/s 9.31M/s 8KiB 6.83M/s 6.8M/s 6.77M/s 6.69M/s 6.81M/s 6.8M/s 6.82M/s 6.89M/s 6.79M/s 6.79M/s 4KiB 4.49M/s 4.52M/s 4.54M/s 4.48M/s 4.51M/s 4.42M/s 4.5M/s 4.58M/s 4.49M/s 4.48M/s 2KiB 2.48M/s 2.47M/s 2.47M/s 2.45M/s 2.52M/s 2.5M/s 2.52M/s 2.5M/s 2.49M/s 2.41M/s 1KiB 1.28M/s 1.28M/s 1.25M/s 1.28M/s 1.28M/s 1.26M/s 1.28M/s 1.26M/s 1.26M/s 1.28M/s tmp179:~ # time dd if=/dev/sdc bs=512K of=/dev/null 1954+1 records in 1954+1 records out 1024966656 bytes (1.0 GB) copied, 71.3464 s, 14.4 MB/s
real 1m11.348s user 0m0.001s sys 0m1.550s tmp179:~ # time dd if=/dev/zero bs=512K of=/dev/sdc dd: writing `/dev/sdc': No space left on device 1955+0 records in 1954+0 records out 1024966656 bytes (1.0 GB) copied, 81.3408 s, 12.6 MB/s
real 1m21.342s user 0m0.000s sys 0m0.915s tmp179:~ # time dd if=/dev/zero bs=2M of=/dev/sdc dd: writing `/dev/sdc': No space left on device 489+0 records in 488+0 records out 1024966656 bytes (1.0 GB) copied, 81.2364 s, 12.6 MB/s
real 1m21.238s user 0m0.000s sys 0m0.912s tmp179:~ # time dd if=/dev/sdc bs=2M of=/dev/null 488+1 records in 488+1 records out 1024966656 bytes (1.0 GB) copied, 71.3836 s, 14.4 MB/s
real 1m11.386s user 0m0.002s sys 0m1.586s tmp179:~ #
Philippe
On Thursday 17 March 2011, Philippe De Muyter wrote:
Here is another (older) one. Package says : "Sony CompactFlash 66x 10MB/s [Read] 1GB" and on reverse side "NCFB1G"
Added to https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCard...
Thanks,
Arnd
On Thu, Mar 17, 2011 at 04:19:56PM +0100, Arnd Bergmann wrote:
On Thursday 17 March 2011, Philippe De Muyter wrote:
Here is another (older) one. Package says : "Sony CompactFlash 66x 10MB/s [Read] 1GB" and on reverse side "NCFB1G"
Added to https://wiki.linaro.org/WorkingGroups/KernelConsolidation/Projects/FlashCard...
Thanks
Yet another one :
Kingston 4GB CF/4GB
tmp179:~ # hdparm -i /dev/sdb
/dev/sdb:
Model=CF CARD 4GB, FwRev=20091113, SerialNo=20090410 0001462E Config={ HardSect NotMFM Fixed DTR>10Mbs } RawCHS=7785/16/63, TrkSize=0, SectSize=576, ECCbytes=4 BuffType=DualPort, BuffSize=1kB, MaxMultSect=1, MultSect=off CurCHS=7785/16/63, CurSects=7847280, LBA=yes, LBAsects=7847280 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120} PIO modes: pio0 pio1 pio2 pio3 pio4 DMA modes: mdma0 mdma1 mdma2 UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5 AdvancedPM=yes: disabled (255) WriteCache=disabled
* signifies the current active mode
tmp179:~ # hdparm -I /dev/sdb
/dev/sdb:
CompactFlash ATA device Model Number: CF CARD 4GB Serial Number: 20090410 0001462E Firmware Revision: 20091113 Standards: Likely used: 6 Configuration: Logical max current cylinders 7785 7785 heads 16 16 sectors/track 63 63 -- CHS current addressable sectors: 7847280 LBA user addressable sectors: 7847280 Logical/Physical Sector size: 512 bytes device size with M = 1024*1024: 3831 MBytes device size with M = 1000*1000: 4017 MBytes (4 GB) cache/buffer size = 1 KBytes (type=DualPort) Capabilities: LBA, IORDY(can be disabled) bytes avail on r/w long: 4 Standby timer values: spec'd by Vendor R/W multiple sector transfer: Max = 1 Current = 0 Advanced power management level: disabled DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 *udma5 Cycle time: min=120ns recommended=120ns PIO: pio0 pio1 pio2 pio3 pio4 Cycle time: no flow control=120ns IORDY flow control=120ns Commands/features: Enabled Supported: * SMART feature set Power Management feature set Write cache WRITE_BUFFER command READ_BUFFER command NOP cmd CFA feature set Advanced Power Management feature set Mandatory FLUSH_CACHE * SMART error logging * SMART self-test * Gen1 signaling speed (1.5Gb/s) * CFA advanced modes: pio5 pio6 mdma3 mdma4 * CFA Power Level 1 (max 500mA) Integrity word not set (found 0x0000, expected 0x65a5) tmp179:~ # ./flashbench -a -b 1024 /dev/sdb sched_setscheduler: Operation not permitted align 134217728 pre 244µs on 334µs post 234µs diff 94.6µs align 67108864 pre 245µs on 333µs post 233µs diff 94.8µs align 33554432 pre 245µs on 334µs post 233µs diff 95.2µs align 16777216 pre 244µs on 333µs post 233µs diff 94.5µs align 8388608 pre 245µs on 333µs post 233µs diff 94.2µs align 4194304 pre 244µs on 333µs post 232µs diff 95µs align 2097152 pre 244µs on 333µs post 232µs diff 94.8µs align 1048576 pre 233µs on 301µs post 244µs diff 62.5µs align 524288 pre 233µs on 300µs post 244µs diff 61.9µs align 262144 pre 233µs on 300µs post 244µs diff 62.1µs align 131072 pre 233µs on 301µs post 244µs diff 62.1µs align 65536 pre 233µs on 300µs post 244µs diff 61.8µs align 32768 pre 233µs on 300µs post 244µs diff 61.7µs align 16384 pre 232µs on 287µs post 232µs diff 55.5µs align 8192 pre 233µs on 288µs post 232µs diff 56µs align 4096 pre 233µs on 256µs post 233µs diff 23.5µs align 2048 pre 233µs on 252µs post 233µs diff 18.8µs tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[2 * 1024 * 1024] --blocksize=8192 /dev/sdb; done 1 sched_setscheduler: Operation not permitted 2MiB 8.66M/s 1MiB 8.6M/s 512KiB 8.57M/s 256KiB 8.67M/s 128KiB 8.66M/s 64KiB 8.59M/s 32KiB 8.39M/s 16KiB 9.05M/s 8KiB 8.06M/s 2 sched_setscheduler: Operation not permitted 2MiB 8.59M/s 1MiB 8.64M/s 512KiB 8.59M/s 256KiB 8.61M/s 128KiB 8.66M/s 64KiB 8.56M/s 32KiB 8.38M/s 16KiB 9.1M/s 8KiB 8M/s 3 sched_setscheduler: Operation not permitted 2MiB 8.61M/s 1MiB 8.57M/s 512KiB 8.59M/s 256KiB 8.63M/s 128KiB 8.65M/s 64KiB 8.58M/s 32KiB 8.37M/s 16KiB 9.08M/s 8KiB 8.03M/s 4 sched_setscheduler: Operation not permitted 2MiB 8.61M/s 1MiB 8.66M/s 512KiB 8.66M/s 256KiB 8.64M/s 128KiB 8.65M/s 64KiB 8.57M/s 32KiB 8.38M/s 16KiB 9.08M/s 8KiB 8.01M/s 5 sched_setscheduler: Operation not permitted 2MiB 8.67M/s 1MiB 8.66M/s 512KiB 8.68M/s 256KiB 8.67M/s 128KiB 8.67M/s 64KiB 8.59M/s 32KiB 8.4M/s 16KiB 9.12M/s 8KiB 8.03M/s 6 sched_setscheduler: Operation not permitted 2MiB 8.68M/s 1MiB 8.68M/s 512KiB 8.67M/s 256KiB 8.7M/s 128KiB 8.71M/s 64KiB 8.61M/s 32KiB 8.43M/s 16KiB 9.14M/s 8KiB 8.05M/s 7 sched_setscheduler: Operation not permitted 2MiB 8.7M/s 1MiB 8.69M/s 512KiB 8.71M/s 256KiB 8.72M/s 128KiB 8.75M/s 64KiB 8.67M/s 32KiB 8.44M/s 16KiB 9.15M/s 8KiB 8.05M/s 8 sched_setscheduler: Operation not permitted 2MiB 8.72M/s 1MiB 5.87M/s 512KiB 1.5M/s 256KiB 784K/s 128KiB 409K/s ^C tmp179:~ # for i in `seq 1 10`; do echo $i; ./flashbench --open-au --open-au-nr=$i --erasesize=$[2 * 1024 * 1024] --blocksize=4096 /dev/sdb; done 1 sched_setscheduler: Operation not permitted 2MiB 8.85M/s 1MiB 8.86M/s 512KiB 8.93M/s 256KiB 8.89M/s 128KiB 8.94M/s 64KiB 8.86M/s 32KiB 8.62M/s 16KiB 9.36M/s 8KiB 8.26M/s 4KiB 3.86M/s 2 sched_setscheduler: Operation not permitted 2MiB 8.83M/s 1MiB 8.79M/s 512KiB 8.83M/s 256KiB 8.9M/s 128KiB 8.9M/s 64KiB 8.76M/s 32KiB 8.59M/s 16KiB 9.33M/s 8KiB 8.19M/s 4KiB 3.85M/s 3 sched_setscheduler: Operation not permitted 2MiB 8.82M/s 1MiB 8.89M/s 512KiB 8.9M/s 256KiB 8.81M/s 128KiB 8.9M/s 64KiB 8.78M/s 32KiB 8.58M/s 16KiB 9.35M/s 8KiB 8.21M/s 4KiB 3.85M/s 4 sched_setscheduler: Operation not permitted 2MiB 8.8M/s 1MiB 8.83M/s 512KiB 8.9M/s 256KiB 8.86M/s 128KiB 8.88M/s 64KiB 8.79M/s 32KiB 8.62M/s 16KiB 9.3M/s 8KiB 8.19M/s 4KiB 3.84M/s 5 sched_setscheduler: Operation not permitted 2MiB 8.88M/s 1MiB 8.87M/s 512KiB 8.87M/s 256KiB 8.91M/s 128KiB 8.9M/s 64KiB 8.81M/s 32KiB 8.6M/s 16KiB 9.32M/s 8KiB 8.2M/s 4KiB 3.83M/s 6 sched_setscheduler: Operation not permitted 2MiB 8.9M/s 1MiB 8.9M/s 512KiB 8.87M/s 256KiB 8.91M/s 128KiB 8.93M/s 64KiB 8.8M/s 32KiB 8.63M/s 16KiB 9.31M/s 8KiB 8.18M/s 4KiB 3.83M/s 7 sched_setscheduler: Operation not permitted 2MiB 8.91M/s 1MiB 8.88M/s 512KiB 8.91M/s 256KiB 8.92M/s 128KiB 8.93M/s 64KiB 8.82M/s 32KiB 8.62M/s 16KiB 9.3M/s 8KiB 8.17M/s 4KiB 3.83M/s 8 sched_setscheduler: Operation not permitted 2MiB 8.91M/s 1MiB 6M/s 512KiB 1.52M/s 256KiB 795K/s 128KiB 413K/s 64KiB 212K/s 32KiB 107K/s ^C tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[2 * 1024 * 1024] --blocksize=1024 /dev/sdb sched_setscheduler: Operation not permitted 2MiB 3.9M/s 8.96M/s 8.96M/s 9.01M/s 9.04M/s 9.05M/s 8.93M/s 8.92M/s 3.71M/s 8.99M/s 1MiB 9.01M/s 9M/s 9.04M/s 8.99M/s 8.98M/s 8.96M/s 8.98M/s 9.04M/s 8.9M/s 8.95M/s 512KiB 9.05M/s 9.02M/s 8.93M/s 8.93M/s 8.97M/s 8.94M/s 8.97M/s 8.98M/s 9.03M/s 9.04M/s 256KiB 9.04M/s 8.92M/s 9.07M/s 9.04M/s 9.01M/s 9.03M/s 9.07M/s 9.06M/s 9.04M/s 8.97M/s 128KiB 9.06M/s 9.06M/s 8.99M/s 9.06M/s 9.05M/s 9.07M/s 8.96M/s 8.98M/s 9.04M/s 9.05M/s 64KiB 8.97M/s 8.96M/s 8.95M/s 8.91M/s 8.88M/s 8.89M/s 8.95M/s 8.93M/s 8.95M/s 8.86M/s 32KiB 8.68M/s 8.76M/s 8.72M/s 8.7M/s 8.72M/s 8.73M/s 8.69M/s 8.72M/s 8.68M/s 8.72M/s 16KiB 9.47M/s 9.43M/s 9.44M/s 9.39M/s 9.43M/s 9.42M/s 9.44M/s 9.45M/s 9.42M/s 9.46M/s 8KiB 8.34M/s 8.34M/s 8.3M/s 8.29M/s 8.31M/s 8.29M/s 8.33M/s 8.32M/s 8.31M/s 8.29M/s 4KiB 3.89M/s 3.88M/s 3.88M/s 3.89M/s 3.9M/s 3.89M/s 3.89M/s 3.86M/s 3.77M/s 3.75M/s 2KiB 1.9M/s 1.92M/s 1.93M/s 1.92M/s 1.92M/s 1.92M/s 1.92M/s 1.92M/s 1.92M/s 1.92M/s 1KiB 956K/s 956K/s 948K/s 955K/s 955K/s 957K/s 955K/s 954K/s 954K/s 953K/s tmp179:~ # ./flashbench --findfat --fat-nr=10 --erasesize=$[2 * 1024 * 1024] --blocksize=1024 /dev/sdb sched_setscheduler: Operation not permitted 2MiB 8.57M/s 8.66M/s 8.91M/s 8.63M/s 9.01M/s 9.04M/s 8.96M/s 8.64M/s 8.98M/s 8.96M/s 1MiB 8.95M/s 9.01M/s 9.06M/s 9.06M/s 8.94M/s 8.96M/s 9.04M/s 8.77M/s 9M/s 9.04M/s 512KiB 9.04M/s 8.97M/s 8.97M/s 8.98M/s 8.99M/s 8.95M/s 8.98M/s 9.07M/s 9.02M/s 8.94M/s 256KiB 9.01M/s 8.98M/s 8.98M/s 9M/s 8.99M/s 9.05M/s 9.01M/s 9.03M/s 9.04M/s 9.08M/s 128KiB 9.07M/s 9.02M/s 9.04M/s 9.06M/s 9.08M/s 9M/s 9.02M/s 9.05M/s 9.05M/s 8.96M/s 64KiB 8.98M/s 8.89M/s 8.91M/s 8.95M/s 8.89M/s 8.94M/s 8.96M/s 8.94M/s 8.97M/s 8.88M/s 32KiB 8.76M/s 8.69M/s 8.73M/s 8.75M/s 8.76M/s 8.76M/s 8.38M/s 8.7M/s 8.68M/s 8.7M/s 16KiB 9.43M/s 9.44M/s 9.45M/s 9.44M/s 9.04M/s 9.46M/s 9.47M/s 9.46M/s 9.44M/s 9.45M/s 8KiB 8.29M/s 8.32M/s 8.31M/s 8.3M/s 8.34M/s 8.29M/s 8.33M/s 8.24M/s 8.33M/s 8.02M/s 4KiB 3.9M/s 3.9M/s 3.89M/s 3.88M/s 3.89M/s 3.9M/s 3.89M/s 3.84M/s 3.89M/s 3.9M/s 2KiB 1.91M/s 1.91M/s 1.93M/s 1.92M/s 1.92M/s 1.93M/s 1.93M/s 1.92M/s 1.93M/s 1.92M/s 1KiB 955K/s 956K/s 952K/s 953K/s 956K/s 956K/s 956K/s 954K/s 956K/s 953K/s tmp179:~ #
Philippe
On Thursday 17 March 2011 21:04:32 Philippe De Muyter wrote:
Yet another one :
Kingston 4GB CF/4GB
Added. When you have more data, please start a new email thread with the name of the card in the subject, so we can find it more easily in the archive.
Thanks,
Arnd
On Thu, Mar 17, 2011 at 11:03:30PM +0100, Arnd Bergmann wrote:
On Thursday 17 March 2011 21:04:32 Philippe De Muyter wrote:
Yet another one :
Kingston 4GB CF/4GB
Added. When you have more data, please start a new email thread with the name of the card in the subject, so we can find it more easily in the archive.
Thanks, OK and sorry about that.
Philippe
flashbench-results@lists.linaro.org