Re: How to pass through off-chip USB controller
Wu, Binbin
Hi,
toggle quoted messageShow quoted text
/The following instruction will take PCI device 'USB Host 00:15.0' as an example to show the set-up steps./ / / /If lspci is not found in your clearlinux sos, you can install the tool by/ /swupd bundle-add sysadmin-basic / / / [edit <http://los-vmm.sc.intel.com/mediawiki//index.php?title=VTd_Enabling_Guide&action=edit§ion=3>]Hide PCI device in SOS 1) Find out the physical BDF (bus:device.function) for USB Host $ lspci <<<<<<<output>>>>>>> ... *00:15.0* USB controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series USB xHCI (rev 0b) ... 2) Find out the numeric PCI ID for USB Host $ lspci -n <<<<<<<output>>>>>>> ... *00:15.0* 0c03:*8086:5aa8* (rev 0b) ... 3) Hide the PCI device in SOS via stub driver Execute the following commands to hide the PCI device "00:15.0" in SOS echo "8086 5aa8" > /sys/bus/pci/drivers/pci-stub/new_id echo "0000:00:15.0" > /sys/bus/pci/devices/0000:00:15.0/driver/unbind echo "0000:00:15.0" > /sys/bus/pci/drivers/pci-stub/bind You could double-check whether the PCI device is hidden successfully via the following command. $ cat /sys/bus/pci/devices/0000:00:15.0/uevent If it is done successfully, the driver will be shown as 'pci-stub'. Example: root@jiechen-xubuntu:~# cat /sys/bus/pci/devices/0000:00:15.0/uevent *DRIVER=pci-stub* PCI_CLASS=C0330 PCI_ID=8086:5AA8 PCI_SUBSYS_ID=0000:0000 PCI_SLOT_NAME=0000:00:15.0 MODALIAS=pci:v00008086d00005AA8sv00000000sd00000000bc0Csc03i30 [edit <http://los-vmm.sc.intel.com/mediawiki//index.php?title=VTd_Enabling_Guide&action=edit§ion=4>]Add parameters in the boot-up command for UOS Add the following parameters in the boot-up command to pass PCI device 0:15.0 to guest @ virtual PCI 0:7.0 -s 7,passthru,0/15/0 You could change '7' to any other number as long as it's not used by other devices yet.
On 9/6/2018 8:47 PM, Geoffroy Van Cutsem wrote:
|
|