Hi Guys,
So I am a new Unraid user and successfully created a Big Sur VM with the help of Macinabox.
It works with VNC, but when I try to set my gpu ( https://www.sapphiretech.com/en/consumer/nitro-rx-580-8g-g5-se ) and switch input source on my monitor then I get a black screen.
I tried it with and without rom ( https://www.techpowerup.com/vgabios/197894/sapphire-rx580-8192-171107 ) but same error.
I also selected the sound card inside it and edited my xml manually as suggested in Spaceinvader One - Advanced GPU passthrough techniques on Unraid video. So multifunction is turned on. Bus ans slot is the same, gpu is function 0 and sound card is function 1.
UEFI boot is turned off in Unraid.
OSX SMBIOS is set to iMac 19,2 but also tried with iMacPro 1,1.
Same error in both cases.
In the BIOS I set the Intel UHD 630 gpu to be the initial gpu.
Any idea to make the gpu passthrough work?
System info
Model: Custom
M/B: Gigabyte Technology Co., Ltd. Z390 DESIGNARE-CF Version x.x - s/n: Default string
BIOS: American Megatrends Inc. Version F9j. Dated: 01/19/2021
CPU: Intel® Core™ i7-8700K CPU @ 3.70GHz
HVM: Enabled
IOMMU: Enabled
Cache: 384 KiB, 1536 KiB, 12 MB
Memory: 32 GiB DDR4 (max. installable capacity 64 GiB)
Network: bond0: fault-tolerance (active-backup), mtu 1500
eth0: interface down
eth1: 1000 Mbps, full duplex, mtu 1500
Kernel: Linux 5.10.21-Unraid x86_64
OpenSSL: 1.1.1j
You can see my xml below
<?xml version='1.0' encoding='UTF-8'?>
<domain type='kvm'>
<name>Macinabox BigSur</name>
<uuid>3220c0ff-52d1-4b1f-9ce1-edacb0d43ebc</uuid>
<description>MacOS Big Sur</description>
<metadata>
<vmtemplate xmlns="unraid" name="Windows 10" icon="default.png" os="osx"/>
</metadata>
<memory unit='KiB'>17301504</memory>
<currentMemory unit='KiB'>17301504</currentMemory>
<memoryBacking>
<nosharepages/>
</memoryBacking>
<vcpu placement='static'>12</vcpu>
<cputune>
<vcpupin vcpu='0' cpuset='0'/>
<vcpupin vcpu='1' cpuset='6'/>
<vcpupin vcpu='2' cpuset='1'/>
<vcpupin vcpu='3' cpuset='7'/>
<vcpupin vcpu='4' cpuset='2'/>
<vcpupin vcpu='5' cpuset='8'/>
<vcpupin vcpu='6' cpuset='3'/>
<vcpupin vcpu='7' cpuset='9'/>
<vcpupin vcpu='8' cpuset='4'/>
<vcpupin vcpu='9' cpuset='10'/>
<vcpupin vcpu='10' cpuset='5'/>
<vcpupin vcpu='11' cpuset='11'/>
</cputune>
<os>
<type arch='x86_64' machine='pc-q35-5.1'>hvm</type>
<loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader>
<nvram>/etc/libvirt/qemu/nvram/3220c0ff-52d1-4b1f-9ce1-edacb0d43ebc_VARS-pure-efi.fd</nvram>
</os>
<features>
<acpi/>
<apic/>
</features>
<cpu mode='host-passthrough' check='none' migratable='on'>
<topology sockets='1' dies='1' cores='6' threads='2'/>
<cache mode='passthrough'/>
</cpu>
<clock offset='utc'>
<timer name='rtc' tickpolicy='catchup'/>
<timer name='pit' tickpolicy='delay'/>
<timer name='hpet' present='no'/>
</clock>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<devices>
<emulator>/usr/local/sbin/qemu</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='raw' cache='writeback'/>
<source file='/mnt/user/domains/Macinabox BigSur/macos_disk.img'/>
<target dev='hdc' bus='sata'/>
<boot order='1'/>
<address type='drive' controller='0' bus='0' target='0' unit='2'/>
</disk>
<controller type='pci' index='0' model='pcie-root'/>
<controller type='pci' index='1' model='pcie-root-port'>
<model name='pcie-root-port'/>
<target chassis='1' port='0x8'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
</controller>
<controller type='pci' index='2' model='pcie-root-port'>
<model name='pcie-root-port'/>
<target chassis='2' port='0x9'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
</controller>
<controller type='pci' index='3' model='pcie-root-port'>
<model name='pcie-root-port'/>
<target chassis='3' port='0x12'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x2'/>
</controller>
<controller type='pci' index='4' model='pcie-root-port'>
<model name='pcie-root-port'/>
<target chassis='4' port='0x13'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x3'/>
</controller>
<controller type='virtio-serial' index='0'>
<address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
</controller>
<controller type='sata' index='0'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
</controller>
<controller type='usb' index='0' model='ich9-ehci1'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x7'/>
</controller>
<controller type='usb' index='0' model='ich9-uhci1'>
<master startport='0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0' multifunction='on'/>
</controller>
<controller type='usb' index='0' model='ich9-uhci2'>
<master startport='2'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x1'/>
</controller>
<controller type='usb' index='0' model='ich9-uhci3'>
<master startport='4'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x2'/>
</controller>
<interface type='bridge'>
<mac address='52:54:00:ed:fe:fd'/>
<source bridge='br0'/>
<model type='virtio-net'/>
<address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
</interface>
<serial type='pty'>
<target type='isa-serial' port='0'>
<model name='isa-serial'/>
</target>
</serial>
<console type='pty'>
<target type='serial' port='0'/>
</console>
<channel type='unix'>
<target type='virtio' name='org.qemu.guest_agent.0'/>
<address type='virtio-serial' controller='0' bus='0' port='1'/>
</channel>
<input type='tablet' bus='usb'>
<address type='usb' bus='0' port='1'/>
</input>
<input type='mouse' bus='ps2'/>
<input type='keyboard' bus='ps2'/>
<hostdev mode='subsystem' type='pci' managed='yes'>
<driver name='vfio'/>
<source>
<address domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
</source>
<rom file='/mnt/user/isos/Sapphire.RX580.8192.170511.rom'/>
<address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0' multifunction='on'/>
</hostdev>
<hostdev mode='subsystem' type='pci' managed='yes'>
<driver name='vfio'/>
<source>
<address domain='0x0000' bus='0x02' slot='0x00' function='0x1'/>
</source>
<address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/>
</hostdev>
<memballoon model='none'/>
</devices>
</domain>
In syslinux I have the following config
kernel /bzimage
append initrd=/bzroot,/bzroot-gui pcie_aspm=off pcie_acs_override=downstream,multifunction vfio-pci.ids=1002:67df,1002:aaf0