Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-26 Thread Alan Stern
On Sun, 26 Jul 2015, Petr Cvek wrote: What about higher speeds (not relevant on PXA, but ep_matches() is called from usb_ep_autoconfig_ss() )? According to http://wiki.osdev.org/Universal_Serial_Bus#Maximum_Data_Payload_Size_2 High speed INT endpoint has a maximum data payload 1024

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-26 Thread Robert Baldyga
On 07/26/2015 05:14 PM, Alan Stern wrote: On Sun, 26 Jul 2015, Petr Cvek wrote: What about higher speeds (not relevant on PXA, but ep_matches() is called from usb_ep_autoconfig_ss() )? According to http://wiki.osdev.org/Universal_Serial_Bus#Maximum_Data_Payload_Size_2 High speed INT

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-26 Thread Petr Cvek
On 26.7.2015 17:14, Alan Stern wrote: On Sun, 26 Jul 2015, Petr Cvek wrote: What about higher speeds (not relevant on PXA, but ep_matches() is called from usb_ep_autoconfig_ss() )? According to http://wiki.osdev.org/Universal_Serial_Bus#Maximum_Data_Payload_Size_2 High speed INT

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Robert Jarzmik
Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT endpoint. For my PXA27x machine the original code

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Alan Stern
On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT endpoint. For my PXA27x machine the original code returns BULK EP even with valid INT endpoint definition

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Alan Stern
On Sat, 25 Jul 2015, Petr Cvek wrote: On 25.7.2015 19:04, Robert Jarzmik wrote: Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Alan Stern
On Sat, 25 Jul 2015, Robert Jarzmik wrote: Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Robert Baldyga
Hi, On 07/25/2015 07:04 PM, Robert Jarzmik wrote: Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Petr Cvek
On 25.7.2015 20:08, Robert Baldyga wrote: Let me give you another example : - pxa27x_udc offers 3 endpoints : ep-in, ep-out, ep-iso-in - a gadget driver does : - request an ep-in - request an ep-out - request an ep-in - request an ep-iso-in In that case, the ep-iso-in

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Petr Cvek
On 25.7.2015 19:04, Robert Jarzmik wrote: Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT endpoint.

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Petr Cvek
On 25.7.2015 13:04, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT endpoint. For my PXA27x machine the original code returns BULK EP even with valid INT endpoint definition

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Petr Cvek
On 25.7.2015 23:36, Alan Stern wrote: On Sat, 25 Jul 2015, Petr Cvek wrote: On 25.7.2015 19:04, Robert Jarzmik wrote: Alan Stern st...@rowland.harvard.edu writes: Hi Alan, On Sat, 25 Jul 2015, Robert Jarzmik wrote: Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-25 Thread Robert Jarzmik
Petr Cvek petr.c...@tul.cz writes: On 23.7.2015 21:46, Alan Stern wrote: It seems that it allows using a BULK endpoint for requested INT endpoint. For my PXA27x machine the original code returns BULK EP even with valid INT endpoint definition (because BULK EPs are defined earlier than INT

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-24 Thread Petr Cvek
On 23.7.2015 16:36, Felipe Balbi wrote: Hi, On Thu, Jul 23, 2015 at 06:40:40AM +0200, Petr Cvek wrote: Hello, Is this: case USB_ENDPOINT_XFER_INT: /* Bulk endpoints handle interrupt transfers, * except the toggle-quirky iso-synch kind */

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-24 Thread Petr Cvek
On 23.7.2015 21:46, Alan Stern wrote: On Thu, 23 Jul 2015, Petr Cvek wrote: Hello, Is this: case USB_ENDPOINT_XFER_INT: /* Bulk endpoints handle interrupt transfers, * except the toggle-quirky iso-synch kind */ if

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-23 Thread Alan Stern
On Thu, 23 Jul 2015, Petr Cvek wrote: Hello, Is this: case USB_ENDPOINT_XFER_INT: /* Bulk endpoints handle interrupt transfers, * except the toggle-quirky iso-synch kind */ if (!ep-caps.type_int !ep-caps.type_bulk)

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-23 Thread Felipe Balbi
Hi, On Thu, Jul 23, 2015 at 06:40:40AM +0200, Petr Cvek wrote: Hello, Is this: case USB_ENDPOINT_XFER_INT: /* Bulk endpoints handle interrupt transfers, * except the toggle-quirky iso-synch kind */ if (!ep-caps.type_int

Re: [PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-22 Thread Petr Cvek
Hello, Is this: case USB_ENDPOINT_XFER_INT: /* Bulk endpoints handle interrupt transfers, * except the toggle-quirky iso-synch kind */ if (!ep-caps.type_int !ep-caps.type_bulk) return 0; ... or

[PATCH v3 42/46] usb: gadget: move ep_matches() from epautoconf to udc-core

2015-07-15 Thread Robert Baldyga
Move ep_matches() function to udc-core and rename it to usb_gadget_ep_match_desc(). This function can be used by UDC drivers in 'match_ep' callback to avoid writing lots of repetitive code. Replace all calls of ep_matches() with usb_gadget_ep_match_desc(). Signed-off-by: Robert Baldyga