Skip to content

Latest commit

 

History

History
 
 

one-key-cpufriend

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Modify macOS CPU Performance

English | 中文

Instruction

I am a newcomer for bash language, and welcome pros to help improve the script.

The script is only for 8th generation CPU(KBL-R, CNL, CFL...).

The script can modify low frequency mode and energy performance preference, and use ResourceConverter.sh to generate customized CPUFriendDataProvider.kext.

By using this script, no file under the System folder will be edited. If you are not happy with the modification, just remove CPUFriend*.kext from /CLOVER/kexts/Other/ and restart.

Before install

  • Read CPUFriend WARNING
  • Good network
  • Make sure IOPlatformPluginFamily.kext untouched
  • Make sure Lilu is working
  • plugin-type=1

How to install

  • Run the following command in Terminal:
bash -c "$(curl -fsSL https://raw.githubusercontent.com/daliansky/XiaoMi-Pro-Hackintosh/master/one-key-cpufriend/one-key-cpufriend.sh)"
  • For Clover users:

    • Copy CPUFriend.kext and CPUFriendDataProvider.kext from desktop to /CLOVER/kexts/Other/ and restart.
  • For OC users:

    • Copy CPUFriend.kext and CPUFriendDataProvider.kext from desktop to /OC/Kexts/.
    • Open /OC/config.plist and find the following code:
<dict>
    <key>BundlePath</key>
    <string>CPUFriend.kext</string>
    <key>Comment</key>
    <string>Power Management</string>
    <key>Enabled</key>
    <false/>
    <key>ExecutablePath</key>
    <string>Contents/MacOS/CPUFriend</string>
    <key>MaxKernel</key>
    <string></string>
    <key>MinKernel</key>
    <string></string>
    <key>PlistPath</key>
    <string>Contents/Info.plist</string>
</dict>
<dict>
    <key>BundlePath</key>
    <string>CPUFriendDataProvider.kext</string>
    <key>Comment</key>
    <string>Power Management</string>
    <key>Enabled</key>
    <false/> 

Change to:

<dict>
    <key>BundlePath</key>
    <string>CPUFriend.kext</string>
    <key>Comment</key>
    <string>Power Management</string>
    <key>Enabled</key>
    <true/>
    <key>ExecutablePath</key>
    <string>Contents/MacOS/CPUFriend</string>
    <key>MaxKernel</key>
    <string></string>
    <key>MinKernel</key>
    <string></string>
    <key>PlistPath</key>
    <string>Contents/Info.plist</string>
</dict>
<dict>
    <key>BundlePath</key>
    <string>CPUFriendDataProvider.kext</string>
    <key>Comment</key>
    <string>Power Management</string>
    <key>Enabled</key>
    <true/>  

Recovery

  • For Clover users:

    • If you are not happy with the modification, just remove CPUFriend.kext and CPUFriendDataProvider.kext from /CLOVER/kexts/Other/ and restart.

    • If unfortunately, you can't boot into the system, and you are sure the issue is caused by CPUFriend*.kext,

      • Press Space when you are in Clover page
      • Use keyboard to choose Block Injected kexts - Other
      • Check CPUFriend.kext and CPUFriendDataProvider.kext
      • Return to the main menu and boot into the system, then delete CPUFriend*.kext from your CLOVER folder
  • For OC users:

Modify macOS CPU voltage

fladnaG86 provided script to lower down voltage of CPU/GPU/cache memory in #150, and welcome everyone to test it!

Credits