All right, please find a revised patch attached that does not stop the CPU fan.
Turns out that the original patch malfunctioned on both v1.1 and v2 of the board if the it87 driver was not loaded. That driver fixed the settings, which added to my confusion. It also explains why it seemed to work for me at first, but then did not when rebooting (I was booting a different filesystem that did not load the it87 module on startup).
Anyway, I'd be grateful for some testing of the attached. It does the right thing on v1.1 and v2 of the board based on my testing. It does not set the diode zero adjust temperature right yet for v2 of the board (it should be 0xfe instead of 0xec). That could be done by adding a detection for the revision of the IT8716F chip (v2 seems to have rev3, v1.1 has rev0), but I don't have time to add that right now. It's not that important I think - but if someone wants to contribute that change, please feel free. There are a few other registers that should be slightly different between v1.1 and v2 but nothing very crucial it seems.
Thanks, Ward.
Hi Ward,
Strange, but here it worked...
It seems that your board(s) use (also?) FAN3. Mine uses only FAN1. Indeed the original bios also turned on auto control of FAN3 (by the same sensor), but since my CPU fan isn't connected to that one, I didn't include it (bit selfish, I agree). The 0-degree threshold for the diode-type sensors is set to 0xe5 by my bios (I don't know where you get the 0xfe from...), but the reading is a bit off compared to the K8-temp, so maybe the 0xec might be better (not much difference anyway). This is only necessary sensor 2 (idx 0x59), as that is the only diode sensor. The value 0x60 for index 0x5c is not correct according to the datasheet (unused bits should be 0, not 1), but indeed my bios also sets 0x60. Again the settings for index 0x70..0x75 are for FAN3, which I don't use (the selfish principle). You also set the FAN2 control to be controlled by temp3, but you don't set the parameters 0x68..0x6d. Should set 0x16 to some value 0~127. I think for the 0x14 index the value 0x87 was a mistake from my side, 0xd7 uses a more sensible PWM frequency (obviously my fan didn't care...). The voltage limit settings 0x31..0x3f have nothing to do with FAN control, should be left out. Shouldn't index 0x13 be set to 0x75 for both FAN1 and FAN3 smartguardian mode?
I'll give it a try asap (probably after the weekend).
I think gigabyte provides different bios for V1 and V2 boards, shouldn't we do the same? (by means of an option, like setting HAVE_FANCTL to 1 for v1 and to 2 for v2)
Ronald.
On Mon, 2008-03-03 at 16:51 -0500, Ward Vandewege wrote:
All right, please find a revised patch attached that does not stop the CPU fan.
Turns out that the original patch malfunctioned on both v1.1 and v2 of the board if the it87 driver was not loaded. That driver fixed the settings, which added to my confusion. It also explains why it seemed to work for me at first, but then did not when rebooting (I was booting a different filesystem that did not load the it87 module on startup).
Anyway, I'd be grateful for some testing of the attached. It does the right thing on v1.1 and v2 of the board based on my testing. It does not set the diode zero adjust temperature right yet for v2 of the board (it should be 0xfe instead of 0xec). That could be done by adding a detection for the revision of the IT8716F chip (v2 seems to have rev3, v1.1 has rev0), but I don't have time to add that right now. It's not that important I think - but if someone wants to contribute that change, please feel free. There are a few other registers that should be slightly different between v1.1 and v2 but nothing very crucial it seems.
Thanks, Ward.
On Wed, Mar 05, 2008 at 12:01:27AM +0100, Ronald Hoogenboom wrote:
I think gigabyte provides different bios for V1 and V2 boards, shouldn't we do the same?
This is something I have thought about on and off.
If there are hardware differences on the board revisions that we are unable to reliably determine in software I think they should be separate ports..
(by means of an option, like setting HAVE_FANCTL to 1 for v1 and to 2 for v2)
..rather than having options.
This also fits better with how v3 works, where I think it would be more intuitive to have several board revs at the same level in the Kconfig menus rather than having a submenu for boards where multiple revisions are supported.
//Peter
//Peter
Hi Ward,
On Mon, 2008-03-03 at 16:51 -0500, Ward Vandewege wrote:
All right, please find a revised patch attached that does not stop the CPU fan.
I've tested your revised patch and it works on my V2 board too. I've removed the stuff (alarm limits, for which the interrupts are disabled anyway) that have nothing to do with fan regulation and it works still (with and without the it87 module). It turns out that the zero degree voltage setting 0xec is actually a lot better than the 0xe5 my shipped bios put in. The 0x87 for the index 0x14 was just my mistake, 0xb7 is the correct value. I've changed the index 0x13 value to 0x75 to make both FAN1 and 3 'smart'-regulated. I hope that is correct for your boards too, if it works fine, we don't need a different setting for V1 and V2 boards after all. Please find the revised-revised patch attached.
Hi Ronald,
On Mon, Mar 10, 2008 at 10:16:40PM +0100, Ronald Hoogenboom wrote:
On Mon, 2008-03-03 at 16:51 -0500, Ward Vandewege wrote:
All right, please find a revised patch attached that does not stop the CPU fan.
I've tested your revised patch and it works on my V2 board too. I've removed the stuff (alarm limits, for which the interrupts are disabled anyway) that have nothing to do with fan regulation
OK, that's fine.
and it works still (with and without the it87 module). It turns out that the zero degree voltage setting 0xec is actually a lot better than the 0xe5 my shipped bios put in. The 0x87 for the index 0x14 was just my mistake, 0xb7 is the correct value. I've changed the index 0x13 value to 0x75 to make both FAN1 and 3 'smart'-regulated.
Actually I'd like to do the same for FAN1,2 and 3. I think putting all three fans under automatic control is the best fail-safe default. So maybe set 0x13 to 0x77 instead?
Should we also configure fan2 and 3 with all the pwm and start/stop values like we do for fan1?
I hope that is correct for your boards too, if it works fine, we don't need a different setting for V1 and V2 boards after all. Please find the revised-revised patch attached.
:) Yeah, it works fine on v1 and v2 for me. I think we can commit once we bring the settings for fan2 and 3 in line with those for fan1, unless you have an argument against doing that?
Thanks, Ward.
On Mon, 2008-03-10 at 18:02 -0400, Ward Vandewege wrote:
:) Yeah, it works fine on v1 and v2 for me. I think we can commit once we bring the settings for fan2 and 3 in line with those for fan1, unless you have an argument against doing that?
The only arguments I can think of are: - prop. bios doesn't do it for FAN2 - if there is no connector that could be used for CPU related fan on the mainboard that wires to the FAN2 output, then why should we?
Are you referring to the difference 0x27/0x20 for the indexes 0x63/0x73? Maybe the intention is to have a bigger fan on FAN3 that doesn't rotate at all below 30% pw, while the smaller fan on FAN1 already rotates at 25% pw. Who knows...
Ronald.
On Tue, Mar 11, 2008 at 12:20:34AM +0100, Ronald Hoogenboom wrote:
On Mon, 2008-03-10 at 18:02 -0400, Ward Vandewege wrote:
:) Yeah, it works fine on v1 and v2 for me. I think we can commit once we bring the settings for fan2 and 3 in line with those for fan1, unless you have an argument against doing that?
The only arguments I can think of are:
- prop. bios doesn't do it for FAN2
That's an argument I don't care about :) The proprietary bios in this particular case is ok, but I've seen some other ones that do things that are really not optimal.
If we can do it better/make the default safer, why would we not?
- if there is no connector that could be used for CPU related fan on the
mainboard that wires to the FAN2 output, then why should we?
There are 3 fan connectors on the MB. Fan1 is the one next to the CPU, and that's the one labelled as 'cpu fan' to which I've connected my cpu fan. The other two are elsewhere on the board.
The superio cpu sensor seems to be sensor 3.
Are you referring to the difference 0x27/0x20 for the indexes 0x63/0x73? Maybe the intention is to have a bigger fan on FAN3 that doesn't rotate at all below 30% pw, while the smaller fan on FAN1 already rotates at 25% pw. Who knows...
Yeah, that could be.
Do we know if the other 2 sensors (sensor 1 and 2) actually produce sane values? I was not sure about that, which is why I proposed setting fan 2 and 3 to automatic, and hooking them up to the cpu sensor.
Thanks, Ward.