Re: libata in 2.4.24?

From: Greg Stark
Date: Tue Dec 02 2003 - 13:52:11 EST

Jeff Garzik <jgarzik@xxxxxxxxx> writes:

> If true, this is an IDE driver bug... assuming the drive itself
> doesn't lie about FLUSH CACHE results (a few do).

I don't think the IDE drivers issue FLUSH CACHE after every write on O_SYNC,
or after fsync calls. The "lying" discussed on the database lists is when a
normal write is issued, IDE disks report immediate success even before the
write hits disk. As far as I know from the lists it seems *all* IDE disks
behave this way unless write caching is disabled.

This doesn't happen with SCSI disks where multiple requests can be pending so
there's no urgency to reporting a false success. The request doesn't complete
until the write hits disk. As a result SCSI disks are reliable for database
operation and IDE disks aren't unless write caching is disabled.

> If the drive lies, there isn't a darned thing we can do about it...
> If the drive lies, there isn't a darned thing the controller can do
> about it, either ;-)

Of course not, but the assumption is that they're only lying because of the
lack of a TCQ interface. If they could have multiple requests pending there
would be no need to lie any more at all.

I'm unclear on which of your #2 or #3 will be the solution though. Do either
or both of them require that writes actually hit disk before the drive reports
success? Do either of them allow that semantic without destroying concurrent


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at