Rate This Document
Findability
Accuracy
Completeness
Readability

Passing a Device Through to a VM

This section explains how to pass a created VF device through to a VM using VFIO, enabling low-latency and high-performance hardware access.

  1. Query the domain and BDF number of the passthrough device.
    lspci -tv

    In this example, the domain is 0000 and the BDF number is 17:00.0.

  2. Add the passthrough device information to the XML file, copy the content of hostdev to dev, and enter the domain and BDF number in source.
    <devices>
    <hostdev mode='subsystem' type='pci' managed='yes'>
    <driver name='vfio'/>
    <source>
    <address domain='0x0000' bus='0x17' slot='0x00' function='0x0'/>
    </source>
    </hostdev>
    </devices>
  3. On the VM, query the passthrough device information.
    lspci -tv