[ltp] hdparm and in R40

Benjamí Villoslada linux-thinkpad@linux-thinkpad.org
Wed, 6 Oct 2004 21:20:33 +0200


When Linux starts and when change the power condition (battery,
plugged) I see this error in /var/log/warn (and /var/log/messages and
dmesg)

hda: task_no_data_intr: status=0x51 { DriveReady SeekComplete Error }
hda: task_no_data_intr: error=0x04 { DriveStatusError }

Seems that is the hdparm command that powersaved executes.  Because
hdparm is dangerous... someone knows the correct hdparm parameters for
this laptop?  More details:

- Thinkpad R40 2681

- SuSE 9.1

- ACPI

codol:~ # uname -a
Linux codol 2.6.5-7.108-default #1 Wed Aug 25 13:34:40 UTC 2004 i686
i686 i386 GNU/Linux

---------------------------------

codol:~ # hdparm -I /dev/hda

/dev/hda:

ATA device, with non-removable media
        Model Number:       HITACHI_DK23EA-40B
        Serial Number:      E55525
        Firmware Revision:  00K3A0B6
Standards:
        Used: ATA/ATAPI-5 T13 1321D revision 3
        Supported: 5 4 3 2 & some of 6
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:   16514064
        LBA    user addressable sectors:   78140160
        device size with M = 1024*1024:       38154 MBytes
        device size with M = 1000*1000:       40007 MBytes (40 GB)
Capabilities:
        LBA, IORDY(cannot be disabled)
        bytes avail on r/w long: 4      Queue depth: 1
        Standby timer values: spec'd by Vendor, no device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 16
        Advanced power management level: 10 (0xa)
        DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 *udma5
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4
             Cycle time: no flow control=240ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    NOP cmd
           *    READ BUFFER cmd
           *    WRITE BUFFER cmd
           *    Host Protected Area feature set
           *    Look-ahead
           *    Write cache
           *    Power Management feature set
                Security Mode feature set
           *    SMART feature set
           *    Mandatory FLUSH CACHE command
           *    Device Configuration Overlay feature set
                SET MAX security extension
                Address Offset Reserved Area Boot
                Advanced Power Management feature set
           *    SMART self-test
           *    SMART error logging
Security:
        Master password revision code = 65534
                supported
        not     enabled
        not     locked
                frozen
        not     expired: security count
                supported: enhanced erase
        40min for SECURITY ERASE UNIT. 40min for ENHANCED SECURITY ERASE UNIT.
HW reset results:
        CBLID- above Vih
        Device num = 0 determined by the jumper
Checksum: correct

---------------------------------

benjami@codol:~> cat /etc/sysconfig/powersave/hdparm
# determines, how the powersave daemon will adjust your Harddisk in the
# different profiles. If you alter something here, you probably already
# know that you are doing this on your own risk. You should be at least
# familiar with hdparm (8) and the settings in /proc/sys/vm.
# YOU WILL PROBABLY LOSE DATA IF YOU ENTER WRONG VALUES HERE.
# You have been warned.

# shall we remount journaled filesystems with appropriate commit interval?
# yes/no
HD_DO_REMOUNTS="yes"
#
# remount with option noatime? Needed for reiserfs now, will be fixed later.
HD_NOATIME="no"
#
# age time, in seconds. Warning: You will lose data if your machine crashes
# or your battery runs flat, sice data will eventually only be committed to
# disk after this time!
HD_MAX_AGE=600
#
# Allowed dirty ratio, in pct.
HD_DIRTY_RATIO=75
#
#
# hdparm arguments for POWERSAVE_DISK_ACOUSTIC
# performance
HD_ACOUSTIC_PERF="-M 254"
# low
HD_ACOUSTIC_LOW="-M 128"
# quiet
HD_ACOUSTIC_QUIET="-M 128"
#
# arguments for POWERSAVE_DISK_STANDBY_MODE
# performance, normally there is no need to change this!
HD_STBY_PERF="-B 255 -S 0"
# powersave, APM 10, Standby: 30sec
HD_STBY_SAVE="-B 10 -S 6"
# aggressiv_powersave, APM: 1, Standby: 10sec
HD_STBY_AGGR="-B 1 -S 2"
#
# if you want to do something like listening to mp3 on battery, you might want
# to increase filesystem readahead to 16MB on battery, so that the whole file
# is sucked in at once and set it back to 128k on ac.
# this would be your settings for this:
# HD_STBY_PERF="-B 255 -S 0 -a 256"
# HD_STBY_SAVE="-B 10  -S 6 -a 32768"
# HD_STBY_AGGR="-B 1   -S 2 -a 32768"

---------------------------------

When the system starts, the error in /var/log/messages:

Oct  6 20:49:09 codol kernel: ACPI: AC Adapter [AC] (off-line)
Oct  6 20:49:09 codol kernel: ACPI: Battery Slot [BAT0] (battery present)
Oct  6 20:49:09 codol kernel: ACPI: Power Button (FF) [PWRF]
Oct  6 20:49:09 codol kernel: ACPI: Lid Switch [LID]
Oct  6 20:49:09 codol kernel: ACPI: Sleep Button (CM) [SLPB]
Oct  6 20:49:09 codol kernel: ACPI: Processor [CPU] (supports C1 C2
C3, 8 throttling states)
Oct  6 20:49:09 codol kernel: ACPI: Thermal Zone [THM0] (40 C)
Oct  6 20:49:09 codol rcpowersaved: enter 'speedstep-ich' into
POWERSAVE_CPUFREQD_MODULE in /etc/sysconfig/powersave/common.
Oct  6 20:49:09 codol rcpowersaved: this will speed up starting
powersaved and avoid unnecessary warnings in syslog.
Oct  6 20:49:10 codol [powersaved][3808]: resmgr: server response code 200
Oct  6 20:49:12 codol kernel: hda: task_no_data_intr: status=0x51 {
DriveReady SeekComplete Error }


Thanks :)

-- 
Benjamí
http://weblog.bitassa.net



.