Qonfused/OSX-Hyper-V

AMD CPU Support

Closed this issue · 1 comments

It hasn't been noted anywhere explicitly that AMD CPUs are supported. As is the case for newer Intel CPUs (see #2), the steps for patching AMD CPUs are the same as with bare metal.

Important

AMD CPUs require the Kernel -> Emulate -> DummyPowerManagement option to be enabled in the config.plist as AMD does not have a native power management driver in macOS:

Kernel:
  Emulate:
    DummyPowerManagement: | Boolean | true

Note that unlike bare metal, iGPU/APUs are not visible to the VM by default and require DDA support. Refer to the README for an overview of these limitations.

Follow the AMD section of the Dortania Install guide for your CPU family. However, in addition to the AMD kernel patches (for AMD CPU families 15h, 16h, 17h and 19h), the below kernel patch is required for High Sierra and above:

Kernel:
  Patch:
    - Arch:                 String  | "x86_64"
      Base:                 String  | "_cpu_syscall_init"
      Comment:              String  | "flagers - kill invalid wrmsr | 10.13+"
      Count:                Integer | 3
      Find:                 Data    | "0F30"
      Identifier:           String  | "kernel"
      MaxKernel:            String  | "24.99.99"
      MinKernel:            String  | "17.0.0"
      Replace:              Data    | "9090"

You can also manually add the below plist entry to your config.plist:

Plist entry (file: patch.plist.zip)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Kernel</key>
    <dict>
        <key>Patch</key>
        <array>
            <dict>
                <key>Arch</key>
                <string>x86_64</string>
                <key>Base</key>
                <string>_cpu_syscall_init</string>
                <key>Comment</key>
                <string>flagers - kill invalid wrmsr | 10.13+</string>
                <key>Count</key>
                <integer>3</integer>
                <key>Enabled</key>
                <true/>
                <key>Find</key>
                <data>DzA=</data>
                <key>Identifier</key>
                <string>kernel</string>
                <key>Limit</key>
                <integer>0</integer>
                <key>Mask</key>
                <data></data>
                <key>MaxKernel</key>
                <string>24.99.99</string>
                <key>MinKernel</key>
                <string>17.0.0</string>
                <key>Replace</key>
                <data>kJA=</data>
                <key>ReplaceMask</key>
                <data></data>
                <key>Skip</key>
                <integer>0</integer>
            </dict>
        </array>
    </dict>
</dict>
</plist>

Will close for tracking. If time permits, I'd still like to find a better or more precise solution for the latter kernel patch.