Description:

Recently I wrote about making workspace quiet and it works great. But it's not very pragmatic and not very convinient. Why ? Because I don't use much Nvidia GPU inside LXC container and I have to shut down my workspace container (sic!) when I need to switch to the Windows virtual machine with attached Nvidia GPU. Besides Intel vPro technology doesn't work with discrete GPU, only with CPU based GPU. This is why I decided to attach Intel GPU to LXC container and Nvidia GPU will be completely dedicated to Windows. What I finally got:

LXC container (Intel GPU):

  1. HDMI dummy dongle plugged into one of internal GPU ports.
  2. Kernel module loaded with path to a custom EDID (unusual screen resolution, 2560x2880): drm.edid_firmware=lg_sdqhd.edid (embedded into initramfs, btw).
  3. Kernel module loaded with KMS: i915.modeset=1
  4. Use modesetting and explicitly defined modeline (xrandr didn't show desired resolution even with the custom EDID):
devbox ~ # cat /etc/X11/xorg.conf.d/20-intel.conf 

Section "Device"
  Identifier "Intel Graphics"
  Driver "modesetting"
  BusID  "pci:00:02:0" # <- Without it: "Cannot run in framebuffer mode. Please specify busIDs".
EndSection

Section "Monitor"
    Identifier "HDMI-2"
    Modeline "2560x2880"  238.25  2560 2608 2640 2720  2880 2883 2893 2921 +hsync -vsync # <- From Xorg.0.log after custom EDID loading.
    Option "PreferredMode" "2560x2880"
EndSection

Windows virtual machine (Nvidia GPU):

  1. No dummy dongle at all, because discrete GPU has a higher priority over internal GPU, e.g. Intel GPU isn't initialized during boot, vPro doesn't work etc.
  2. Virtual display with a custom resolution: virtula-display-rs
  3. Video BIOS loaded during virtual machine start:
mdz ~ # virsh dumpxml winbox-nvidia | grep rom
      <rom file='/etc/libvirt/tu117gl-t1000.vbios'/>

Results:

  1. Independent workspaces (Linux, Windows).
  2. Hardware is utilized more pragmatically.
  3. vPro works.