Skip to contentSkip to conversation

USB-OHCI / UHCI: Isochronous transfer not working on Linux host

Qemu-devel Thomas Bandelier 4 participants 5 messages Nov 27, 2008 – Dec 11, 2008

lore
Share & tools
lore
#0 lore raw

Hi all,

Following several tests we did with qemu trunk, Isochronous transfer seems to be broken with the head of qemu.

We tried following Os (targets):
-WinXP (i386)
-Win2k (i386)
-Several linux kernel ( 2.6.26-1 (i386), 2.6.27 (ARM) )

On our host we are using Gentoo with 2.6.23 and 2.6.27 kernel.

Following USB devices were tested:
-USB 2.0 logitech webcams
-Terratec USB2.0 Cynergy hybrid XS FM tuner.

Both OHCI and UHCI configurations were tested in i386 target. Only OHCI was tested in ARM target.

In all these configurations, it was *never* possible to initiate isochronous USB transfer. It was possible to enumerate the devices but as soon as isochronous packets were used, the procedure failed. It means for example that no picture was retrieved from the webcams, and no audio data was retrieved from FM tuner.

It is important to mention that all theses devices perfectly work on our host.

After some search in this maling list archives, it seems that no work has been made on these aspects since Arnon Gilboa sent some patches more than one year ago. Am I wrong?

So It would be very useful for us to have a feedback from the community on this point.
Has someone met the same problems? Has someone investigated this aspect? Is someone regularly using this feature?

How can we investigate this problem?

Thanks

Thomas

#1 lore raw

Hello Thomas,

Since the last time I sent a patch, usb-linux.c & usb-uhci.c were completly rewritten by
Max Krasnyansky and merged by aliguori.

However, looking at my post below from 24 Sep 2007, you can see that usb-uhci,
which is USB 1.1 host controller emulation, was mostly tested on USB 1.1 devices.

I am sure that many USB 2.0 and even several 1.1 devices (especially isochronous)
will NOT work with the emulation.

http://lists.gnu.org/archive/html/qemu-devel/2007-09/msg00409.html

Regards,
Arnon

________________________________

From: Thomas Bandelier [mailto:[email protected]]
Sent: Thursday, November 27, 2008 4:06 PM
To: [email protected]
Cc: [email protected]; Arnon Gilboa
Subject: USB-OHCI / UHCI: Isochronous transfer not working on Linux host

Hi all,

Following several tests we did with qemu trunk, Isochronous transfer seems to be broken with the head of qemu.

We tried following Os (targets):
-WinXP (i386)
-Win2k (i386)
-Several linux kernel ( 2.6.26-1 (i386), 2.6.27 (ARM) )

On our host we are using Gentoo with 2.6.23 and 2.6.27 kernel.

Following USB devices were tested:
-USB 2.0 logitech webcams
-Terratec USB2.0 Cynergy hybrid XS FM tuner.

Both OHCI and UHCI configurations were tested in i386 target. Only OHCI was tested in ARM target.

In all these configurations, it was never possible to initiate isochronous USB transfer. It was possible to enumerate the devices but as soon as isochronous packets were used, the procedure failed. It means for example that no picture was retrieved from the webcams, and no audio data was retrieved from FM tuner.

It is important to mention that all theses devices perfectly work on our host.

After some search in this maling list archives, it seems that no work has been made on these aspects since Arnon Gilboa sent some patches more than one year ago. Am I wrong?

So It would be very useful for us to have a feedback from the community on this point.
Has someone met the same problems? Has someone investigated this aspect? Is someone regularly using this feature?

How can we investigate this problem?

Thanks

Thomas

#2 lore raw

Hi Arnon, Max, Pierre,

Arnon, Thanks for your feedback on this point.

As we need to manage several USB 2.0 devices in our environment, we are going to work on this aspect. We are very motivated to make it work.

Do you (Max and/or Arnon) have any idea of what should be done / reworked in order to support USB 2.0 devices and especially isochronous transfers in QEMU?

We would prefer keeping OHCI implementation, but do you think we should switch to UHCI? Or maybe EHCI?

If we can keep OHCI, what should we begin to do in order to debug current QEMU OHCI implementation? Same question for the other controllers if we have to switch.

Best Regards,

Thomas

Quoted 82 lines · Arnon Gilboa

Hello Thomas,

