psexec -i -d -s c:\windows\regedit.exe
:: HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP
:: delete \*

:: https://www.reddit.com/r/HyperV/comments/1bt5m9c/comment/kxpuyq0/

:: GPU v limbu:
:: This happens when the PCIe device is already marked as "dismounted" under PCIP in the registry. I have had this happen to me a number of times when switching GPUs, or physically moving the GPU to another PCIe slot.
::      The only way I have found to fix this issue is to remove the entire key+sub keys for the device under PCIP in the registry. There is one caveat however. To perform the removal in the registry, you need to be running under the "SYSTEM" account credential. While it's not the only way to do it, this is made easy for us by using psexec. Follow the steps below and you should be good.
::      From an elevated prompt:
::      psexec -i -d -s c:\windows\regedit.exe
::      Find device as “Dismounted” under “HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP”
::      Example: “PCI Express Graphics Processing Unit – Dismounted”
::      Delete the whole key with subkeys under PCIP.
::      Example: "HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP\VEN_10DE&DEV_1EB1&SUBSYS_12A010DE&REV_A1"
::      Reboot and you can dismount it again from the host
::      
::      Systém s 3x RTX 3060 Ti:
::      Computer\HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP\ <-- všechna dismnounted GPU
::      Computer\HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP\VEN_10DE&DEV_2489&SUBSYS_C9721462&REV_A1 <-- v tomto případě konkrétní model GPU
::      Computer\HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Enum\PCIP\VEN_10DE&DEV_2489&SUBSYS_C9721462&REV_A1\6&9197ff2&0&00000011 <-- konkrétní GPU, celý tento klíč i se subklíči smazat
::      reboot a dismount bude fungovat
:: pomáhá vypojit fyzicky GPU a následně odinstalovat zařízení (show hidden devices přes devmgmt)
::      device manager -> show hidden devices -> uninstall unplugged GPU