I found a way to use the GPU! It's not perfect, but it survives reboots and shutdowns of the VMs
Basically, I used this to unbind the gpu:
https://forum.level1techs.com/t/vfio-pass-through-working-on-9070xt/227194.
NOTE: For this to work you need to remove amdgpu from
/etc/modprobe.d/blacklist.conf
and also remove it from
/etc/modprobe.d/vfio.conf
.
This will make proxmox use the amdgpu driver, which you can then correctly unbind and pass it through to a VM.
This works well if you need to reboot the VM, if you need it to work for another VM or after vm shutdown, use the following commands:
Bash:
#Unbind vfio driver:
echo "0000:2f:00.0" > /sys/bus/pci/drivers/vfio-pci/unbind
#Bind the amdgpu driver:
echo "0000:2f:00.0" > /sys/bus/pci/drivers/amdgpu/bind
#Use the unbind script from the provided link
Don't forget to change the IDs for the PCI!
It's a bit janky, but it can be put into a script as a temporary workaround, I will update this when I will make it.