All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
@ 2012-09-15 16:27 Jan Kiszka
  2012-09-17  9:08 ` Hans de Goede
  0 siblings, 1 reply; 17+ messages in thread
From: Jan Kiszka @ 2012-09-15 16:27 UTC (permalink / raw)
  To: qemu-devel; +Cc: Hans de Goede, Gerd Hoffmann

From: Jan Kiszka <jan.kiszka@siemens.com>

This follows the logic of host-linux: If a 2.0 device has no ISO
endpoint and no interrupt endpoint with a packet size > 64, we can
attach it also to an 1.1 host controller. In case the redir server does
not report endpoint sizes, play safe and remove the 1.1 compatibility as
well.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 hw/usb/redirect.c |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
index 5301a69..bc36e53 100644
--- a/hw/usb/redirect.c
+++ b/hw/usb/redirect.c
@@ -1098,6 +1098,9 @@ static void usbredir_device_connect(void *priv,
     }
 
     dev->dev.speedmask = (1 << dev->dev.speed);
+    if (dev->dev.speed == USB_SPEED_HIGH) {
+        dev->dev.speedmask |= USB_SPEED_MASK_FULL;
+    }
     dev->device_info = *device_connect;
 
     if (usbredir_check_filter(dev)) {
@@ -1172,7 +1175,14 @@ static void usbredir_ep_info(void *priv,
         case usb_redir_type_invalid:
             break;
         case usb_redir_type_iso:
+            dev->dev.speedmask &= ~USB_SPEED_MASK_FULL;
+            /* Fall through */
         case usb_redir_type_interrupt:
+            if (!usbredirparser_peer_has_cap(dev->parser,
+                                     usb_redir_cap_ep_info_max_packet_size) ||
+                ep_info->max_packet_size[i] > 64) {
+                dev->dev.speedmask &= ~USB_SPEED_MASK_FULL;
+            }
             if (dev->endpoint[i].interval == 0) {
                 ERROR("Received 0 interval for isoc or irq endpoint\n");
                 usbredir_device_disconnect(dev);
-- 
1.7.3.4

^ permalink raw reply related	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-15 16:27 [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller Jan Kiszka
@ 2012-09-17  9:08 ` Hans de Goede
  2012-09-17  9:18   ` Jan Kiszka
  2012-09-22  9:29   ` [Qemu-devel] [PATCH v2] " Jan Kiszka
  0 siblings, 2 replies; 17+ messages in thread
From: Hans de Goede @ 2012-09-17  9:08 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 09/15/2012 06:27 PM, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
>
> This follows the logic of host-linux: If a 2.0 device has no ISO
> endpoint and no interrupt endpoint with a packet size > 64, we can
> attach it also to an 1.1 host controller. In case the redir server does
> not report endpoint sizes, play safe and remove the 1.1 compatibility as
> well.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>

Interesting thanks for the patch. I like the approach you took (simple code),
but unfortunately it won't work, if you look at usbredir_device_connect(),
where you do the dev->dev.speedmask |= USB_SPEED_MASK_FULL, it also
actually attaches the device to the controller, from which point on the
guest will see the device.

What happens on the wire is that the usbredir-host sends (in order):
-ep_info + interface_info
-device_connect message

So your clearing of the speed-mask will never trigger, unless ep-info
gets repeated later (which it does under certain circumstances).

I suggest instead changing the code to set a "fullspeed_compatible" flag
in struct USBRedirDevice from usbredir_device_disconnect(), clear that
flag from usbredir_ep_info and use it to add to the mask in
usbredir_device_connect().

###

Another issue is what happens if a device "grows" incompatible endpoints
after being attached, ie a webcam could have no isoc endpoints in alt
setting 0, and then grow an isoc endpoint on a set_interface. So we
would need a check for a device becoming not fullspeed compat while
being attached at fullspeed in usbredir_ep_info(), and then call
usbredir_reject_device() when this happens.

Although not pretty I'm ok with this, since I actually want to add
similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
to work with ehci or uhci controllers :)

Regards,

Hans





