]>
Commit | Line | Data |
---|---|---|
18b351a9 | 1 | #!/bin/sh |
3672489f | 2 | |
3 | # Source function library | |
18b351a9 JK |
4 | . /etc/rc.d/init.d/functions |
5 | ||
3672489f | 6 | # Get service config |
7 | [ -f /etc/sysconfig/hdparm ] && . /etc/sysconfig/hdparm | |
18b351a9 | 8 | |
3df24779 | 9 | for drive in $(ls /proc/ide 2> /dev/null); do |
441c76bb | 10 | if [ -L "/proc/ide/${drive}" ]; then |
11 | eval PARAMS=\$HDPARM_${drive} | |
382b9412 | 12 | if [ -n "${PARAMS}" ]; then |
9848b88a | 13 | show "Setting parameters for drive %s (%s)" "$drive" "$PARAMS" |
441c76bb | 14 | busy |
15 | /sbin/hdparm ${PARAMS} /dev/${drive} | |
441c76bb | 16 | ok |
17 | fi | |
0575f91b | 18 | fi |
3df24779 AM |
19 | done |
20 | ||
18b351a9 | 21 | exit 0 |