lkml.org 
[lkml]   [2005]   [Nov]   [19]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateSat, 19 Nov 2005 12:10:34 +0100
FromBart Samwel <>
SubjectRe: Laptop mode causing writes to wrong sectors?
Vojtech Pavlik wrote:

> The issue might be that these people are using
> 
> 	hdparm -S xxx
> 
> 	or
> 
> 	hdparm -y / -Y
> 
> while a much better way to do
> 
> 	hdparm -B 63
> 
> The -S option should in theory be safe, but I remember some drives did
> behave unpredictably if this was used.

Well, some drives have a specific lower limit on the -S values that are 
supported. That's the only compatibility problem I've ever encountered 
with -S. (And you can find out if a drive has a lower limit by checking 
hdparm -i.)

> -y/-Y is much tougher and some
> drives will not work reliably unless first woken up manually before
> issuing a read/write request.

In fact, -Y is problematic but -y usually isn't. -Y puts the drive to 
sleep and requires that Linux reset the complete IDE controller before 
using it again, while -y simply puts the drive in standby mode, leaving 
it up to the drive to decide when it spins up. I've never heard of any 
problems with -y.

> On the other hand, -B is pretty safe on drives that support it, and all
> IBM notebook drives do.

Not true, unfortunately. In fact, I had to change the default config of 
laptop-mode-tools a while ago so that it wouldn't use -B, as it seemed 
to be one of the *causes* of hangup/corruption problems. This was also 
an issue on Thinkpads, and I think it was also noted in the ubuntu bug I 
linked to earlier.

An additional problem is that the values for -B are not really 
standardized, while the values for -S are.

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

\
 
 \ /
  Last update: 2005-11-19 12:15    [from the cache]
©2003-2008