User Tools

Site Tools


public:gpu-passthrough

This is an old revision of the document!


GPU Passthrough

GPU passthrough refers to configuration where a graphics card is reserved for use by a virtual machine. Making use of VT-d, IOMMU, and related technologies, the graphics card can be used at native performance.

This page describes my specific system configurations.

Hardware

Hardware Configuration:

  • Asus P8B WS
  • Intel E3-1275 (Sandy Bridge)
  • 32GB Kingston ECC Unbuffered
  • EVGA NVIDIA GTX 570
  • [Testing: NVIDIA 8800 GT]
  • [Purchase: Gigabyte 750 Ti GV-N75TOC-2GI]
  • Asus Xonar DX

iommu_groups.sh

Shows pci devices grouped by IOMMU group

#!/bin/sh

BASE="/sys/kernel/iommu_groups"

for i in $(find $BASE -maxdepth 1 -mindepth 1 -type d); do
  GROUP=$(basename $i)
  echo "### GROUP $GROUP ###"
  for j in $(find $i/devices -type l); do
    DEV=$(basename $j)
    echo -n "  "
    lspci -s $DEV
  done
done

iommu_groups.sh output

This output corresponds to the following pci card configuration:

  • Slot 1 (16x): Nvidia GeForce 570
  • Slot 2 (16x): empty
  • Slot 3 (1x): empty
  • Slot 4 (16x): Asus Xonar DX
  • Slot 5 (PCI): Silicon Image SATA Controller
  • Slot 6 (16x): empty

iommu_groups.sh output

Kernel

Because the C206 chipset is affected by the Intel root port isolation quirk (1, 2), both graphics cards are isolated in their own IOMMU group. The pcie_acs_override patch is not needed. (To check if the root port isolation quirk exists, grep dmesg for “Intel PCH root port ACS workaround enabled”.)

If we wanted to use the integrated graphics of the E3-1275, then we would need to either:

  • Use the i914.enable_hd_vgaarb patch (and lose DRI).
  • Use a guest GPU that supports UEFI and use the OVMF boot firmware to start the virtual machine. (OVMF can initialize the GPU using legacy-free UEFI, keeping DRI and bypassing VGA and the need for arbitration.)

References

public/gpu-passthrough.1447372046.txt.gz · Last modified: 2015/11/12 23:47 by squires

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki