[lkml]   [2005]   [Mar]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Aligning file system data
On Tue, Mar 29, 2005 at 11:32:16PM -0500, John Richard Moser wrote:
> Does crossing a
> track boundary incur anything expensive?

AFAIK, yes. It's going to involve some kind of seeking (even a head
switch needs microjogging on modern drives), and it will certainly add
latency (although I don't remember how much, off the top of my head).

However, trying to control this from the kernel may be vastly harder
than you're expecting (assuming a modern hard drive). You may want to
look at these pages for more info:

Also look at the last paragraph on this page -- not the paragraph with
the "Stop" sign, but the one after it:

I think this could in fact be done, but it would be a lot of effort,
and the kernel would need knowledge on a per-drive-model basis (or
at least it would need a way to obtain such knowledge from user space,
and the per-model knowledge would need to be stored there somehow).
For all I know, vendor-specific commands might also be needed in order
to find out which blocks are remapped, in order to use that knowledge to
avoid changing tracks spuriously. (And one other note: Since your device
almost certainly has many tracks with well over 256 sectors in reality,
your device is actually incapable of reading or writing a single track
with a single ATA command unless it supports LBA48.)

-Barry K. Nathan <>
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-04-06 13:31    [W:0.028 / U:0.816 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site