Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Mar 2009 19:19:38 +0000
From:      Bruce Cran <bruce@cran.org.uk>
To:        Dimitry Andric <dimitry@andric.com>
Cc:        Poul-Henning Kamp <phk@phk.freebsd.dk>, freebsd-current@freebsd.org, Andriy Gapon <avg@icyb.net.ua>
Subject:   Re: ata: printf on every spinup/spindown?
Message-ID:  <20090320191938.25d85caa@gluon>
In-Reply-To: <49C37B75.5060905@andric.com>
References:  <49BE7C5A.2080103@icyb.net.ua> <10611.1237233778@critter.freebsd.dk> <20090320074833.67d615e2@gluon> <49C37B75.5060905@andric.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 20 Mar 2009 12:18:13 +0100
Dimitry Andric <dimitry@andric.com> wrote:

> On 2009-03-20 08:48, Bruce Cran wrote:
> > Related to this, the ATA driver should probably have some means,
> > either automatically or via atacontrol, of setting the APM value on
> > disks; I bought a new laptop and immediately had to install
> > sysutils/ataidle in order to stop the heads loading/unloading
> > several times per minute by setting APM to 254.  Apparently it's
> > fairly common for laptop drives to have overly aggressive power
> > settings that need intervention from the OS.
> 
> I have been running with the attached patch since ages, and it still
> applies to -stable, hopefully to -current too.  I have forgotten who
> the original author is, so my apologies for not crediting it...


There's a reluctance to include code like this, I
think because it bypasses the ATA driver and talks directly to the
drive. Since the driver doesn't know what the drive's been told to do,
it can't know to adjust timers etc. to wait for the disk to spin back
up, for example.  I believe other systems like Linux and NetBSD do
bypass the driver as your patch to atacontrol does, but in FreeBSD the
driver appears to be much more sensitive to it, resulting in panics and
read timeouts because it assumes the drive is always active and ready
to respond to requests.

-- 
Bruce Cran



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090320191938.25d85caa>