> ---
>   hw/usb/redirect.c |   10 ++++++++++
>   1 files changed, 10 insertions(+), 0 deletions(-)
>
> diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
> index 5301a69..bc36e53 100644
> --- a/hw/usb/redirect.c
> +++ b/hw/usb/redirect.c
> @@ -1098,6 +1098,9 @@ static void usbredir_device_connect(void *priv,
>       }
>
>       dev->dev.speedmask = (1 << dev->dev.speed);
> +    if (dev->dev.speed == USB_SPEED_HIGH) {
> +        dev->dev.speedmask |= USB_SPEED_MASK_FULL;
> +    }
>       dev->device_info = *device_connect;
>
>       if (usbredir_check_filter(dev)) {
> @@ -1172,7 +1175,14 @@ static void usbredir_ep_info(void *priv,
>           case usb_redir_type_invalid:
>               break;
>           case usb_redir_type_iso:
> +            dev->dev.speedmask &= ~USB_SPEED_MASK_FULL;
> +            /* Fall through */
>           case usb_redir_type_interrupt:
> +            if (!usbredirparser_peer_has_cap(dev->parser,
> +                                     usb_redir_cap_ep_info_max_packet_size) ||
> +                ep_info->max_packet_size[i] > 64) {
> +                dev->dev.speedmask &= ~USB_SPEED_MASK_FULL;
> +            }
>               if (dev->endpoint[i].interval == 0) {
>                   ERROR("Received 0 interval for isoc or irq endpoint\n");
>                   usbredir_device_disconnect(dev);
>

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17  9:08 ` Hans de Goede
@ 2012-09-17  9:18   ` Jan Kiszka
  2012-09-17 14:24     ` Hans de Goede
  2012-09-22  9:29   ` [Qemu-devel] [PATCH v2] " Jan Kiszka
  1 sibling, 1 reply; 17+ messages in thread
From: Jan Kiszka @ 2012-09-17  9:18 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

[-- Attachment #1: Type: text/plain, Size: 2444 bytes --]

On 2012-09-17 11:08, Hans de Goede wrote:
> Hi,
> 
> On 09/15/2012 06:27 PM, Jan Kiszka wrote:
>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>
>> This follows the logic of host-linux: If a 2.0 device has no ISO
>> endpoint and no interrupt endpoint with a packet size > 64, we can
>> attach it also to an 1.1 host controller. In case the redir server does
>> not report endpoint sizes, play safe and remove the 1.1 compatibility as
>> well.
>>
>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> 
> Interesting thanks for the patch. I like the approach you took (simple
> code),
> but unfortunately it won't work, if you look at usbredir_device_connect(),
> where you do the dev->dev.speedmask |= USB_SPEED_MASK_FULL, it also
> actually attaches the device to the controller, from which point on the
> guest will see the device.
> 
> What happens on the wire is that the usbredir-host sends (in order):
> -ep_info + interface_info
> -device_connect message
> 
> So your clearing of the speed-mask will never trigger, unless ep-info
> gets repeated later (which it does under certain circumstances).

Hmm, what a pity...

> 
> I suggest instead changing the code to set a "fullspeed_compatible" flag
> in struct USBRedirDevice from usbredir_device_disconnect(), clear that
> flag from usbredir_ep_info and use it to add to the mask in
> usbredir_device_connect().

OK.

> 
> ###
> 
> Another issue is what happens if a device "grows" incompatible endpoints
> after being attached, ie a webcam could have no isoc endpoints in alt
> setting 0, and then grow an isoc endpoint on a set_interface. So we
> would need a check for a device becoming not fullspeed compat while
> being attached at fullspeed in usbredir_ep_info(), and then call
> usbredir_reject_device() when this happens.

...and this patch started so simple. OK.

> 
> Although not pretty I'm ok with this, since I actually want to add
> similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
> to work with ehci or uhci controllers :)

Great, that would have been my next question, but I don't have hardware
for that around yet.

BTW, I'm facing several incompatibilities with passed-through CDC/ACM
devices (e.g. a Galaxy S2), independent of my patch. Both host-linux and
redir doesn't allow to use them properly but show different symptoms.
Need to analyze and report once time permits.

Jan



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17  9:18   ` Jan Kiszka
@ 2012-09-17 14:24     ` Hans de Goede
  2012-09-17 16:22       ` Jan Kiszka
  2012-09-18 21:18       ` Anthony Liguori
  0 siblings, 2 replies; 17+ messages in thread
From: Hans de Goede @ 2012-09-17 14:24 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 09/17/2012 11:18 AM, Jan Kiszka wrote:
> On 2012-09-17 11:08, Hans de Goede wrote:

<snip>

>> Although not pretty I'm ok with this, since I actually want to add
>> similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
>> to work with ehci or uhci controllers :)
>
> Great, that would have been my next question, but I don't have hardware
> for that around yet.

I do have hardware for that around, so once you've respun your patch to
address the issues discussed, then that will give me a nice basis to
add usb-3 usb-stick to ehci-controller redirection :)

> BTW, I'm facing several incompatibilities with passed-through CDC/ACM
> devices (e.g. a Galaxy S2), independent of my patch. Both host-linux and
> redir doesn't allow to use them properly but show different symptoms.
> Need to analyze and report once time permits.

Hmm, there is (was) one know issues with these devices, which has been fixed
in usbredir, so first of all make sure that the usbredir on your spice-client
/ usbredirserver, has this patch:
http://cgit.freedesktop.org/spice/usbredir/commit/?id=7783d3db61083bbf7f61b1ea8608c666b4c6a1dd

If that does not work, add the debug parameter to the usb-redir device, set it
to 4, collect logs of trying to redirect the device and send me the logs
please, ie:
-device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4

Also be aware that usb-redir relies on chardev flowcontrol working,
which it does not upstream! See for example here for the chardev flow
control patch set which RHEL / Fedora carry:
http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50

And then the first 13 patches after: "Merge tag 'v1.2.0'"

Oh, and also, if you're running qemu git master, make sure you've:
http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17 14:24     ` Hans de Goede
@ 2012-09-17 16:22       ` Jan Kiszka
  2012-09-18  9:41         ` Hans de Goede
  2012-09-18 21:18       ` Anthony Liguori
  1 sibling, 1 reply; 17+ messages in thread
From: Jan Kiszka @ 2012-09-17 16:22 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

On 2012-09-17 16:24, Hans de Goede wrote:
> Hi,
> 
> On 09/17/2012 11:18 AM, Jan Kiszka wrote:
>> On 2012-09-17 11:08, Hans de Goede wrote:
> 
> <snip>
> 
>>> Although not pretty I'm ok with this, since I actually want to add
>>> similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
>>> to work with ehci or uhci controllers :)
>>
>> Great, that would have been my next question, but I don't have hardware
>> for that around yet.
> 
> I do have hardware for that around, so once you've respun your patch to
> address the issues discussed, then that will give me a nice basis to
> add usb-3 usb-stick to ehci-controller redirection :)
> 
>> BTW, I'm facing several incompatibilities with passed-through CDC/ACM
>> devices (e.g. a Galaxy S2), independent of my patch. Both host-linux and
>> redir doesn't allow to use them properly but show different symptoms.
>> Need to analyze and report once time permits.
> 
> Hmm, there is (was) one know issues with these devices, which has been
> fixed
> in usbredir, so first of all make sure that the usbredir on your
> spice-client
> / usbredirserver, has this patch:
> http://cgit.freedesktop.org/spice/usbredir/commit/?id=7783d3db61083bbf7f61b1ea8608c666b4c6a1dd
> 

