You can't use xrandr as your second gpu is used by vfio and VM. You could probably be able to control monitor by hdmi (CEC) - check for example http://libcec.pulse-eight.com/
On 11/16/2016 12:50 AM, Fabian Lx wrote: > Hi, > > I have successfully set up my Windows 10 virtual machine using Alex > Williamson's guide. > Everything is working fine, however, I would like to improve my > experience by automatically switching the monitor input after booting > up the vm. > > My current monitor does not support an auto-detect mode, which would > switch the active input to my guest vm after deactivating the current > input via "$ xrandr --output HDMI2 --off". > Unfortunately "$ xrandr --listproviders" and "$ xrandr" only list the > Intel GPU (see "My PC specifications" below) so I have not been able > to set it up myself. > > I have seen that this issue has already been discussed in the > archlinux forums, although I am not sure whether this was related to > vfio. > No solution was mentioned in the thread at that time. > > https://bbs.archlinux.org/viewtopic.php?id=175743 > > > How can I make the second/guest GPU visible to xrandr or use it in > another way to switch the monitor input for my vm? > > > > > > My PC specifications: > > > Monitor: LG 24MP68VQ > > Host OS: Archlinux 4.8.7-1-ARCH > Host GPU: Intel HD Graphics 530 > > Guest OS: Windows 10 Home 64-bit > Guest GPU: AMD Sapphire RX 480 (No AMD reset issues with this card > anymore) > Guest GPU driver: Radeon Software Crimson Edition 16.11.3 > > > $ lspci | grep VGA > > 00:02.0 VGA compatible controller: Intel Corporation HD Graphics 530 > (rev 06) > 01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. > [AMD/ATI] Ellesmere [Radeon RX 480] (rev c7) > > > $ xrandr --listproviders > > Providers: number : 1 > Provider 0: id: 0x48 cap: 0xb, Source Output, Sink Output, Sink > Offload crtcs: 4 outputs: 5 associated providers: 0 name:Intel > > > $ xrandr > > Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 32767 x 32767 > DP1 disconnected (normal left inverted right x axis y axis) > HDMI1 disconnected (normal left inverted right x axis y axis) > HDMI2 connected primary 1920x1080+0+0 (normal left inverted right x > axis y axis) 480mm x 270mm > 1920x1080 60.00*+ > 1680x1050 59.88 > 1400x1050 59.95 > 1600x900 60.00 > 1280x1024 75.02 60.02 > 1440x900 59.90 > 1280x800 59.91 > 1152x864 75.00 > 1280x720 60.00 > 1024x768 75.03 60.00 > 800x600 75.00 60.32 > 640x480 75.00 59.94 > 720x400 70.08 > HDMI3 disconnected (normal left inverted right x axis y axis) > VIRTUAL1 disconnected (normal left inverted right x axis y axis) > > > > Best regards > Fabian > > _______________________________________________ > vfio-users mailing list > vfio-users@redhat.com > https://www.redhat.com/mailman/listinfo/vfio-users _______________________________________________ vfio-users mailing list vfio-users@redhat.com https://www.redhat.com/mailman/listinfo/vfio-users