Skip to contentSkip to conversation

How to pass-through USB when Running Raspberry Pi image?

DISCUSSION Dmitry S Kravchenko 1 participant 1 message Oct 3, 2020

lore
Share & tools
lore
#0 lore raw

I am trying to emulate Raspberry Pi image on Linux host and have access to host USB ports and failing

My basic command line is

qemu-system-arm \
    -kernel qemu-rpi-kernel/kernel-qemu-4.4.34-jessie \
    -cpu arm1176 \
    -m 256 \
    -M versatilepb \
    -append "root=/dev/sda2 panic=1" \
    -hda 2017-07-05-raspbian-jessie.img \
    -usb \
    -redir tcp:5022::22 \
    -redir tcp:5080::80 \
    -serial stdio \
    -no-reboot

And I also tried to add some combinations of options such as

-usb \
-device qemu-xhci \
-device usb-ehci,id=ehci \
-device usb-host,hostbus=1,hostport=1.3

and so on, but failed.

I have no any usb on guest and also have

$ lsusb
unable to initalize libusb: -99

My host is Ubunto 18.04, my device is serial-based custom USB device

On host:

$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/6p, 5000M
    |__ Port 6: Dev 2, If 0, Class=Mass Storage, Driver=usb-storage, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/12p, 480M
    |__ Port 3: Dev 2, If 0, Class=Vendor Specific Class, Driver=ftdi_sio, 12M

last one is interested

How to investigate and fix?

--
Это сообщение проверено на вирусы антивирусом Avast.
https://www.avast.com/antivirus