I have two graphics cards in my desktop. AMD PRO (primary) and AMD RX (second). The second one is used in vm, hence I set it accordingly in the kernel parameters (vfio-pci.ids=). Recently, however, I started playing with lxd and would like to use the second card inside the container, but because of this kernel parameter, the card is normally invisible.
My question is whether it is possible to disable the second gpu by default and enable or disable on demand, so that it is visible as needed both for vm and for lxd (but used by only one at a time), and disabled when not used at all?
I know that there is a way with nvidia. But is it possible with AMD?