PCIe USB 3.0 controller card passthrough


Recommended Posts

Hello all,

 

Looking for some guidance and help in getting a PCIe USB 3.0 card passed through to a Windows 7 VM.  The card in question is this bad boy made my mediasonic.

 

Bus 1 --> 0000:00:1a.0 (IOMMU group 4)                                                                                                         
Bus 001 Device 004: ID 13fe:3123 Kingston Technology Company Inc. Verbatim STORE N GO 4GB                                                      
Bus 001 Device 003: ID 0557:2221 ATEN International Co., Ltd Winbond Hermon                                                                    
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub                                                                      
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub                                                                                 
                                                                                                                                               
Bus 2 --> 0000:00:1d.0 (IOMMU group                                                                                                          
Bus 002 Device 003: ID 1bcf:0c31 Sunplus Innovation Technology Inc. SPIF30x Serial-ATA bridge                                                  
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub                                                                      
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub                                                                                 
                                                                                                                                               
Bus 3 --> 0000:03:00.0 (IOMMU group 2)                                                                                                         
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub                                                                                 
                                                                                                                                               
Bus 4 --> 0000:03:00.0 (IOMMU group 2)                                                                                                         
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

 

IOMMU group 0                                                                                                                                  
        00:00.0 Host bridge [0600]: Intel Corporation Xeon E3-1200 v2/Ivy Bridge DRAM Controller [8086:0158] (rev 09)
IOMMU group 1                                                                                                                                  
        00:01.0 PCI bridge [0604]: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor PCI Express Root Port [8086:0151] (rev 09)
        00:01.1 PCI bridge [0604]: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor PCI Express Root Port [8086:0155] (rev 09)
[RESET] 01:00.0 Serial Attached SCSI controller [0107]: LSI Logic / Symbios Logic SAS2008 PCI-Express Fusion-MPT SAS-2 [Falcon] [1000:0072] (re
v 03)                                                                                                                                          
[RESET] 02:00.0 Serial Attached SCSI controller [0107]: LSI Logic / Symbios Logic SAS2008 PCI-Express Fusion-MPT SAS-2 [Falcon] [1000:0072] (re
v 02)                                                                                                                                          
IOMMU group 2                                                                                                                                  
        00:06.0 PCI bridge [0604]: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor PCI Express Root Port [8086:015d] (rev 09)
[RESET] 03:00.0 USB controller [0c03]: Renesas Technology Corp. uPD720202 USB 3.0 Host Controller [1912:0015] (rev 02)                         
IOMMU group 3                                                                                                                                  
        00:16.0 Communication controller [0780]: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #1 [8086:1c3a] (rev 04)
        00:16.1 Communication controller [0780]: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #2 [8086:1c3b] (rev 04)
IOMMU group 4                                                                                                                                  
[RESET] 00:1a.0 USB controller [0c03]: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #2 [8086:1c2d] (rev 0
5)                                                                                                                                             
IOMMU group 5                                                                                                                                  
[RESET] 00:1c.0 PCI bridge [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 [8086:1c10] (rev b5)          
IOMMU group 6                                                                                                                                  
[RESET] 00:1c.6 PCI bridge [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 7 [8086:1c1c] (rev b5)          
IOMMU group 7                                                                                                                                  
[RESET] 00:1c.7 PCI bridge [0604]: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 8 [8086:1c1e] (rev b5)          
IOMMU group 8                                                                                                                                  
[RESET] 00:1d.0 USB controller [0c03]: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #1 [8086:1c26] (rev 0
5)                                                                                                                                             
IOMMU group 9                                                                                                                                  
        00:1e.0 PCI bridge [0604]: Intel Corporation 82801 PCI Bridge [8086:244e] (rev a5)                                                     
[RESET] 07:03.0 VGA compatible controller [0300]: Matrox Electronics Systems Ltd. MGA G200eW WPCM450 [102b:0532] (rev 0a)                      
IOMMU group 10                                                                                                                                 
        00:1f.0 ISA bridge [0601]: Intel Corporation C204 Chipset Family LPC Controller [8086:1c54] (rev 05)
[RESET] 00:1f.2 SATA controller [0106]: Intel Corporation 6 Series/C200 Series Chipset Family SATA AHCI Controller [8086:1c02] (rev 05)        
        00:1f.3 SMBus [0c05]: Intel Corporation 6 Series/C200 Series Chipset Family SMBus Controller [8086:1c22] (rev 05)                      
IOMMU group 11                                                                                                                                 
[RESET] 05:00.0 Ethernet controller [0200]: Intel Corporation 82574L Gigabit Network Connection [8086:10d3]                                    
IOMMU group 12                                                                                                                                 
[RESET] 06:00.0 Ethernet controller [0200]: Intel Corporation 82574L Gigabit Network Connection [8086:10d3]

 

Window VM XML

<domain type='kvm'>
  <name>Windows 7</name>
  <uuid>f9232898-ac1a-b0ab-9417-3d980469ad88</uuid>
  <metadata>
    <vmtemplate xmlns="unraid" name="Windows 7" icon="windows7.png" os="windows7"/>
  </metadata>
  <memory unit='KiB'>4194304</memory>
  <currentMemory unit='KiB'>4194304</currentMemory>
  <memoryBacking>
    <nosharepages/>
  </memoryBacking>
  <vcpu placement='static'>2</vcpu>
  <cputune>
    <vcpupin vcpu='0' cpuset='3'/>
    <vcpupin vcpu='1' cpuset='7'/>
  </cputune>
  <os>
    <type arch='x86_64' machine='pc-i440fx-2.5'>hvm</type>
  </os>
  <features>
    <acpi/>
    <apic/>
    <hyperv>
      <relaxed state='on'/>
      <vapic state='on'/>
      <spinlocks state='on' retries='8191'/>
      <vendor id='none'/>
    </hyperv>
  </features>
  <cpu mode='host-passthrough'>
    <topology sockets='1' cores='1' threads='2'/>
  </cpu>
  <clock offset='localtime'>
    <timer name='hypervclock' present='yes'/>
    <timer name='hpet' present='no'/>
  </clock>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
    <emulator>/usr/local/sbin/qemu</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/vms/Windows 7/vdisk1.img'/>
      <target dev='hdc' bus='virtio'/>
      <boot order='1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </disk>
    <controller type='usb' index='0' model='ich9-ehci1'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x7'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci1'>
      <master startport='0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0' multifunction='on'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci2'>
      <master startport='2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x1'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci3'>
      <master startport='4'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x2'/>
    </controller>
    <controller type='pci' index='0' model='pci-root'/>
    <controller type='virtio-serial' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </controller>
    <interface type='bridge'>
      <mac address='52:54:00:c3:73:f5'/>
      <source bridge='br0'/>
      <model type='virtio'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    </interface>
    <serial type='pty'>
      <target port='0'/>
    </serial>
    <console type='pty'>
      <target type='serial' port='0'/>
    </console>
    <channel type='unix'>
      <source mode='connect'/>
      <target type='virtio' name='org.qemu.guest_agent.0'/>
      <address type='virtio-serial' controller='0' bus='0' port='1'/>
    </channel>
    <input type='tablet' bus='usb'/>
    <input type='mouse' bus='ps2'/>
    <input type='keyboard' bus='ps2'/>
    <graphics type='vnc' port='-1' autoport='yes' websocket='-1' listen='0.0.0.0' keymap='en-us'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>
    <video>
      <model type='cirrus' vram='16384' heads='1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>
    <hostdev mode='subsystem' type='usb' managed='no'>
      <source>
        <vendor id='0x1bcf'/>
        <product id='0x0c31'/>
      </source>
    </hostdev>
    <memballoon model='virtio'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
    </memballoon>
  </devices>
</domain>

Link to comment

You should be able to pass it through if you stub it first in your syslinux.cfg, then reboot, and you should have it in the VM template under other devices.

There should be info in the 6.2 announcement thread on how to stub a device.

From the iommu groups you posted its only the card and the bridge, so it should most likely work.

Link to comment

You should be able to pass it through if you stub it first in your syslinux.cfg, then reboot, and you should have it in the VM template under other devices.

There should be info in the 6.2 announcement thread on how to stub a device.

From the iommu groups you posted its only the card and the bridge, so it should most likely work.

Sounds good and thanks for the point in the right direction.  When I get off of work I will take a stab at it and let you know how it goes.

Link to comment

You should be able to pass it through if you stub it first in your syslinux.cfg, then reboot, and you should have it in the VM template under other devices.

There should be info in the 6.2 announcement thread on how to stub a device.

From the iommu groups you posted its only the card and the bridge, so it should most likely work.

 

Just a quick thanks and point in the right direction.  I was able to get the USB 3.0 card stubbed out and passed into the Windows 7 VM.  Once there a driver installed made it show right up and work without an issue.

 

Thanks!!

Link to comment

You should be able to pass it through if you stub it first in your syslinux.cfg, then reboot, and you should have it in the VM template under other devices.

There should be info in the 6.2 announcement thread on how to stub a device.

From the iommu groups you posted its only the card and the bridge, so it should most likely work.

 

Just a quick thanks and point in the right direction.  I was able to get the USB 3.0 card stubbed out and passed into the Windows 7 VM.  Once there a driver installed made it show right up and work without an issue.

 

Thanks!!

Glad you got it working  :)

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.