Re: [PATCH 16/19] readahead: laptop mode support

From: Bart Samwel
Date: Fri Nov 25 2005 - 11:25:08 EST


Wu Fengguang wrote:
When the laptop drive is spinned down, defer look-ahead to spin up time.

Just a n00b question: isn't readahead something that happens at read time at the block device level? And doesn't the fact that you're reading something imply that the drive is spun up? Or can readahead be triggered by reading from cache?

For crazy laptop users who prefer aggressive read-ahead, here is the way:

# echo 1000 > /proc/sys/vm/readahead_ratio
# blockdev --setra 524280 /dev/hda # this is the max possible value

These amounts of readahead are absolutely useless though. I've done measurements about a year ago, that show that at a spindown time of two minutes you've basically achieved all the power savings you can get. More than 10 minutes of spindown is absolutely useless unless you have a desktop drive, because those don't normally support more than 50,000 spinup cycles. The only apps I can think of that work on this amount of data in such a short period of time are all apps where you shouldn't be concerned about power drawn by the hard drive. :)

--Bart
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/