Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 185341 - app-laptop/pbbuttonsd-0.8.1 has unsuitable hdparm defaults
Summary: app-laptop/pbbuttonsd-0.8.1 has unsuitable hdparm defaults
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: PPC Porters
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-14 19:37 UTC by Ulrich Müller
Modified: 2007-07-19 01:39 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ulrich Müller gentoo-dev 2007-07-14 19:37:21 UTC
app-laptop/pbbuttonsd-0.8.1 installs a file /etc/power/pmcs-config containing the following default initialisation parameters:

   performance_HDOptions="-p"
   custom_HDOptions="-p"
   powersave_HDOptions="-p"

These are used by /etc/power/scripts.d/hdsetup and passed as argument to hdparm. The hdparm man page says for option "-p":

"Attempt to reprogram the IDE interface chipset for the specified PIO mode, or attempt to auto-tune for the 'best' PIO mode supported by the drive. This feature is supported in the kernel for only a few 'known' chipsets, and even then the support is iffy at best. Some IDE chipsets are unable to alter the PIO mode for a single drive, in which case this flag may cause the PIO mode for *both* drives to be set. Many IDE chipsets support either fewer or more than the standard six (0 to 5) PIO modes, so the exact speed setting that is actually  implemented will vary by chipset/driver sophistication. *Use*with*extreme*caution!* This feature includes zero protection for the unwary, and an  unsuccessful outcome may result in *severe*filesystem*corruption!*"

For the Intel PIIX/ICH driver in kernel 2.6.22, the effect of "hdparm -p" is that DMA for the device is disabled.

In short, "-p" is an unsuitable and dangerous default and should be replaced by the empty string. Users who want to tune their HD performance can still change the pcms-config file or specify their options in /etc/conf.d/hdparm.
Comment 1 Joe Jezak (RETIRED) gentoo-dev 2007-07-19 01:39:12 UTC
Okay, I reported this upstream and added a patch to portage.  Thanks.