VCool - cool your Athlon/Duron during idle
Hello Alan,
Have you read something about this Athlon/Duron cooling problem? Can this code included into your (and/or the official) tree? Maybe it is needed for the AMD 750/760/760MP/760MPX, too?
http://www.naggelgames.de/vcool/VCool_de.html
Regards,
Dieter
Quoted 3 lines
Have you read something about this Athlon/Duron cooling problem? Can this code included into your (and/or the official) tree? Maybe it is needed for the AMD 750/760/760MP/760MPX, too?
Well my German isnt that good, but it appears to be just another variant on CPU idling. We do hlt or APM already, and APM should be doing other work if appropriate.
Alan
Am Sonntag, 26. August 2001 21:24 schrieb Alan Cox:
Quoted 7 lines
Quoted 3 lines
Have you read something about this Athlon/Duron cooling problem? Can this code included into your (and/or the official) tree? Maybe it is needed for the AMD 750/760/760MP/760MPX, too?
Well my German isnt that good, but it appears to be just another variant on CPU idling. We do hlt or APM already, and APM should be doing other work if appropriate.
OK, sorry. There is an English version, already...;-)
http://www.naggelgames.de/vcool/
The site deals with the Athlon/Duron and chipset (VIA) short comings and current bugs (power saving related). I think it is one of the best (put all info together and provide a solution) for the AMD Athlon/Duron hardware throttling.
[-]
VCool 1.6
This little utility will cool your Athlon/Duron processor on Via KT133 or KX133(A) (VT8363 or VT8371/VT82C686x) chipsets during idle
Features
Controls the "Northbridge Bus Disconnect Bit" to lower your CPUs power level during idle
An idle loop that puts your CPU into STPGNT state if your OS won't
Displays the current CPU temperature in your system tray (optional)
Optional hardware throttling of the CPU when it gets too hot (50%, 10%, shutdown)
Lightweight: 30K
Requirements
Chipset with a VT8371 or VT8363 Northbridge and a VT82C686x Southbridge (VIA KT133x or KX133) - limited support for AMD 761
A Win32 OS (Windows 98 or better - no that does not include LINUX *g*)
For Windows 2000 and NT you'll need the "GiveIO" driver
How it works
The Athlon (or Duron) enters a lower power state only when its system bus is disconnected. However the (VIA-)Northbridge will only disconnect the bus if its "Bus Disconnect Enable" bit is set and the CPU is in STPGNT state.
VCool allows you to enable this bit so your CPU can relax when there's
nothing to do.
Setting this bit might not be enough on some systems as the idle loop provided with the OS will not put the CPU into the STPGNT state recognized by the Northbridge.
For those cases VCool includes an internal idle loop that forces the CPU
into the STPGNT mode required by the Northbridge to initiate a bus disconnect.
If you want to read more about how this works follow this link.
Note that the system monitor will report 100% utilization when the idle loop is active.
That's because it takes away all idle time from the OS idle loop and the OS
calculates the utilization like:
Utilization = 100 % - %age of time spent in OS idle loop.
Also note that disconnecting the system bus to save power might interfere with "realtime" applications like TV or sound capturing - causing dropouts or other oddities.
What's new in VCool 1.6
The temperature readout on 686 chips was a bit low at high temperatures - now VCool uses a new formula based on inofficial data. The "TempDiv" and "TempSub" registry keys have been removed.
Added and Apply button in the options dialog
The status of the SBMus is now restored after readout to solve problems with ASUS probe. There's also a busy wait option to prevent asus probe from interfering with VCools reading - however so far this seems to work only on W9x and ME as the preemptive scheduling of W2K and NT requires a driver to achieve this - maybe in a later version *g*.
The status of the cool bit and the idle loop are now indicated by small dots on the lower left and right of the icon.
<shift>+LClick (<crtl>+LClick) on the icon toggles the Cool bit (idle loop)
The idle loop is turned off now when the temperature drops below T50 (if it was off before T50 was exceeded).
There's now a custom shutdown option that will execute a user definable program when Tshutdown is exceeded.
[-]
Source is available (even for Linux).
-Dieter
Quoted 1 line · Alan Cox
Well my German isnt that good,
the page is in english (at least the one you get while clicking on linux, which is german and english alike, and gthe source code is rather international ;)
Quoted 2 lines
but it appears to be just another variant
on CPU idling.
The linux version only fiddles with a single bit in the northbridge that is claimed to be necessary so the cpu goes into the "real" idle mode. It also warns that some streaming applications might react to this with frame drops or similar.
So :/
Signature · 7 lines
-----==- |
----==-- _ |
---==---(_)__ __ ____ __ Marc Lehmann +--
--==---/ / _ \/ // /\ \/ / [email protected] |e|
-=====/_/_//_/\_,_/ /_/\_\ XX11-RIPE --+
The choice of a GNU generation |
|Quoted 2 lines · Dieter Nützel
Have you read something about this Athlon/Duron cooling problem? Can this code included into your (and/or the official) tree?
I haven't yet measured if this really saves a significant amount of power, but I made a kernel patch closely based on the vcool patch from http://www.naggelgames.de/vcool/
This patch is extremely experimental, but it didn't crash my machine, yet ;-) Some things could probably be more elegant.
Feel free to comment or use this patch as you like. It does only use stpclk if you boot with idle=stpclk
Jan
arch/i386/kernel/pci-i386.h +3 -0
@@ -70,3 +70,6 @@void pcibios_irq_init (void );void pcibios_fixup_irqs (void );void pcibios_enable_irq (struct pci_dev *dev); + +extern int use_stpclk; +void idle_setup_stpclk (void );
arch/i386/kernel/pci-pc.c +2 -0
@@ -1053,6 +1053,8 @@if ((pci_probe &PCI_BIOS_SORT ) && !(pci_probe &PCI_NO_SORT ))pcibios_sort ();#endif +if (use_stpclk) +idle_setup_stpclk (); }char *__init pcibios_setup (char *str)
arch/i386/kernel/process.c +60 -0
93 lines not on this page · raw message
Quoted 7 lines · Marc A. Lehmann
Quoted 1 line · Alan Cox
Well my German isnt that good,
the page is in english (at least the one you get while clicking on linux, which is german and english alike, and gthe source code is rather international ;)
Quoted 7 lines
Quoted 2 lines
but it appears to be just another variant
on CPU idling.The linux version only fiddles with a single bit in the northbridge that is claimed to be necessary so the cpu goes into the "real" idle mode. It also warns that some streaming applications might react to this with frame drops or similar.
According to c't 18/2001 p.36, the real power saving in halt and STPCLK is only in effect when the CPU disconnects from the FSB. In the VIA north bridges there is one bit (bit 7 at offset 0x52) which controls whether the north bridge performs the disconnect protocol. For various reasons, this is usually disabled by the BIOS:
1. Lower quality power supplies and motherboard voltage regulators may not be able to deal with the large and fast current changes.
2. Disconnect costs 2% - 3% on common benchmarks. Incidentally, this is also the difference between the fastest and slowest Athlon motherboards. Disconnect doesn't sell, benchmarks do.
3. The internal clock generator of the CPU may lose sync or something on reconnect. (erratum #11, can be worked around by software)
4. In rare cases, Athlons with non-integer frequency multipliers (e.g. 7.5) may fail to reconnect altogether. (erratum #14, work around:
don't sleep in C1 or C2 with disconnect)
Errata as quoted from the article, referring to "AMD Athlon Processor Model 4 Revision Guide",
http://www.amd.com/products/cpg/athlon/techdocs/pdf/23614.pdf
Signature · 1 line
Andreas E. Bombe <[email protected]> DSA key 0x04880A44
Hi!
Review
Quoted 10 lines
(quoted diff) +10
-0+static void stpclk_idle(void) +{ + if (current_cpu_data.hlt_works_ok && !hlt_counter) { + __cli(); + if (!current->need_resched) + inb(Reg_PL2); + else + __sti(); + } +}
You are not using hlt instruction -> you don't need to care about hlt_works_ok.
Pavel
Signature · 2 lines
I'm [email protected]. "In my country we have almost anarchy and I don't care." Panos Katsaloulis describing me w.r.t. patents at [email protected]