Subject: Re: atactl(8) somehow defective on macppc?
To: Nathan J. Williams <nathanw@wasabisystems.com>
From: Timo Schoeler <timo.schoeler@riscworks.net>
List: port-macppc
Date: 10/10/2005 18:15:14
thus Nathan J. Williams spake:
> Timo Schoeler <timo.schoeler@riscworks.net> writes:
> 
> 
>>before using send-pr i'd like to make sure that this doesn't happen
>>only to me...
>>
>>as soon as i try to get insight into what S.M.A.R.T. logs on an ATA HD
>>i get kicked by atactl(8):
>>
>>yak3: {141} atactl wd0 identify
>>Model: WDC WD400EB-00CPF0, Rev: 06.04G06, Serial #: WD-WCAAT4307646
>>Device type: ATA, fixed
>>Device capabilities:
>>         DMA
>>         LBA
>>         ATA standby timer values
>>         IORDY operation
>>         IORDY disabling
>>Device supports following standards:
>>ATA-1 ATA-2 ATA-3 ATA-4 ATA-5
>>Command set support:
>>         READ BUFFER command
>>         WRITE BUFFER command
>>         Host Protected Area feature set
>>         look-ahead
>>         write cache
>>         Power Management feature set
>>         Security Mode feature set
>>         SMART feature set
>>         Device Configuration Overlay feature set
>>         Automatic Acoustic Management feature set
>>         SET MAX security extension
>>         DOWNLOAD MICROCODE command
>>Command sets/features enabled:
>>         look-ahead
>>         write cache
>>         SMART feature set
> 
> 
> You're using an old atactl(8) binary, or one built from old
> sources.

ah, yes. sorry, that's true.

unfortunately, netbsd3-beta doesn't build for me (atactl is v 1.39 
2005/06/27 01:00:05 in my src directory) because it crashes in ofwboot:

http://www.netbsd.org/cgi-bin/query-pr-single.pl?number=31470

so i have a slightly outdated userland :(

> The current version (as of rev 1.33, 2004-10-08, and present
> on the netbsd-3 branch) has the enabled/disabled status combined in
> the output:
> 
> Command set support:
>         NOP command (enabled)
>         READ BUFFER command (enabled)
>         WRITE BUFFER command (enabled)
>         Host Protected Area feature set (enabled)
>         look-ahead (enabled)
>         write cache (enabled)
>         Power Management feature set (enabled)
>         Security Mode feature set (disabled)
>         SMART feature set (enabled)
>         DOWNLOAD MICROCODE command (enabled)
> 
> but more importantly, has this fix:
> 
>   revision 1.35
>   date: 2004/11/17 15:40:50;  author: fvdl;  state: Exp;  lines: +14 -14
>   * don't swap the WDSMART_CYL value, it isn't needed
>   * swap the 16- and 32 bit fields of the SMART structures (where used)
>   
>   Makes SMART commands work on big-endian systems.
> 
> 
> With that fix, atactl(8) reads SMART info successfully on my G4 (and
> I've used it on a powerbook and my ibook as well):
> 
> id value thresh crit collect reliability description                    raw
>   1 100   60     yes online  positive    Raw read error rate            0
>   2 138   50     yes offline positive    Throughput performance         3745
>   3 136   24     yes online  positive    Spin-up time                   38685573608
>   4 100    0     no  online  positive    Start/stop count               2241
>   5 100    5     yes online  positive    Reallocated sector count       0
>   7 100   67     yes online  positive    Seek error rate                0
>   8 105   20     yes offline positive    Seek time performance          57
>   9  94    0     no  online  positive    Power-on hours count           47197
>  10 100   60     yes online  positive    Spin retry count               0
>  12 100    0     no  online  positive    Device power cycle count       163
> 196 100    0     no  online  positive    Reallocated event count        0
> 197 100    0     no  online  positive    Current pending sector         0
> 198 100    0     no  offline positive    Offline uncorrectable          0
> 199 200    0     no  online  positive    Ultra DMA CRC error count      0
> 
> 
>         - Nathan

thanks,

timo