# How to manually adjust CPU fan speed in FreeBSD 10.0 on X201



## FreeDomBSD (Jun 21, 2014)

I need some help with manually adjusting CPU fan speed in FreeBSD 10.0 on a Lenovo ThinkPad x201t (convertible tablet). I do not feel/hear much airflow and the laptop automatically shuts down when it gets hot enough. I already looked at relevant BIOS settings (there are none). Thanks!

`# sysctl hw.acpi`


```
hw.acpi.supported_sleep_state: S3 S4 S5
hw.acpi.power_button_state: S5
hw.acpi.sleep_button_state: S3
hw.acpi.lid_switch_state: NONE
hw.acpi.standby_state: NONE
hw.acpi.suspend_state: S3
hw.acpi.sleep_delay: 1
hw.acpi.s4bios: 0
hw.acpi.verbose: 0
hw.acpi.disable_on_reboot: 0
hw.acpi.handle_reboot: 0
hw.acpi.reset_video: 0
hw.acpi.cpu.cx_lowest: C1
hw.acpi.thermal.min_runtime: 0
hw.acpi.thermal.polling_rate: 10
hw.acpi.thermal.user_override: 0
hw.acpi.thermal.tz0.temperature: 69.0C
hw.acpi.thermal.tz0.active: -1
hw.acpi.thermal.tz0.passive_cooling: 1
hw.acpi.thermal.tz0.thermal_flags: 0
hw.acpi.thermal.tz0._PSV: 91.5C
hw.acpi.thermal.tz0._HOT: -1
hw.acpi.thermal.tz0._CRT: 100.0C
hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
hw.acpi.thermal.tz0._TC1: 5
hw.acpi.thermal.tz0._TC2: 4
hw.acpi.thermal.tz0._TSP: 600
hw.acpi.battery.life: 99
hw.acpi.battery.time: -1
hw.acpi.battery.state: 2
hw.acpi.battery.units: 1
hw.acpi.battery.info_expire: 5
hw.acpi.acline: 1
```

*N*othing happens when I run `sysctl -a | grep fan`*.*


----------



## ondra_knezour (Jun 21, 2014)

*Re: Manually adjust CPU fan speed in FreeBSD 10.0*

Isn't there an ACPI module for your laptop, which may help?

Some laptops have independent thermal control built-in in their BIOS, did you try to look there? Also BIOS upgrade/downgrade may help, I have personally horrific experience with the hp machines in this area (couple of dozens of them).

And finally - you will probably get much better response when you specify which laptop type is in the question.


----------



## FreeDomBSD (Jun 21, 2014)

*Re: Manually adjust CPU fan speed in FreeBSD 10.0*

How silly of me! I was in a rush and forgot to mention that I have already dug through the BIOS (no fan settings) and the model of the laptop. *Edited*


----------



## ondra_knezour (Jun 21, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on*

Try to load acpi_ibm() module with the `kldload acpi_ibm.ko` command, then look for 'dev.acpi_ibm.0.fan*' sysctls.

However it looks like common problem, which may be a result of a poor design or manufacturing (I found one response where somebody states, that there was too little thermal paste on one chip and no paste at all on another, after adding paste was problem solved.)

http://forums.lenovo.com/t5/X-Series-Th ... d-p/227471
http://www.thinkwiki.org/wiki/Problem_w ... untu_11.10
https://bugzilla.redhat.com/show_bug.cgi?id=675433


----------



## FreeDomBSD (Jun 22, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

This is exactly what I needed. I switched the fan speeds to manual and then raised the RPMs. Alas the RPMs were already maxed out on automatic and the real problem is that these hot-running i7s burn off their thermal compound after a while.

Thank you, ondra_knezour, my friend from Prague!


----------



## FreeDomBSD (Jun 26, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

So I now realize that the fan speed is much slower when I use FreeBSD on the x200t then when I use Windows. I am afraid that the fan just does not spin high enough. I have no idea what to do!


----------



## FreeDomBSD (Jun 30, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

Any advice? I need to bring the fan speed to ~6500rpm. Now it maxes out at 4600rpm.


----------



## Crivens (Jul 1, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

Keep an eye on the temperature of the CPU when running Windows, compare that to the value from FreeBSD. As long as the temperature is around the same level, there is no need for additional cooling.


----------



## FreeDomBSD (Jul 1, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

Thanks for the reply! The temperature are much hotter and the fan speed is much lower in FreeBSD. There is also no 'max' setting for the fan as described in this bug report: https://bugzilla.redhat.com/show_bug.cgi?id=675433#c1

Basically, in Windows when the laptop gets hot the fan kicks into high gear. This behavior is not observed with FreeBSD: the fan runs on low, very low, no matter how hot the system gets.


----------



## FreeDomBSD (Jul 7, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

Does anyone have any hints for me?


----------



## User23 (Jul 10, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

As long as you can't control the fan speed, just control the CPU frequency.  :\


----------



## Crivens (Jul 10, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on*

It might be that the ACPI is not up to any good on the machine. Maybe you need to debug in that area, it might be as simple as lying to ACPI about the OS running.  Other than that, i have not really an idea what you could do there. Also, if I remember correctly, there was an acpi_thermal module. Is that so and would it help?


----------



## BrockyL (Jul 10, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on *

essentially this is not necessary especially if you have an off the shelf mixed media io controller, whoch you eont see or hear about but will keep hardware flowing bits into memory just  fine if the hw.acpi.thermal.useroverride and hw.acpi.thermal.passive_cooling sysctl's are positive, which throttles  kernel function response to hardware interrupt, I have an old intel motherboard and I keep it under 60.0C in my sauna of a home, otherwise it will spike at 80C. without adverse performance issues because remember theres a read/write ahead buffering in userland, kernel, firmware, hardware and on top of buffering, mixed media io  hardware priority.


----------



## sulman (Aug 22, 2014)

*Re: How to manually adjust CPU fan speed in FreeBSD 10.0 on*

I have a work_ing_ X201 with Gentoo Linux on it, and I had to use a third-party application called thinkfan, otherwise the laptop regularly overheated during compilation as fan RPM usually topped out around 4k; Thinkfan, like many fan control applications maps a relationship between temperature reading and fan setting. 

I'm not sure what the answer is on FreeBSD unless somebody develops something similar. I have read it is also a problem on Windows - this laptop is poorly designed in terms of cooling. A shame as it is otherwise pretty nice.


----------

