Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: Re: HDD read ahead cache
From: Bjoern Fischer (bfischer_at_Techfak.Uni-Bielefeld.DE)
Date: 2002-08-15


Hello Uwe,

> HM> According to the ATA/ATAPI command set you should only be able to
> HM> enable/disable the _write_ functionality of the cache. I cannot imagine a
> HM> vendor should disable the read cache which would greatly reduce the
> HM> performance...
>
> But when I read the same sector from disk every minute and the disk
> spins up every time (my 2nd test), it obviously doesn't use the read
> cache. Or do you have another idea why this happened?

I can think of two options:

1. The cache on the HDD acts as a read ahead cache and so a read
operation of the next sector could come from the cache.

2. Some of the operations performed in ata.c (suspend, sleep,
   power off, resetting, etc.) invalidate the cache.

Option 2 is more likely, since ATA-HDD manufactures often implement
the flush cache command as a NOP to make their drives faster in
benchmarks (haha!) and put the real flush cache functionality on
top of some other command (soft reset, sleep, etc.).

So you may want to do some research wrt different spin down
and spin up methods in ata.c.

Björn (Fischer)



Page was last modified "Jan 10 2012" The Rockbox Crew
aaa