pwmconfig: Better diagnostics in pwmdisable.

git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5022 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Jean Delvare committed 2007-11-18 15:51:26 +00:00
1 parent 9df95ebdee
commit 1a795661fb
2 files changed
+9 -2

No files matched your search

+1
View File
@@ -9,6 +9,7 @@ SVN-HEAD
Recognize VGN as a valid Sony Vaio name prefix (2.6 backport)
Program decode-dimms.pl: Fix DDR2 SDRAM module speed decoding
Update manufacturer IDs.
Program pwmconfig: Better diagnostics in pwmdisable
Program sensors: Hide spurious errors on missing f71872f voltage inputs
Program sensors-detect: Add Texas Instruments TMP401 detection
Mention the f75375s driver
+8 -2
View File
@@ -132,15 +132,21 @@ function pwmdisable()
# It didn't work, try pwmN_enable=1 pwmN=255
echo 1 > $ENABLE 2> /dev/null
if [ "`cat $ENABLE`" -ne 1 ]
then
echo "$ENABLE stuck to `cat $ENABLE`" >&2
return 1
fi
echo $MAX > $1
if [ "`cat $ENABLE`" -eq 1 -a "`cat $1`" -ge 190 ]
if [ "`cat $1`" -ge 190 ]
then
# Success
return 0
fi
# Nothing worked
echo "$ENABLE stuck to `cat $ENABLE`" >&2
echo "$1 stuck to `cat $1`" >&2
return 1
else
echo $MAX 0 > $1