On 04/15/2013 08:20 PM, Michael wrote:
I'm not very familiar with envsys but is it possible to make it control fan speed automatically depending on the current temperature ? Or is it better to control fan speed in the kernel space, like Linux or FreeBSD kernels do it. I would appreciate any pointers here.I don't think there's a generic mechanism in envsys to do that, since most of the supported sensors / fan controllers do this automatically. There is some prior art though, I think sparc64's tda driver ( for the Sun Blade 1000 / 2000, see arch/sparc64/dev/tda.c ) does this by software as well.
I already implemented it with envsys and powerd. I's very simple actually, if a critical value is exceeded, envsys sends an event to powerd and powerd runs my script which increases the speed of all fans. And if the CPU temperature drops below the critical value then my script decreases the speed of all fans. And the fans are really quiet now and let my G5 run for a whole day without problems, compiled a kernel and distribution ot it with no lockups. But i had some lock panics :( Unfortunately, i couldn't get a ddb trace. But i could reproduce the problem with iozone from pkgsrc today. It panics in mutex_vector_enter with the message 'Mutex error: mutex_vector_enter: locking against myself' Trying to debug it currently. regards