Since the last time I sent a patch, usb-linux.c & usb-uhci.c were completly rewritten by
Max Krasnyansky and merged by aliguori.

However, looking at my post below from 24 Sep 2007, you can see that usb-uhci,
which is USB 1.1 host controller emulation, was mostly tested on USB 1.1 devices.

I am sure that many USB 2.0 and even several 1.1 devices (especially isochronous)
will NOT work with the emulation.

http://lists.gnu.org/archive/html/qemu-devel/2007-09/msg00409.html

Regards,
Arnon

------------------------------
*From:* Thomas Bandelier [mailto:[email protected]] *Sent:* Thursday, November 27, 2008 4:06 PM
*To:* [email protected]
*Cc:* [email protected]; Arnon Gilboa
*Subject:* USB-OHCI / UHCI: Isochronous transfer not working on Linux host

Hi all,

Following several tests we did with qemu trunk, Isochronous transfer seems to be broken with the head of qemu.

We tried following Os (targets):

(quoted diff) +0 -3
-WinXP (i386)
-Win2k (i386)
-Several linux kernel ( 2.6.26-1 (i386), 2.6.27 (ARM) )

On our host we are using Gentoo with 2.6.23 and 2.6.27 kernel.

Following USB devices were tested:

(quoted diff) +0 -2
-USB 2.0 logitech webcams
-Terratec USB2.0 Cynergy hybrid XS FM tuner.

Both OHCI and UHCI configurations were tested in i386 target. Only OHCI was tested in ARM target.

In all these configurations, it was *never* possible to initiate isochronous USB transfer. It was possible to enumerate the devices but as soon as isochronous packets were used, the procedure failed. It means for example that no picture was retrieved from the webcams, and no audio data was retrieved from FM tuner.

It is important to mention that all theses devices perfectly work on our host.

After some search in this maling list archives, it seems that no work has been made on these aspects since Arnon Gilboa sent some patches more than one year ago. Am I wrong?

So It would be very useful for us to have a feedback from the community on this point.
Has someone met the same problems? Has someone investigated this aspect? Is someone regularly using this feature?

How can we investigate this problem?

Thanks

Thomas

#3 lore raw

Sorry for delay in replying.
(CCing Mark Burkley who recently posted EHCI patches)

Quoted 7 lines · Thomas Bandelier

Hi Arnon, Max, Pierre,

Arnon, Thanks for your feedback on this point.

As we need to manage several USB 2.0 devices in our environment, we are going to work on this aspect. We are very motivated to make it work.

Do you (Max and/or Arnon) have any idea of what should be done / reworked in order to support USB 2.0 devices and especially isochronous transfers in QEMU?

Most USB 2.0 devices should work just fine with the current UHCI code. Including isochronous transfers. While developing new UHCI implementation I was testing it with several 2.0 devices like USB storage devices and MS Webcam. Webcam uses isoc transfers and worked fairly well. However since UHCI does not do 2.0 rates USB bandwidth is much lower in the guest.

Quoted 3 lines

We would prefer keeping OHCI implementation, but do you think we should switch to UHCI? Or maybe EHCI?

If we can keep OHCI, what should we begin to do in order to debug current QEMU OHCI implementation? Same question for the other controllers if we have to switch.

Ideally we need to switch to EHCI in order to support high USB2.0 speeds. Not too long ago Mark posted a EHCI implementation (I have not had much luck with it and XP yet though). Otherwise if you're ok with lower BW then UHCI should work fine.

Max

#4 lore raw
In reply to Thomas Bandelier

I met the same problem when using usb-ohci.c with usb-linux.c and usb.c in head version.
Comparing usb-ohci.c on head and in 0.9.1, there is little difference but the other 2 files are totally different.
It could work if I pickup usb-linux.c and usb.c from 0.9.1.

Quoted 15 lines · Thomas Bandelier-2 wrote:

Hi all,

So It would be very useful for us to have a feedback from the community on this point.
Has someone met the same problems? Has someone investigated this aspect? Is someone regularly using this feature?

How can we investigate this problem?

Thanks

Thomas

Signature · 2 lines
View this message in context: http://www.nabble.com/USB-OHCI---UHCI%3A-Isochronous-transfer-not-working-on-Linux-host-tp20719918p20914454.html
Sent from the QEMU - Dev mailing list archive at Nabble.com.