Re: starting a new hw driver for gadget support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 27 Jan 2012, Klaus Rudolph wrote:

> Hi Alan,
> 
> > Are you sure you didn't lose a SETUP packet?
> 
> I am not shure in anything in the moment :-) Is that right that a
> setup packet should have a length of 8 so that they could copied to a
> usb_ctrlrequest structure?

Yes.

>  But "my" packet received on Ep0 after
> enumeration has a length of 24 bytes.
> 
> I captured that packet with wireshark:
> 
>   2      82 39.150590   host                  3.0                   USB      URB_CONTROL out
>   3 
>   4 Frame 82: 88 bytes on wire (704 bits), 88 bytes captured (704 bits)
>   5     Arrival Time: Jan 27, 2012 08:34:36.568664000 CET
>   6     Epoch Time: 1327649676.568664000 seconds
>   7     [Time delta from previous captured frame: 0.000080000 seconds]
>   8     [Time delta from previous displayed frame: 0.000080000 seconds]
>   9     [Time since reference or first frame: 39.150590000 seconds]
>  10     Frame Number: 82
>  11     Frame Length: 88 bytes (704 bits)
>  12     Capture Length: 88 bytes (704 bits)
>  13     [Frame is marked: False]
>  14     [Frame is ignored: False]
>  15     [Protocols in frame: usb]
>  16 USB URB
>  17     URB id: 0x00000000e6ce7180
>  18     URB type: URB_SUBMIT ('S')
>  19     URB transfer type: URB_CONTROL out (0x02)
>  20     Endpoint: 0x00
>  21     Device: 3
>  22     URB bus id: 6
>  23     Device setup request: relevant (0)
>  24     Data: present (0)
>  25     URB sec: 1327649676
>  26     URB usec: 568664
>  27     URB status: Operation now in progress (-EINPROGRESS) (-115)
>  28     URB length [bytes]: 24
>  29     Data length [bytes]: 24
>  30     [Response in: 83]
>  31     [bInterfaceClass: CDC_DATA (0x0a)]
>  32     URB setup
>  33         bmRequestType: 0x21
>  34             0... .... = Direction: Host-to-device
>  35             .01. .... = Type: Class (0x01)
>  36             ...0 0001 = Recipient: Interface (0x01)
>  37         bRequest: 0
>  38         wValue: 0x0000
>  39         wIndex: 0
>  40         wLength: 24
>  41     Leftover Capture Data: 020000001800000001000000010000000000000040060000
>  42 
>  43 0000  80 71 ce e6 00 00 00 00 53 02 00 03 06 00 00 00   .q......S.......
>  44 0010  8c 53 22 4f 00 00 00 00 58 ad 08 00 8d ff ff ff   .S"O....X.......
>  45 0020  18 00 00 00 18 00 00 00 21 00 00 00 00 00 18 00   ........!.......
>  46 0030  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00   ................
>  47 0040  02 00 00 00 18 00 00 00 01 00 00 00 01 00 00 00   ................
>  48 0050  00 00 00 00 40 06 00 00                           ....@...

This means that the host thinks it sent an 8-byte SETUP packet followed
by a 24-byte data-OUT packet.

> And as I told you, I have no idea where to put that packet?

Most likely, the SETUP packet _was_ sent and either your hardware or 
your driver lost it.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux