quasar_x Posted July 6, 2007 Share Posted July 6, 2007 I have a 1.73 Ghz Core Duo and was wondering why my CPU-freq would display 2167 Mhz on high load. "kern.cpu_maxfreq: 2167" seems to be the problem (see below): sudo sysctl -a | grep freq kern.exec: unknown type returned hw.busfrequency = 532000000 hw.cpufrequency = 1730000000 hw.tbfrequency = 1000000000 kern.cputhrottle_curfreq: 800 kern.cputhrottle_freqs: 800 1067 1333 1733 kern.cpu_currentfreq: 1000 kern.cpu_minfreq: 1000 kern.cpu_maxfreq: 2167 hw.busfrequency: 532000000 hw.busfrequency_min: 532000000 hw.busfrequency_max: 532000000 hw.cpufrequency: 1730000000 hw.cpufrequency_min: 1800000000 hw.cpufrequency_max: 1800000000 hw.tbfrequency: 1000000000 But when I try to change it by typing "sudo sysctl -w kern.cpu_maxfreq=1733" I always get: "sysctl: oid 'kern.cpu_maxfreq' is read only" I know this might be a dumb question, but how do I write to the various kern.cpu entries? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-403016 Share on other sites More sharing options...
quasar_x Posted July 7, 2007 Share Posted July 7, 2007 on manual switching with sysctl -w kern.cputhrottle_curfreq=xxx where xxx = 600,800,1000,1200,1700 the throttle will sometimes succeed and other times not. How did you manage to write to the variable? Everytime I am trying to modify either "kern.cputhrottle_curfreq" or "kern.cpu_maxfreq" I get: "sysctl: oid 'kern.cpu_*' is read only" Any ideas? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-403291 Share on other sites More sharing options...
delish Posted July 7, 2007 Share Posted July 7, 2007 quasar_x: login as root in terminal maybe? (sudo su) Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-403607 Share on other sites More sharing options...
quasar_x Posted July 7, 2007 Share Posted July 7, 2007 quasar_x: login as root in terminal maybe? (sudo su) Hehe, nope, that was of course the first thing that I tried. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-403616 Share on other sites More sharing options...
bishoy Hanna Posted July 12, 2007 Share Posted July 12, 2007 How can I see if speedstep is working? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-406934 Share on other sites More sharing options...
quasar_x Posted July 13, 2007 Share Posted July 13, 2007 How can I see if speedstep is working? Paste your sudo sysctl -a | grep freq output Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-407306 Share on other sites More sharing options...
bishoy Hanna Posted July 13, 2007 Share Posted July 13, 2007 Paste your sudo sysctl -a | grep freq output I don't even know what that means. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-407652 Share on other sites More sharing options...
josftx Posted July 25, 2007 Share Posted July 25, 2007 http://www.hostclip.com/dl/e1f5facfa6fc0e90f00c48538c3fbecb 10.4.9 kernel for SSE3, hpet with speedstep. Oh, and I changed code for wake from sleep, had to make an hpet call to wake properly. Now I can sleep it for hours and it wakes in about 5 seconds. Beat ya kiko The link doesn't work ,,, Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-414459 Share on other sites More sharing options...
teong85 Posted July 31, 2007 Share Posted July 31, 2007 Dead Link? any idea? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-418051 Share on other sites More sharing options...
paulicat Posted August 16, 2007 Share Posted August 16, 2007 I'll repost a new link for the kernel download later tonight. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429020 Share on other sites More sharing options...
Satyr Posted August 16, 2007 Share Posted August 16, 2007 When no kern.cputhrottle instances show up in dmesg output does that mean that: 1. Kernel speedstep failed or 2. AppleIntelCPUPowermanagement.kext failed in recognizing available CPU frequencies? Of course, ACPICPUThrottle.kext fails to load as well because of 1 or 2. Console log says SpeedStep kernel extension failed to load (AppleIntelCPU....kext?) I also have Core Duo 1.73 GHz. sysctl -a | grep freq Password: kern.exec: unknown type returned hw.busfrequency = 532000000 hw.cpufrequency = 1730000000 hw.tbfrequency = 1000000000 hw.busfrequency: 532000000 hw.busfrequency_min: 532000000 hw.busfrequency_max: 532000000 hw.cpufrequency: 1730000000 hw.cpufrequency_min: 1730000000 hw.cpufrequency_max: 1730000000 hw.tbfrequency: 1000000000 Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429079 Share on other sites More sharing options...
paulicat Posted August 17, 2007 Share Posted August 17, 2007 http://www.hostclip.com/dl/7d6b719485feb7050f3fff956f19f77d This is 10.4.9 mach_kernel and the associated ACPICPUThrottle files. Unzip this and you will get 1 file and 1 folder. Move mach_kernel to / Unzip the ACPICPUThrottle.zip and move the resulting folder to /Library/StartupItems Reboot. You'll get a prompt to repair permissions for the ACPICPUThrottle StartupItem. Click the Fix button and reboot once more. Upon the next login, run sysctl -a | grep throttle and look for lines such as: kern.cputhrottle_curfreq: 800 kern.cputhrottle_verbose: 0 kern.cputhrottle_freqs: 800 1067 1333 1600 1867 If these lines don't show up, the ACPICPUThrottle.kext didn't load for some reason. One thing to try is to turn OFF any speedstep related items in your bios. Sometimes this causes OSX to not be able to throttle the cpu. As far as I know, AppleIntelCPUPowermanagement.kext has no impact on Speedstep. For the record though, this kext is loaded up on my laptop. Good luck. Paulicat. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429383 Share on other sites More sharing options...
Satyr Posted August 17, 2007 Share Posted August 17, 2007 Thanks paulicat, I'm gonna try this tomorrow. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429391 Share on other sites More sharing options...
paulicat Posted August 17, 2007 Share Posted August 17, 2007 No problem, hope it works for ya. Paulicat. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429397 Share on other sites More sharing options...
Satyr Posted August 18, 2007 Share Posted August 18, 2007 Nope, it didn't work because of BIOS being "braindead" I was trying to figure out this for the whole day and this is what I learned: If BIOS doesn't report correct power states to ACPI or fails to do so, ACPICPUThrottle.kext fails to load. If BIOS doesn't reports correct powerstates to ACPI, that means that Windows are using magic tricks to throttle cpu. Not really. There is the other way to control powerstates on Enhanced SpeedStep CPUs (Pentium M, Core Duo, Core 2 Duo etc) and it's already implemented in ACPICPUThrottle.kext but it doesn't work because it pulls available powerstates from ACPI, which BIOS "forgot" to report. Since many laptops have this "braindead" BIOS, no wonder why so many people have this problem. There is solution though. Quick explanation: "Intel Pentium M processors have circuitry for changing their clock frequency and input voltage on-the-fly. In addition to providing a large range of frequencies -- typically between 5 and 7, in contrast to earlier processors from Intel, which only had "fast" and "slow" speeds -- this "Enhanced SpeedStep" is easier to control, requiring only that a MSR (model-specific register) be manipulated, unlike earlier versions which required BIOS support." (c/p from http://www.daemonology.net/freebsd-est/ ) Edit: AMDs support this "direct drive" throttling too It is possible (it's possible on windows and freebsd, I don't see a reason why this wouldn't work on OS X...) to supply ACPICPUThrottle.kext with pre-defined CPU table with their characteristics - available frequencies, just like this: . Experts, what do you think? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-429966 Share on other sites More sharing options...
paulicat Posted August 18, 2007 Share Posted August 18, 2007 Kiko posted a direct drive kext attempt earlier in this thread, did you try that one? Paulicat Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430175 Share on other sites More sharing options...
Satyr Posted August 18, 2007 Share Posted August 18, 2007 ACPICPUThrottle: No valid CPUs returned by ACPI! It's possible your BIOS does not think your system should be throttled and therefore did not return any available power states, or maybe your CPU only supports one other power state than maximum which is below 1Ghz! There is solution on the way though Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430182 Share on other sites More sharing options...
paulicat Posted August 18, 2007 Share Posted August 18, 2007 what solution? If that error about one state below 1Ghz is from my kext then ignore it. I removed that artificial limitation a long time ago, but I probably forgot to remove that text. What CPU do you have again?? Paulicat EDIT, I just tried Kikos direct drive kext, it still has the fake 1ghz barrier in it. Also, my kext has acpi code in it, but for kernels 10.4.8 and up, it will fail on acpi, but will procede to use DirectDrive also. I'm not entirely sure of what Kiko put in his kext though. Here's a copy/paste of dmesg after my kext is loaded on a core solo 1.87ghz: ACPICPUThrottle: Adding CPU0 ---> P0, 1867Mhz, 31000mW, 10us, 10us (ctrl=0xe2c, status=0xe2c) ---> P1, 1600Mhz, 26000mW, 10us, 10us (ctrl=0xc26, status=0xc26) ---> P2, 1333Mhz, 22000mW, 10us, 10us (ctrl=0xa20, status=0xa20) ---> P3, 1067Mhz, 17000mW, 10us, 10us (ctrl=0x81a, status=0x81a) ---> P4, 800Mhz, 13000mW, 10us, 10us (ctrl=0x613, status=0x613) ACPICPUThrottle: Using direct drive of Intel throttling Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430213 Share on other sites More sharing options...
Satyr Posted August 19, 2007 Share Posted August 19, 2007 Aug 19 16:23:55 s-computer kernel[0]: ACPICPUThrottle: Adding CPU1 Aug 19 16:23:55 s-computer kernel[0]: ACPICPUThrottle: Adding CPU2 Aug 19 16:23:55 s-computer kernel[0]: ACPICPUThrottle: No valid CPUs returned by ACPI! It's... No throttle in dmesg output... I have Core Duo T2250 @ 1.73 GHz. Correct me if I'm wrong but from your dmesg output it's clear that kext is using ACPI to get powerstates From Intel® 64 and IA-32 Architectures Software Developer’s Manual Volume 3A: System Programming Guide, Part 1 The Advanced Configuration and Power Interface (ACPI) defines performance states (P-state) that are used facilitate system software’s ability to manage processor power consumption. Different P-state correspond to different performance levels that are applied while the processor is actively executing instructions. Enhanced Intel SpeedStep Technology supports P-state by providing software interfaces that control the operating frequency and voltage of a processor. This is probable cause of my problem: A BIOS (following ACPI 3.0 specification) can choose to expose P-state as dependent and hardware-coordinated to OS power management (OSPM) policy. Which my BIOS obvioulsy don't Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430846 Share on other sites More sharing options...
paulicat Posted August 19, 2007 Share Posted August 19, 2007 Actually no, from my paste, the last line tells you that its using DirectDrive to control the cpu states. As of 10.4.8 there is 0 support for acpi throttle states. It will always use DirectDrive. I've attached a debug build of my kext. Please post the dmesg from: "ACPI CPU Throttle loaded" What laptop do you have by the way? Paulicat. ACPICPUThrottle.kext.zip Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430882 Share on other sites More sharing options...
Satyr Posted August 19, 2007 Share Posted August 19, 2007 Asus F3jc ACPICPUThrottle: Adding CPU1 ACPICPUThrottle: Failed with code -536870212 ACPICPUThrottle: Adding CPU2 ACPICPUThrottle: Failed with code -536870212 ACPICPUThrottle: No valid CPUs returned by ACPI! It's possible....... Edit: Is it possible that BIOS disables IA32_MISC_ENABLE MSR ? Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-430917 Share on other sites More sharing options...
paulicat Posted August 19, 2007 Share Posted August 19, 2007 It shouldn't but I suppose you never know. What power related options does your bios have? Paulicat. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-431038 Share on other sites More sharing options...
Satyr Posted August 19, 2007 Share Posted August 19, 2007 None. BIOS is stripped and locked down completely. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-431041 Share on other sites More sharing options...
paulicat Posted August 19, 2007 Share Posted August 19, 2007 Oh that sucks I don't think there's a whole I can do to help you bud. Something is definately blocking the kext from getting access to read out the cpu states. Sorry. Paulicat. Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-431044 Share on other sites More sharing options...
Satyr Posted August 19, 2007 Share Posted August 19, 2007 Oh well..., thanks a bunch anyway! Link to comment https://www.insanelymac.com/forum/topic/42865-howto-sse3-kernel-with-sleep-speedstep/page/10/#findComment-431046 Share on other sites More sharing options...
Recommended Posts