summaryrefslogtreecommitdiff
path: root/extra/lm_sensors/lm_sensors-fancontrol.patch
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2013-04-05 00:06:04 -0700
committerroot <root@rshg054.dnsready.net>2013-04-05 00:06:04 -0700
commit3c7a59bfd2b8340068df7dc196e0c9b612b9ef31 (patch)
tree355d93a0286f98e9b5ba02d7e5b840eedb38e2b1 /extra/lm_sensors/lm_sensors-fancontrol.patch
parent1b6860ed7a33a22c4202348a4f42afbb5d26be09 (diff)
Fri Apr 5 00:06:03 PDT 2013
Diffstat (limited to 'extra/lm_sensors/lm_sensors-fancontrol.patch')
-rw-r--r--extra/lm_sensors/lm_sensors-fancontrol.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/extra/lm_sensors/lm_sensors-fancontrol.patch b/extra/lm_sensors/lm_sensors-fancontrol.patch
new file mode 100644
index 000000000..e58891695
--- /dev/null
+++ b/extra/lm_sensors/lm_sensors-fancontrol.patch
@@ -0,0 +1,29 @@
+--- prog/pwm/fancontrol 2012-11-07 03:26:37.000000000 +0200
++++ prog/pwm/fancontrol 2013-03-22 18:15:00.566696011 +0200
+@@ -297,7 +297,7 @@
+ cd $DIR
+
+ # Check for configuration change
+-if [ -z "$DEVPATH" -o -z "$DEVNAME" ]
++if [ -z "$DEVPATH" ] || [ -z "$DEVNAME" ]
+ then
+ echo "Configuration is too old, please run pwmconfig again" >&2
+ exit 1
+@@ -337,7 +337,7 @@
+ # It didn't work, try pwmN_enable=1 pwmN=255
+ echo 1 > $ENABLE 2> /dev/null
+ echo $MAX > $1
+- if [ `cat $ENABLE` -eq 1 -a `cat $1` -ge 190 ]
++ if [ `cat $ENABLE` -eq 1 ] && [ `cat $1` -ge 190 ]
+ then
+ # Success
+ return 0
+@@ -469,7 +469,7 @@
+ else
+ # calculate the new value from temperature and settings
+ pwmval="(${tval}-${mint})*(${maxpwm}-${minso})/(${maxt}-${mint})+${minso}"
+- if [ $pwmpval -eq 0 -o $min_fanval -eq 0 ]
++ if [ $pwmpval -eq 0 ] || [ $min_fanval -eq 0 ]
+ then # if fan was stopped start it using a safe value
+ echo $minsa > $pwmo
+ # Sleep while still handling signals