ericek111

QEMU/KVM macOS Hackintosh virsh GPU passthrough

Aug 1st, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 7.31 KB | None | 0 0
  1. <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
  2.   <name>macos-high-sierra</name>
  3.   <uuid>2aca0dd6-cec9-4717-9ab2-0b7b13d111c3</uuid>
  4.   <title>macOS Mojave</title>
  5.   <memory unit='KiB'>6291456</memory>
  6.   <currentMemory unit='KiB'>6291456</currentMemory>
  7.   <memoryBacking>
  8.     <hugepages/>
  9.   </memoryBacking>
  10.   <vcpu placement='static'>3</vcpu>
  11.   <cputune>
  12.     <vcpupin vcpu='0' cpuset='1'/>
  13.     <vcpupin vcpu='1' cpuset='2'/>
  14.     <vcpupin vcpu='2' cpuset='3'/>
  15.     <emulatorpin cpuset='0'/>
  16.   </cputune>
  17.   <os>
  18.     <type arch='x86_64' machine='pc-q35-2.11'>hvm</type>
  19.     <loader readonly='yes' type='pflash'>/var/lib/libvirt/boot/OVMF_CODE.fd</loader>
  20.     <nvram>/var/lib/libvirt/boot/OVMF_VARS-1024x768.fd</nvram>
  21.   </os>
  22.   <features>
  23.     <acpi/>
  24.     <kvm>
  25.       <hidden state='on'/>
  26.     </kvm>
  27.   </features>
  28.   <cpu mode='custom' match='exact' check='partial'>
  29.     <model fallback='allow'>Penryn</model>
  30.   </cpu>
  31.   <clock offset='utc'/>
  32.   <on_poweroff>destroy</on_poweroff>
  33.   <on_reboot>restart</on_reboot>
  34.   <on_crash>restart</on_crash>
  35.   <devices>
  36.     <emulator>/usr/bin/qemu-system-x86_64</emulator>
  37.     <disk type='block' device='disk'>
  38.       <driver name='qemu' type='raw' cache='writeback' io='threads'/>
  39.       <source dev='/dev/spare/macos'/>
  40.       <target dev='sdd' bus='sata'/>
  41.       <address type='drive' controller='0' bus='0' target='0' unit='3'/>
  42.     </disk>
  43.     <disk type='file' device='disk'>
  44.       <driver name='qemu' type='qcow2'/>
  45.       <source file='/var/lib/libvirt/images/Clover2.qcow2'/>
  46.       <target dev='sdf' bus='sata'/>
  47.       <boot order='1'/>
  48.       <address type='drive' controller='0' bus='0' target='0' unit='5'/>
  49.     </disk>
  50.     <controller type='sata' index='0'>
  51.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
  52.     </controller>
  53.     <controller type='pci' index='0' model='pcie-root'/>
  54.     <controller type='pci' index='1' model='dmi-to-pci-bridge'>
  55.       <model name='i82801b11-bridge'/>
  56.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
  57.     </controller>
  58.     <controller type='pci' index='2' model='pci-bridge'>
  59.       <model name='pci-bridge'/>
  60.       <target chassisNr='2'/>
  61.       <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
  62.     </controller>
  63.     <controller type='pci' index='3' model='pcie-root-port'>
  64.       <model name='pcie-root-port'/>
  65.       <target chassis='3' port='0x10'/>
  66.       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0' multifunction='on'/>
  67.     </controller>
  68.     <controller type='pci' index='4' model='pcie-root-port'>
  69.       <model name='pcie-root-port'/>
  70.       <target chassis='4' port='0x11'/>
  71.       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x1'/>
  72.     </controller>
  73.     <controller type='pci' index='5' model='pcie-root-port'>
  74.       <model name='pcie-root-port'/>
  75.       <target chassis='5' port='0x12'/>
  76.       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x2'/>
  77.     </controller>
  78.     <controller type='usb' index='0' model='ich9-ehci1'>
  79.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x7'/>
  80.     </controller>
  81.     <controller type='usb' index='0' model='ich9-uhci1'>
  82.       <master startport='0'/>
  83.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x0' multifunction='on'/>
  84.     </controller>
  85.     <controller type='usb' index='0' model='ich9-uhci2'>
  86.       <master startport='2'/>
  87.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x1'/>
  88.     </controller>
  89.     <controller type='usb' index='0' model='ich9-uhci3'>
  90.       <master startport='4'/>
  91.       <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x2'/>
  92.     </controller>
  93.     <controller type='virtio-serial' index='0'>
  94.       <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
  95.     </controller>
  96.     <interface type='bridge'>
  97.       <mac address='52:54:00:8e:e2:66'/>
  98.       <source bridge='br0'/>
  99.       <target dev='tap0'/>
  100.       <model type='e1000-82545em'/>
  101.       <address type='pci' domain='0x0000' bus='0x02' slot='0x02' function='0x0'/>
  102.     </interface>
  103.     <serial type='pty'>
  104.       <target type='isa-serial' port='0'>
  105.         <model name='isa-serial'/>
  106.       </target>
  107.     </serial>
  108.     <console type='pty'>
  109.       <target type='serial' port='0'/>
  110.     </console>
  111.     <console type='pty'>
  112.       <target type='virtio' port='1'/>
  113.     </console>
  114.     <channel type='spicevmc'>
  115.       <target type='virtio' name='com.redhat.spice.0'/>
  116.       <address type='virtio-serial' controller='0' bus='0' port='1'/>
  117.     </channel>
  118.     <channel type='unix'>
  119.       <target type='virtio' name='org.qemu.guest_agent.0'/>
  120.       <address type='virtio-serial' controller='0' bus='0' port='2'/>
  121.     </channel>
  122.     <input type='keyboard' bus='usb'>
  123.       <address type='usb' bus='0' port='2'/>
  124.     </input>
  125.     <input type='mouse' bus='ps2'/>
  126.     <input type='mouse' bus='virtio'>
  127.       <address type='pci' domain='0x0000' bus='0x00' slot='0x0d' function='0x0'/>
  128.     </input>
  129.     <input type='keyboard' bus='virtio'>
  130.       <address type='pci' domain='0x0000' bus='0x00' slot='0x0f' function='0x0'/>
  131.     </input>
  132.     <input type='keyboard' bus='ps2'/>
  133.     <input type='mouse' bus='usb'>
  134.       <address type='usb' bus='0' port='3'/>
  135.     </input>
  136.     <sound model='ich9'>
  137.       <address type='pci' domain='0x0000' bus='0x02' slot='0x01' function='0x0'/>
  138.     </sound>
  139.     <hostdev mode='subsystem' type='pci' managed='yes'>
  140.       <source>
  141.         <address domain='0x0000' bus='0x06' slot='0x00' function='0x0'/>
  142.       </source>
  143.       <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
  144.     </hostdev>
  145.     <hostdev mode='subsystem' type='pci' managed='yes'>
  146.       <source>
  147.         <address domain='0x0000' bus='0x06' slot='0x00' function='0x1'/>
  148.       </source>
  149.       <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
  150.     </hostdev>
  151.     <redirdev bus='usb' type='spicevmc'>
  152.       <address type='usb' bus='0' port='5'/>
  153.     </redirdev>
  154.     <hub type='usb'>
  155.       <address type='usb' bus='0' port='1'/>
  156.     </hub>
  157.     <memballoon model='none'/>
  158.   </devices>
  159.   <qemu:commandline>
  160.     <qemu:arg value='-device'/>
  161.     <qemu:arg value='isa-applesmc,osk=ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc'/>
  162.     <qemu:arg value='-smbios'/>
  163.     <qemu:arg value='type=2'/>
  164.     <qemu:arg value='-cpu'/>
  165.     <qemu:arg value='Penryn,kvm=on,vendor=GenuineIntel,+invtsc,vmware-cpuid-freq=on,+pcid,+ssse3,+sse4.2,+popcnt,+avx,+aes,+xsave,+xsaveopt,check'/>
  166.     <qemu:arg value='-object'/>
  167.     <qemu:arg value='input-linux,id=mouse1,evdev=/dev/input/by-id/usb-Logitech_G203_Prodigy_Gaming_Mouse_1468375F3336-event-mouse'/>
  168.     <qemu:arg value='-object'/>
  169.     <qemu:arg value='input-linux,id=kbd1,evdev=/dev/input/by-id/usb-SINO_WEALTH_USB_KEYBOARD-event-kbd,grab_all=on,repeat=on'/>
  170.     <qemu:env name='QEMU_AUDIO_DRV' value='pa'/>
  171.     <qemu:env name='QEMU_AUDIO_TIMER_PERIOD' value='200'/>
  172.     <qemu:env name='QEMU_PA_SAMPLES' value='1024'/>
  173.     <qemu:env name='PULSE_LATENCY_MSEC' value='20'/>
  174.     <qemu:env name='QEMU_PA_SERVER' value='/run/user/1000/pulse/native'/>
  175.   </qemu:commandline>
  176. </domain>
  177. Domain macos-high-sierra XML configuration not changed.
Add Comment
Please, Sign In to add comment