# Trusting hardware instead of ACPI to control my fan = safer?

## icmp_request

Hello! So, I'm about to install lm_sensors in my laptop to enable... "sensoring"? Anyway, when I've gone to the Gentoo Wiki about this set of tools ( http://en.gentoo-wiki.com/wiki/Lm_sensors ) I've read the following scary message:

 *Quote:*   

> Be careful when activating sensors, like i2c, in the kernel. On some systems this might stop the fans from working and can disable the ACPI system-overheat shutdown as well. This will cause your computer to freeze at best, or may even cause serious hardware damage.
> 
>     * See the lm_sensors website for a problematic hardware list.
> 
>     * Using lm_sensors on IBM ThinkPads is especially not advised. 

 

Well, when I go through my 2.6.34-gentoo-r1 kernel options, I see the following option:

Power management and ACPI options -> ACPI (Advanced Configuration and Power Interface) Support -> Fan

If lm_sensors and acpi can stop my fan from working, does disabling this sole option as built-in or module, but still enabling other ACPI options and sensors, prevents me from the problem described?

So Linux has no control over my fan but maybe my own hardware does, preventing any fan from stop working when it shouldn't stop?

Thanks!

EDIT: In simpler words, I DON'T want Linux, acpi, lm_sensors or any application using sensors to be able to turn off my fan and cause possible hardware damages. Does disabling acpi fan module but still enabling acpi and sensoring does the trick?

----------

## depontius

Not to answer your question, (I'm curious to see the answers, too.) but I hope you don't have a ThinkPad.  There is a rather fundamental incompatibility between ThinkPads and lm_sensors - as in the latter will brick the former.  I don't know if it's all ThinkPads or just early ones, but I've never seen a post saying that ANY ThinkPads are OK for lm_sensors, and many posts warning about it.  OTOH, it's possible to get the same information from ThinkPads with ACPI.  It's undocumented, but there are people poking about with cans of chiller spraying components and seeing which readings change.

I also don't believe that simply enabling the sensor stuff will start turning off the fan.  I believe that has to be scripted in somewhere under "/etc/acpi/events" and by default the fan just runs under hardware control.  Not sure about that, so I wouldn't rely on it without further digging.  It's also possible that some other package you install will put something in that directory that handles (or mishandles) the fan.

----------

## icmp_request

Yes depontius, I'm really much more worried about the apps that uses lm_sensors, but I cannot say that I'm not even a little worried about lm_sensors itself.

I don't have a Thinkpad, but lm_sensors incompatibility may not limit only to Thinkpads.

My main concern is not lm_sensors not work, but cause hardware damage.

MAYBE if disabling the acpi fan control module on kernel proves to be safe and not allow acpi, lm_sensors and other stuff that uses hardware monitoring/scaling to control the fans, it could be also safe to edit the wiki and put a note below the warning, saying that if you do that you should not worry about your hardware being damaged by lm_sensors, because the worst thing that could happen would be lm_sensors/acpi not working.

Edit: Something like "what can really cause damage is allowing fan control, so build this module at your own risk!" - But then it needs to be proof that only by disabling the specific module under ACPI will prevent any Software/OS control over the fans.

I've already contacted the lm_sensors mailing list, no answers until now, but will keep this thread updated if they answer anything.

----------

## depontius

Now that I think of it, my main deskside machine has fan control, but I've turned it off in BIOS, and I run lm_sensors on that machine.  Though it's more of a concern on a laptop, because the fan is always under some sort of control.  But since I have a ThinkPad, I can't even test this one for you.

----------

## icmp_request

What implies about turning it off on BIOS? Means that:

- Only OS will not be able to control fans.

Or:

- Hardware will also not be able, resulting in fan operating always in max. speed?

----------

## depontius

I'm going to go out on a limb here and make an ugly guess:

It's ALWAYS software control.  Ever since the Pentium, (or so) there has been this thing called SMM (System Management Mode)

http://www.laynetworks.com/architecture%20of%20Pentium%20Microprocessor.htm

Basically it's a complete context switch, and the processor runs off and does something else for a while, then comes back and does what it was doing before.  I'm going to guess that when the fan is under "hardware control" it's really controlled by the processor in SMM.  I'll further guess that if you can control the fan with your software, you're better off.  I can't imagine that SMM is a lighter weight context switch than the OS can manage for multitasking - from a quick read it looks rather brutish, to me.

I believe that in turning off "Q-Fan" in my BIOS, I'm doing neither - I'm just running it full-out all the time.

----------

## depontius

New development...

The regular deskside machine croaked this past weekend, so I've installed the laptop there temporarily.

My wife likes the relative quiet.

I think I'm going to have to learn about "Q-Fan" as I repair the old machine.

----------