Included (I'm using 0.5 or even git head).

> 
> If that does not work, add the debug parameter to the usb-redir device,
> set it
> to 4, collect logs of trying to redirect the device and send me the logs
> please, ie:
> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
> 
> Also be aware that usb-redir relies on chardev flowcontrol working,
> which it does not upstream! See for example here for the chardev flow
> control patch set which RHEL / Fedora carry:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
> 
> 
> And then the first 13 patches after: "Merge tag 'v1.2.0'"
> 
> Oh, and also, if you're running qemu git master, make sure you've:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
> 

I used qemu-kvm-1.2-usbredir^ (the last commit is apparently broken -
copy&paste bug?). I'm getting this right after typing cat /dev/ACM0 in
the guest. It's an endless stream, and so is the output in the guest
although there should be nothing to dump (that's the proper behaviour on
the host).

qemu-system-x86_64: usb-redir: ctrl-out type 0x21 req 0x22 val 0x3 index
1 len 0 id 933360000

qemu-system-x86_64: usb-redir: ctrl-in status 0 len 0 id 933360000

qemu-system-x86_64: usb-redir: interrupt recv started ep 83

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933359872

qemu-system-x86_64: usb-redir: interrupt recv status 0 ep 83 id 0

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 9 id 933359872

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360192

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360192

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360320

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362688

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362688

qemu-system-x86_64: usb-redir: interrupt-in status 0 ep 83 len 10 id 0

qemu-system-x86_64: usb-redir: interrupt-token-in ep 83 status 0 len 10

qemu-system-x86_64: usb-redir: interrupt-in status 0 ep 83 len 10 id 1

qemu-system-x86_64: usb-redir: interrupt-token-in ep 83 status 0 len 10

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 13 id 933360320

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360448

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360448

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360576

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 21 id 933360576

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360832

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362624

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 27 id 933360832

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361088

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933361088

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361216

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933361216

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361344

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 27 id 933361344

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361600

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361408

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361408

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362176

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362816

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 26 id 933361600

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361728

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933361728

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361856

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 6 id 933361856

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361984

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933361984

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933362112

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933361216

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 1 id 933361408

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933361216

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 1 id 933361408

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360896

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 27 id 933362112

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360000

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933359872

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933359808

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933359808

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362240

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933359872

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360192

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360192

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360320

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933359808

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933359808

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361216

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933360320

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360448

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933360448

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360576

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363008

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363072

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933360576

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933362752

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933360832

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360192

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360448

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360192

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360448

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360704

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361984

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933360832

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933362880

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933362880

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361088

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360448

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363264

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363200

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360448

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933363136

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 32 id 933361088

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933362560

qemu-system-x86_64: usb-redir: bulk-in status 0 ep 85 len 0 id 933362560

qemu-system-x86_64: usb-redir: bulk-out ep 85 len 512 id 933361344

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360192

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360640

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362624

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362880

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360000

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361664

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361472

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362304

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933361152

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933360960

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362368

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362752

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362944

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362432

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933362496

qemu-system-x86_64: usb-redir: bulk-out ep 04 len 2 id 933363200


Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SDP-DE
Corporate Competence Center Embedded Linux

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17 16:22       ` Jan Kiszka
@ 2012-09-18  9:41         ` Hans de Goede
  2012-09-21 11:49           ` Jan Kiszka
  0 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2012-09-18  9:41 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 09/17/2012 06:22 PM, Jan Kiszka wrote:
>> If that does not work, add the debug parameter to the usb-redir device,
>> set it
>> to 4, collect logs of trying to redirect the device and send me the logs
>> please, ie:
>> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>>
>> Also be aware that usb-redir relies on chardev flowcontrol working,
>> which it does not upstream! See for example here for the chardev flow
>> control patch set which RHEL / Fedora carry:
>> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
>>
>>
>> And then the first 13 patches after: "Merge tag 'v1.2.0'"
>>
>> Oh, and also, if you're running qemu git master, make sure you've:
>> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
>>
>
> I used qemu-kvm-1.2-usbredir^ (the last commit is apparently broken -
> copy&paste bug?).

Yeah, that has been fixed now.

> I'm getting this right after typing cat /dev/ACM0 in
> the guest. It's an endless stream, and so is the output in the guest
> although there should be nothing to dump (that's the proper behaviour on
> the host).

Hmm, can you try commenting out line 1608 of hw/usb/redirect.c:
             usb_ep->pipeline = true;

And see if that helps. If it does not help, please bump the debug level to 5
(this will also make it log packet contents), and then generate another log, and
then it is time to dive into the ACM protocol to see what is happening...

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17 14:24     ` Hans de Goede
  2012-09-17 16:22       ` Jan Kiszka
@ 2012-09-18 21:18       ` Anthony Liguori
  2012-09-19  9:20         ` Hans de Goede
  1 sibling, 1 reply; 17+ messages in thread
From: Anthony Liguori @ 2012-09-18 21:18 UTC (permalink / raw)
  To: Hans de Goede, Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hans de Goede <hdegoede@redhat.com> writes:

> Hi,
>
> On 09/17/2012 11:18 AM, Jan Kiszka wrote:
>> On 2012-09-17 11:08, Hans de Goede wrote:
>
> <snip>
>
>>> Although not pretty I'm ok with this, since I actually want to add
>>> similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
>>> to work with ehci or uhci controllers :)
>>
>> Great, that would have been my next question, but I don't have hardware
>> for that around yet.
>
> I do have hardware for that around, so once you've respun your patch to
> address the issues discussed, then that will give me a nice basis to
> add usb-3 usb-stick to ehci-controller redirection :)
>
>> BTW, I'm facing several incompatibilities with passed-through CDC/ACM
>> devices (e.g. a Galaxy S2), independent of my patch. Both host-linux and
>> redir doesn't allow to use them properly but show different symptoms.
>> Need to analyze and report once time permits.
>
> Hmm, there is (was) one know issues with these devices, which has been fixed
> in usbredir, so first of all make sure that the usbredir on your spice-client
> / usbredirserver, has this patch:
> http://cgit.freedesktop.org/spice/usbredir/commit/?id=7783d3db61083bbf7f61b1ea8608c666b4c6a1dd
>
> If that does not work, add the debug parameter to the usb-redir device, set it
> to 4, collect logs of trying to redirect the device and send me the logs
> please, ie:
> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>
> Also be aware that usb-redir relies on chardev flowcontrol working,
> which it does not upstream! See for example here for the chardev flow
> control patch set which RHEL / Fedora carry:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50

Those patches are garbage.

Are you saying that usb-redir doesn't work in qemu.git?  So why are we
even carrying it?

Regards,

Anthony Liguori

>
> And then the first 13 patches after: "Merge tag 'v1.2.0'"
>
> Oh, and also, if you're running qemu git master, make sure you've:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
>
> Regards,
>
> Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-18 21:18       ` Anthony Liguori
@ 2012-09-19  9:20         ` Hans de Goede
  0 siblings, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2012-09-19  9:20 UTC (permalink / raw)
  To: Anthony Liguori; +Cc: Jan Kiszka, qemu-devel, Gerd Hoffmann

Hi,

On 09/18/2012 11:18 PM, Anthony Liguori wrote:
> Hans de Goede <hdegoede@redhat.com> writes:
>
>> Hi,
>>
>> On 09/17/2012 11:18 AM, Jan Kiszka wrote:
>>> On 2012-09-17 11:08, Hans de Goede wrote:
>>
>> <snip>
>>
>>>> Although not pretty I'm ok with this, since I actually want to add
>>>> similar code to allow usb-3 (superspeed) devices like a usb-3 usb-stick
>>>> to work with ehci or uhci controllers :)
>>>
>>> Great, that would have been my next question, but I don't have hardware
>>> for that around yet.
>>
>> I do have hardware for that around, so once you've respun your patch to
>> address the issues discussed, then that will give me a nice basis to
>> add usb-3 usb-stick to ehci-controller redirection :)
>>
>>> BTW, I'm facing several incompatibilities with passed-through CDC/ACM
>>> devices (e.g. a Galaxy S2), independent of my patch. Both host-linux and
>>> redir doesn't allow to use them properly but show different symptoms.
>>> Need to analyze and report once time permits.
>>
>> Hmm, there is (was) one know issues with these devices, which has been fixed
>> in usbredir, so first of all make sure that the usbredir on your spice-client
>> / usbredirserver, has this patch:
>> http://cgit.freedesktop.org/spice/usbredir/commit/?id=7783d3db61083bbf7f61b1ea8608c666b4c6a1dd
>>
>> If that does not work, add the debug parameter to the usb-redir device, set it
>> to 4, collect logs of trying to redirect the device and send me the logs
>> please, ie:
>> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>>
>> Also be aware that usb-redir relies on chardev flowcontrol working,
>> which it does not upstream! See for example here for the chardev flow
>> control patch set which RHEL / Fedora carry:
>> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
>
> Those patches are garbage.

<sigh, very very deep sigh>

No they are not garbage. They:

1) Fix a real issue, which is independent of spice / usb-redir but happens to be
more easily triggerable with them. Note that the original set was developed to
fix a bug which did not involve either!

2) Are disliked by you because they build upon the existing not pretty chardev
code. We all agree that needs a rewrite. But that is not a valid reason to
keep this perfectly fine patchset out of qemu master for years now!

3) You keep saying they are "racy", but you've never given a simple step by
step thread 1 does foo, thread 2 does bar replay of such a theoretical race.

4) Have caused no issues in almost 2 years of deployment in the field in both
RHEL and Fedora.

5) Are kept out of master by you for no valid reasons, you seem to use them
as a tool to strongarm people into rewriting the qemu chardev layer. Well it
seems that no one is biting because of -ENOTIME, so can we now please get
these included, after almost 2 years since their first posting ?

> Are you saying that usb-redir doesn't work in qemu.git?  So why are we
> even carrying it?

It works just as well as virtio-console or any other chardev frontend, any chardev
frontent can currently trigger asserts by writing data faster then the backend
can handle. This is just more easily triggerable with USB trafic then with a
serial console.

The original bug-report this patch set once was written for was about virtio-console
and is dated 2010-08-05 !

So why are we even carrying virtio-console ?

Regards,

Hans

p.s.

Note that I'm *not* the original author of these patches.

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-18  9:41         ` Hans de Goede
@ 2012-09-21 11:49           ` Jan Kiszka
  2012-09-21 12:21             ` Hans de Goede
  0 siblings, 1 reply; 17+ messages in thread
From: Jan Kiszka @ 2012-09-21 11:49 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

On 2012-09-18 11:41, Hans de Goede wrote:
> Hi,
> 
> On 09/17/2012 06:22 PM, Jan Kiszka wrote:
>>> If that does not work, add the debug parameter to the usb-redir device,
>>> set it
>>> to 4, collect logs of trying to redirect the device and send me the logs
>>> please, ie:
>>> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>>>
>>> Also be aware that usb-redir relies on chardev flowcontrol working,
>>> which it does not upstream! See for example here for the chardev flow
>>> control patch set which RHEL / Fedora carry:
>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
>>>
>>>
>>> And then the first 13 patches after: "Merge tag 'v1.2.0'"
>>>
>>> Oh, and also, if you're running qemu git master, make sure you've:
>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
>>>
>>
>> I used qemu-kvm-1.2-usbredir^ (the last commit is apparently broken -
>> copy&paste bug?).
> 
> Yeah, that has been fixed now.
> 
>> I'm getting this right after typing cat /dev/ACM0 in
>> the guest. It's an endless stream, and so is the output in the guest
>> although there should be nothing to dump (that's the proper behaviour on
>> the host).
> 
> Hmm, can you try commenting out line 1608 of hw/usb/redirect.c:
>              usb_ep->pipeline = true;
> 
> And see if that helps. If it does not help, please bump the debug level to 5
> (this will also make it log packet contents), and then generate another log, and
> then it is time to dive into the ACM protocol to see what is happening...

As it looks like now, I was just using the wrong test on the guest side.
Retried this morning briefly with a terminal program, and it was all
fine, even when forwarding from host-ehci to guest-uhci (with my broken
patch), even when using current QEMU git head. Sorry for the noise

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SDP-DE
Corporate Competence Center Embedded Linux

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-21 11:49           ` Jan Kiszka
@ 2012-09-21 12:21             ` Hans de Goede
  2012-09-21 12:25               ` Jan Kiszka
  0 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2012-09-21 12:21 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 09/21/2012 01:49 PM, Jan Kiszka wrote:
> On 2012-09-18 11:41, Hans de Goede wrote:
>> Hi,
>>
>> On 09/17/2012 06:22 PM, Jan Kiszka wrote:
>>>> If that does not work, add the debug parameter to the usb-redir device,
>>>> set it
>>>> to 4, collect logs of trying to redirect the device and send me the logs
>>>> please, ie:
>>>> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>>>>
>>>> Also be aware that usb-redir relies on chardev flowcontrol working,
>>>> which it does not upstream! See for example here for the chardev flow
>>>> control patch set which RHEL / Fedora carry:
>>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
>>>>
>>>>
>>>> And then the first 13 patches after: "Merge tag 'v1.2.0'"
>>>>
>>>> Oh, and also, if you're running qemu git master, make sure you've:
>>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
>>>>
>>>
>>> I used qemu-kvm-1.2-usbredir^ (the last commit is apparently broken -
>>> copy&paste bug?).
>>
>> Yeah, that has been fixed now.
>>
>>> I'm getting this right after typing cat /dev/ACM0 in
>>> the guest. It's an endless stream, and so is the output in the guest
>>> although there should be nothing to dump (that's the proper behaviour on
>>> the host).
>>
>> Hmm, can you try commenting out line 1608 of hw/usb/redirect.c:
>>               usb_ep->pipeline = true;
>>
>> And see if that helps. If it does not help, please bump the debug level to 5
>> (this will also make it log packet contents), and then generate another log, and
>> then it is time to dive into the ACM protocol to see what is happening...
>
> As it looks like now, I was just using the wrong test on the guest side.
> Retried this morning briefly with a terminal program, and it was all
> fine, even when forwarding from host-ehci to guest-uhci (with my broken
> patch), even when using current QEMU git head. Sorry for the noise

Ok, so to be clear: this is solved now, right ?

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-21 12:21             ` Hans de Goede
@ 2012-09-21 12:25               ` Jan Kiszka
  0 siblings, 0 replies; 17+ messages in thread
From: Jan Kiszka @ 2012-09-21 12:25 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

On 2012-09-21 14:21, Hans de Goede wrote:
> Hi,
> 
> On 09/21/2012 01:49 PM, Jan Kiszka wrote:
>> On 2012-09-18 11:41, Hans de Goede wrote:
>>> Hi,
>>>
>>> On 09/17/2012 06:22 PM, Jan Kiszka wrote:
>>>>> If that does not work, add the debug parameter to the usb-redir device,
>>>>> set it
>>>>> to 4, collect logs of trying to redirect the device and send me the logs
>>>>> please, ie:
>>>>> -device usb-redir,chardev=usbredirchardev1,id=usbredirdev1,debug=4
>>>>>
>>>>> Also be aware that usb-redir relies on chardev flowcontrol working,
>>>>> which it does not upstream! See for example here for the chardev flow
>>>>> control patch set which RHEL / Fedora carry:
>>>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/log/?h=qemu-kvm-1.2-usbredir&ofs=50
>>>>>
>>>>>
>>>>> And then the first 13 patches after: "Merge tag 'v1.2.0'"
>>>>>
>>>>> Oh, and also, if you're running qemu git master, make sure you've:
>>>>> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?id=81e34f5973d8d6a1ef998a50c4a4bf66abb3b56b
>>>>>
>>>>
>>>> I used qemu-kvm-1.2-usbredir^ (the last commit is apparently broken -
>>>> copy&paste bug?).
>>>
>>> Yeah, that has been fixed now.
>>>
>>>> I'm getting this right after typing cat /dev/ACM0 in
>>>> the guest. It's an endless stream, and so is the output in the guest
>>>> although there should be nothing to dump (that's the proper behaviour on
>>>> the host).
>>>
>>> Hmm, can you try commenting out line 1608 of hw/usb/redirect.c:
>>>               usb_ep->pipeline = true;
>>>
>>> And see if that helps. If it does not help, please bump the debug level to 5
>>> (this will also make it log packet contents), and then generate another log, and
>>> then it is time to dive into the ACM protocol to see what is happening...
>>
>> As it looks like now, I was just using the wrong test on the guest side.
>> Retried this morning briefly with a terminal program, and it was all
>> fine, even when forwarding from host-ehci to guest-uhci (with my broken
>> patch), even when using current QEMU git head. Sorry for the noise
> 
> Ok, so to be clear: this is solved now, right ?

Let's consider it solved until I find a real bug. ;)

Will send some update for the speed matching patch on the weekend, probably.

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SDP-DE
Corporate Competence Center Embedded Linux

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [Qemu-devel] [PATCH v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-17  9:08 ` Hans de Goede
  2012-09-17  9:18   ` Jan Kiszka
@ 2012-09-22  9:29   ` Jan Kiszka
  2012-10-08 17:36     ` Jan Kiszka
  2012-10-08 23:05     ` [Qemu-devel] [v2] " Hans de Goede
  1 sibling, 2 replies; 17+ messages in thread
From: Jan Kiszka @ 2012-09-22  9:29 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

From: Jan Kiszka <jan.kiszka@siemens.com>

This follows the logic of host-linux: If a 2.0 device has no ISO
endpoint and no interrupt endpoint with a packet size > 64, we can
attach it also to an 1.1 host controller. In case the redir server does
not report endpoint sizes, play safe and remove the 1.1 compatibility as
well. Moreover, if we detect a conflicting change in the configuration
after the device was already attached, it will be disconnected
immediately.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---

Changes in v2:
 - fix incompatibility marking via introduction of compatible_speedmask
 - disconnect device if incompatibility is detected when already
   attached

 hw/usb/redirect.c |   24 +++++++++++++++++++++++-
 1 files changed, 23 insertions(+), 1 deletions(-)

diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
index b10241a..2099ea4 100644
--- a/hw/usb/redirect.c
+++ b/hw/usb/redirect.c
@@ -105,6 +105,7 @@ struct USBRedirDevice {
     struct usb_redir_interface_info_header interface_info;
     struct usbredirfilter_rule *filter_rules;
     int filter_rules_count;
+    int compatible_speedmask;
 };
 
 static void usbredir_hello(void *priv, struct usb_redir_hello_header *h);
@@ -1037,6 +1038,9 @@ static int usbredir_initfn(USBDevice *udev)
     /* We'll do the attach once we receive the speed from the usb-host */
     udev->auto_attach = 0;
 
+    /* Will be cleared during setup when we find conflicts */
+    dev->compatible_speedmask = USB_SPEED_MASK_FULL;
+
     /* Let the backend know we are ready */
     qemu_chr_fe_open(dev->cs);
     qemu_chr_add_handlers(dev->cs, usbredir_chardev_can_read,
@@ -1177,10 +1181,12 @@ static void usbredir_device_connect(void *priv,
     case usb_redir_speed_low:
         speed = "low speed";
         dev->dev.speed = USB_SPEED_LOW;
+        dev->dev.speedmask = 0;
         break;
     case usb_redir_speed_full:
         speed = "full speed";
         dev->dev.speed = USB_SPEED_FULL;
+        dev->dev.speedmask = 0;
         break;
     case usb_redir_speed_high:
         speed = "high speed";
@@ -1189,6 +1195,7 @@ static void usbredir_device_connect(void *priv,
     case usb_redir_speed_super:
         speed = "super speed";
         dev->dev.speed = USB_SPEED_SUPER;
+        dev->dev.speedmask = 0;
         break;
     default:
         speed = "unknown speed";
@@ -1210,7 +1217,7 @@ static void usbredir_device_connect(void *priv,
              device_connect->device_class);
     }
 
-    dev->dev.speedmask = (1 << dev->dev.speed);
+    dev->dev.speedmask = (1 << dev->dev.speed) | dev->compatible_speedmask;
     dev->device_info = *device_connect;
 
     if (usbredir_check_filter(dev)) {
@@ -1271,6 +1278,14 @@ static void usbredir_interface_info(void *priv,
     }
 }
 
+static void usbredir_mark_fullspeed_incompatible(USBRedirDevice *dev)
+{
+    dev->compatible_speedmask &= ~USB_SPEED_MASK_FULL;
+    if (dev->dev.attached && dev->dev.port->dev->speed == USB_SPEED_FULL) {
+        usbredir_device_disconnect(dev);
+    }
+}
+
 static void usbredir_ep_info(void *priv,
     struct usb_redir_ep_info_header *ep_info)
 {
@@ -1286,7 +1301,14 @@ static void usbredir_ep_info(void *priv,
         case usb_redir_type_invalid:
             break;
         case usb_redir_type_iso:
+            usbredir_mark_fullspeed_incompatible(dev);
+            /* Fall through */
         case usb_redir_type_interrupt:
+            if (!usbredirparser_peer_has_cap(dev->parser,
+                                     usb_redir_cap_ep_info_max_packet_size) ||
+                ep_info->max_packet_size[i] > 64) {
+                usbredir_mark_fullspeed_incompatible(dev);
+            }
             if (dev->endpoint[i].interval == 0) {
                 ERROR("Received 0 interval for isoc or irq endpoint\n");
                 usbredir_device_disconnect(dev);
-- 
1.7.3.4

^ permalink raw reply related	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [PATCH v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-22  9:29   ` [Qemu-devel] [PATCH v2] " Jan Kiszka
@ 2012-10-08 17:36     ` Jan Kiszka
  2012-10-08 23:05     ` [Qemu-devel] [v2] " Hans de Goede
  1 sibling, 0 replies; 17+ messages in thread
From: Jan Kiszka @ 2012-10-08 17:36 UTC (permalink / raw)
  To: Hans de Goede; +Cc: qemu-devel, Gerd Hoffmann

On 2012-09-22 11:29, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
> 
> This follows the logic of host-linux: If a 2.0 device has no ISO
> endpoint and no interrupt endpoint with a packet size > 64, we can
> attach it also to an 1.1 host controller. In case the redir server does
> not report endpoint sizes, play safe and remove the 1.1 compatibility as
> well. Moreover, if we detect a conflicting change in the configuration
> after the device was already attached, it will be disconnected
> immediately.
> 
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
> 
> Changes in v2:
>  - fix incompatibility marking via introduction of compatible_speedmask
>  - disconnect device if incompatibility is detected when already
>    attached
> 
>  hw/usb/redirect.c |   24 +++++++++++++++++++++++-
>  1 files changed, 23 insertions(+), 1 deletions(-)
> 
> diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
> index b10241a..2099ea4 100644
> --- a/hw/usb/redirect.c
> +++ b/hw/usb/redirect.c
> @@ -105,6 +105,7 @@ struct USBRedirDevice {
>      struct usb_redir_interface_info_header interface_info;
>      struct usbredirfilter_rule *filter_rules;
>      int filter_rules_count;
> +    int compatible_speedmask;
>  };
>  
>  static void usbredir_hello(void *priv, struct usb_redir_hello_header *h);
> @@ -1037,6 +1038,9 @@ static int usbredir_initfn(USBDevice *udev)
>      /* We'll do the attach once we receive the speed from the usb-host */
>      udev->auto_attach = 0;
>  
> +    /* Will be cleared during setup when we find conflicts */
> +    dev->compatible_speedmask = USB_SPEED_MASK_FULL;
> +
>      /* Let the backend know we are ready */
>      qemu_chr_fe_open(dev->cs);
>      qemu_chr_add_handlers(dev->cs, usbredir_chardev_can_read,
> @@ -1177,10 +1181,12 @@ static void usbredir_device_connect(void *priv,
>      case usb_redir_speed_low:
>          speed = "low speed";
>          dev->dev.speed = USB_SPEED_LOW;
> +        dev->dev.speedmask = 0;
>          break;
>      case usb_redir_speed_full:
>          speed = "full speed";
>          dev->dev.speed = USB_SPEED_FULL;
> +        dev->dev.speedmask = 0;
>          break;
>      case usb_redir_speed_high:
>          speed = "high speed";
> @@ -1189,6 +1195,7 @@ static void usbredir_device_connect(void *priv,
>      case usb_redir_speed_super:
>          speed = "super speed";
>          dev->dev.speed = USB_SPEED_SUPER;
> +        dev->dev.speedmask = 0;
>          break;
>      default:
>          speed = "unknown speed";
> @@ -1210,7 +1217,7 @@ static void usbredir_device_connect(void *priv,
>               device_connect->device_class);
>      }
>  
> -    dev->dev.speedmask = (1 << dev->dev.speed);
> +    dev->dev.speedmask = (1 << dev->dev.speed) | dev->compatible_speedmask;
>      dev->device_info = *device_connect;
>  
>      if (usbredir_check_filter(dev)) {
> @@ -1271,6 +1278,14 @@ static void usbredir_interface_info(void *priv,
>      }
>  }
>  
> +static void usbredir_mark_fullspeed_incompatible(USBRedirDevice *dev)
> +{
> +    dev->compatible_speedmask &= ~USB_SPEED_MASK_FULL;
> +    if (dev->dev.attached && dev->dev.port->dev->speed == USB_SPEED_FULL) {
> +        usbredir_device_disconnect(dev);
> +    }
> +}
> +
>  static void usbredir_ep_info(void *priv,
>      struct usb_redir_ep_info_header *ep_info)
>  {
> @@ -1286,7 +1301,14 @@ static void usbredir_ep_info(void *priv,
>          case usb_redir_type_invalid:
>              break;
>          case usb_redir_type_iso:
> +            usbredir_mark_fullspeed_incompatible(dev);
> +            /* Fall through */
>          case usb_redir_type_interrupt:
> +            if (!usbredirparser_peer_has_cap(dev->parser,
> +                                     usb_redir_cap_ep_info_max_packet_size) ||
> +                ep_info->max_packet_size[i] > 64) {
> +                usbredir_mark_fullspeed_incompatible(dev);
> +            }
>              if (dev->endpoint[i].interval == 0) {
>                  ERROR("Received 0 interval for isoc or irq endpoint\n");
>                  usbredir_device_disconnect(dev);
> 

Any comments? Or already queued somewhere?

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SDP-DE
Corporate Competence Center Embedded Linux

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-09-22  9:29   ` [Qemu-devel] [PATCH v2] " Jan Kiszka
  2012-10-08 17:36     ` Jan Kiszka
@ 2012-10-08 23:05     ` Hans de Goede
  2012-10-09  8:38       ` Hans de Goede
  1 sibling, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2012-10-08 23:05 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

Some comments inline, I've a version with all the comments fixed here:
http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=5e342d2d2186757cc41b2f834e3503cf10e98c2b

On 09/22/2012 01:29 AM, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
>
> This follows the logic of host-linux: If a 2.0 device has no ISO
> endpoint and no interrupt endpoint with a packet size > 64, we can
> attach it also to an 1.1 host controller. In case the redir server does
> not report endpoint sizes, play safe and remove the 1.1 compatibility as
> well. Moreover, if we detect a conflicting change in the configuration
> after the device was already attached, it will be disconnected
> immediately.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>
> ---
> Changes in v2:
>   - fix incompatibility marking via introduction of compatible_speedmask
>   - disconnect device if incompatibility is detected when already
>     attached
>
>   hw/usb/redirect.c |   24 +++++++++++++++++++++++-
>   1 files changed, 23 insertions(+), 1 deletions(-)
>
> diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
> index b10241a..2099ea4 100644
> --- a/hw/usb/redirect.c
> +++ b/hw/usb/redirect.c
> @@ -105,6 +105,7 @@ struct USBRedirDevice {
>       struct usb_redir_interface_info_header interface_info;
>       struct usbredirfilter_rule *filter_rules;
>       int filter_rules_count;
> +    int compatible_speedmask;
>   };
>
>   static void usbredir_hello(void *priv, struct usb_redir_hello_header *h);
> @@ -1037,6 +1038,9 @@ static int usbredir_initfn(USBDevice *udev)
>       /* We'll do the attach once we receive the speed from the usb-host */
>       udev->auto_attach = 0;
>
> +    /* Will be cleared during setup when we find conflicts */
> +    dev->compatible_speedmask = USB_SPEED_MASK_FULL;
> +

This needs to be done in disconnect to, as that resets the
device state, as the same usb-redir device may be reused to later
redirect another device.

>       /* Let the backend know we are ready */
>       qemu_chr_fe_open(dev->cs);
>       qemu_chr_add_handlers(dev->cs, usbredir_chardev_can_read,
> @@ -1177,10 +1181,12 @@ static void usbredir_device_connect(void *priv,
>       case usb_redir_speed_low:
>           speed = "low speed";
>           dev->dev.speed = USB_SPEED_LOW;
> +        dev->dev.speedmask = 0;
>           break;
>       case usb_redir_speed_full:
>           speed = "full speed";
>           dev->dev.speed = USB_SPEED_FULL;
> +        dev->dev.speedmask = 0;
>           break;
>       case usb_redir_speed_high:
>           speed = "high speed";
> @@ -1189,6 +1195,7 @@ static void usbredir_device_connect(void *priv,
>       case usb_redir_speed_super:
>           speed = "super speed";
>           dev->dev.speed = USB_SPEED_SUPER;
> +        dev->dev.speedmask = 0;
>           break;
>       default:
>           speed = "unknown speed";

All the above setting to 0 of speedmask are not necessary, as immediately
afterwards we do:

> @@ -1210,7 +1217,7 @@ static void usbredir_device_connect(void *priv,
>                device_connect->device_class);
>       }
>
> -    dev->dev.speedmask = (1 << dev->dev.speed);
> +    dev->dev.speedmask = (1 << dev->dev.speed) | dev->compatible_speedmask;
>       dev->device_info = *device_connect;
>
>       if (usbredir_check_filter(dev)) {
> @@ -1271,6 +1278,14 @@ static void usbredir_interface_info(void *priv,
>       }
>   }
>
> +static void usbredir_mark_fullspeed_incompatible(USBRedirDevice *dev)
> +{
> +    dev->compatible_speedmask &= ~USB_SPEED_MASK_FULL;
> +    if (dev->dev.attached && dev->dev.port->dev->speed == USB_SPEED_FULL) {

This test won't work as for a high speed dev dev->dev.port->dev->speed
== USB_SPEED_HIGH

Also this is not the right place to test, as this gets called from middle in
the loop over the endpoints, so any ep state cleanup usbredir_device_disconnect()
does will then get partially undone by the rest of the loop.

> +        usbredir_device_disconnect(dev);

It would be better to use usbredir_device_reject here, this way the
spice-client / usbredirserver also gets notified of the device getting
disconnected by qemu.

> +    }
> +}
> +
>   static void usbredir_ep_info(void *priv,
>       struct usb_redir_ep_info_header *ep_info)
>   {
> @@ -1286,7 +1301,14 @@ static void usbredir_ep_info(void *priv,
>           case usb_redir_type_invalid:
>               break;
>           case usb_redir_type_iso:
> +            usbredir_mark_fullspeed_incompatible(dev);
> +            /* Fall through */
>           case usb_redir_type_interrupt:
> +            if (!usbredirparser_peer_has_cap(dev->parser,
> +                                     usb_redir_cap_ep_info_max_packet_size) ||
> +                ep_info->max_packet_size[i] > 64) {
> +                usbredir_mark_fullspeed_incompatible(dev);
> +            }
>               if (dev->endpoint[i].interval == 0) {
>                   ERROR("Received 0 interval for isoc or irq endpoint\n");
>                   usbredir_device_disconnect(dev);
>

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-10-08 23:05     ` [Qemu-devel] [v2] " Hans de Goede
@ 2012-10-09  8:38       ` Hans de Goede
  2012-10-09  8:40         ` Gerd Hoffmann
  2012-10-09 10:05         ` Hans de Goede
  0 siblings, 2 replies; 17+ messages in thread
From: Hans de Goede @ 2012-10-09  8:38 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 10/09/2012 01:05 AM, Hans de Goede wrote:
> Hi,
>
> Some comments inline, I've a version with all the comments fixed here:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=5e342d2d2186757cc41b2f834e3503cf10e98c2b
>

And I now also have redirecting super-speed mass-storage devices
to an emulated EHCI controller working:
http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=a6bdb97481c62b42e4106e7670364e61acde8037

Not sure what will happen when we actually get UAS devices in this
scenario though, will need to test, but UAS devices are very hard to
find...

Gerd, do you know where I can buy an UAS device (note a German
source is fine) ?

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-10-09  8:38       ` Hans de Goede
@ 2012-10-09  8:40         ` Gerd Hoffmann
  2012-10-09 10:05         ` Hans de Goede
  1 sibling, 0 replies; 17+ messages in thread
From: Gerd Hoffmann @ 2012-10-09  8:40 UTC (permalink / raw)
  To: Hans de Goede; +Cc: Jan Kiszka, qemu-devel

  Hi,

> Not sure what will happen when we actually get UAS devices in this
> scenario though, will need to test, but UAS devices are very hard to
> find...
> 
> Gerd, do you know where I can buy an UAS device (note a German
> source is fine) ?

No, I only have virtual ones ;)

/me got a usb3 stick, but it is a BOT device.

cheers,
  Gerd

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [Qemu-devel] [v2] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller
  2012-10-09  8:38       ` Hans de Goede
  2012-10-09  8:40         ` Gerd Hoffmann
@ 2012-10-09 10:05         ` Hans de Goede
  1 sibling, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2012-10-09 10:05 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: qemu-devel, Gerd Hoffmann

Hi,

On 10/09/2012 10:38 AM, Hans de Goede wrote:
> Hi,
>
> On 10/09/2012 01:05 AM, Hans de Goede wrote:
>> Hi,
>>
>> Some comments inline, I've a version with all the comments fixed here:
>> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=5e342d2d2186757cc41b2f834e3503cf10e98c2b
>>
>
> And I now also have redirecting super-speed mass-storage devices
> to an emulated EHCI controller working:
> http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=a6bdb97481c62b42e4106e7670364e61acde8037
>

Oops this causes full speed devices to get attached as high speed, not good,
new revision of both patches here:
http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=76231208ad556cceb07f97db349699421d121030
http://cgit.freedesktop.org/~jwrdegoede/qemu/commit/?h=qemu-kvm-1.2-usbredir&id=7a04479a4dd1d810199fbb6d7d36eae6390c36bc

Regards,

Hans

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2012-10-09 10:04 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-15 16:27 [Qemu-devel] [PATCH] usb-redir: Allow to attach USB 2.0 devices to 1.1 host controller Jan Kiszka
2012-09-17  9:08 ` Hans de Goede
2012-09-17  9:18   ` Jan Kiszka
2012-09-17 14:24     ` Hans de Goede
2012-09-17 16:22       ` Jan Kiszka
2012-09-18  9:41         ` Hans de Goede
2012-09-21 11:49           ` Jan Kiszka
2012-09-21 12:21             ` Hans de Goede
2012-09-21 12:25               ` Jan Kiszka
2012-09-18 21:18       ` Anthony Liguori
2012-09-19  9:20         ` Hans de Goede
2012-09-22  9:29   ` [Qemu-devel] [PATCH v2] " Jan Kiszka
2012-10-08 17:36     ` Jan Kiszka
2012-10-08 23:05     ` [Qemu-devel] [v2] " Hans de Goede
2012-10-09  8:38       ` Hans de Goede
2012-10-09  8:40         ` Gerd Hoffmann
2012-10-09 10:05         ` Hans de Goede

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.