You are not logged in.

#1 2010-03-30 01:35:53

quintaessentia
Member
From: Florida
Registered: 2010-03-19
Posts: 4

pwmconfig stops fans then errors out

I've done a lot of searching and I haven't been able to find anyone who's had quite the same problem as I'm having. When I run pwmconfig, I get the following:

Found the following devices:
    hwmon0/device is smsc47m1
    hwmon1/device is smsc47m192

Found the following PWM controls:
    hwmon1/device/pwm1
    hwmon1/device/pwm2

Giving the fans some time to reach full speed...

Found the following fan sensors:
    hwmon0/device/fan1_input     current speed: 0 ... skipping!
    hwmon0/device/fan2_input     current speed: 0 ... skipping!

There are no working fan censors, all readings are 0.
make sure you have a 3-wire fan connected.
You may also need to increase the fan divisors.
See doc/fan-divisors for more information.

There is a delay of 5 seconds after the "Giving the fans some time..." and during this delay my fans stop completely, I have to reboot to get them going again. I took a look at the doc/fan-divisors, which suggests putting set fanN_div X into the sensors3.conf file. I tried this and when I ran sensors -s I got the following error:

Error: File /etc/sensors3.conf, line 211: Unknown feature name
smsc47m192-i2c-0-2d: No such subfeature known

I also looked through the pwmconfig bash script file and here's the code for the part that's messing up on me:

278    echo "Giving the fans some time to reach full speed..."
279    sleep $DELAY
280    echo 'Found the following fan sensors:'
281    for i in $FAN
282    do
283            # this will return the first field if there's only one (sysfs)
284            S=`cat $i | cut -d' ' -f2`
285            if [ "$S" = "0" -o "$S" = "-1" ]
286            then
287                    echo "   $i     current speed: 0 ... skipping!"
288            else
289                    echo "   $i     current speed: $S RPM"
290                    if [ "$GOODFAN" = "" ]
291                    then
292                            GOODFAN=$i
293                            SPEEDS=$S
294                    else
295                            GOODFAN="$GOODFAN $i"
296                            SPEEDS="$SPEEDS $S"
297                    fi
298            fi
299    done
300    echo
301    
302    if [ "$GOODFAN" = "" ]
303    then
304            echo 'There are no working fan sensors, all readings are 0.'
305            echo 'Make sure you have a 3-wire fan connected.'
306            echo 'You may also need to increase the fan divisors.'
307            echo 'See doc/fan-divisors for more information.'
308            exit 1
309    fi

Link to the entire code of the above fragment: http://www.lm-sensors.org/browser/lm-se … /pwmconfig. I'm not exactly sure what the "-f2" accomplishes in the line S=`cat $i | cut -d' ' -f2`, so I don't really understand why it's assigning a "0" or "-1" to "$S". Nor can I figure why this causes my fans to stop.

If anyone might know what's going on, how I can fix it, or can just point me in the right direction I'd be grateful.

Offline

#2 2010-05-11 05:01:15

fphillips
Member
From: Austin, TX
Registered: 2009-01-24
Posts: 202

Re: pwmconfig stops fans then errors out

Did kernel 2.6.33 fix this?

http://lm-sensors.org/wiki/Configuratio … io-S4000NX
http://git.kernel.org/?p=linux/kernel/g … 281cf3d562

The hardware seems to be working fine, the driver just isn't reading fan speeds. The pwmconfig script is ok: its checking for a value of zero or -1 in fanN_input. The comment says that when there aren't two fields (columns delimited by a ' ') in the file, it returns the first field. Sysfs has only one value per file (the fan speed). It was probably procfs that had two fields, back before sysfs existed.

Offline

Board footer

Powered by FluxBB