Re: Oddity with EP configuration

2017-06-15 Thread Benjamin Herrenschmidt
On Thu, 2017-06-15 at 14:13 +0300, Felipe Balbi wrote: > > I don't have a clear idea of the best approach for this problem.  > > Perhaps Felipe will suggest something. > > I wonder if introducing the idea of "gadget ports" would be better > here. It might be simpler to implement a single gadget

Re: Oddity with EP configuration

2017-06-15 Thread Felipe Balbi
Hi, Alan Stern writes: >> > I think the problem is that you misunderstand how epautoconf is >> > intended to work. >> > >> > I'm not the expert on this stuff -- Felipe is.  Still, as best I >> > understand, the idea is that a gadget driver or the composite core will

Re: Oddity with EP configuration

2017-06-14 Thread Alan Stern
On Thu, 15 Jun 2017, Benjamin Herrenschmidt wrote: > On Wed, 2017-06-14 at 10:19 -0400, Alan Stern wrote: > > I think the problem is that you misunderstand how epautoconf is > > intended to work. > > > > I'm not the expert on this stuff -- Felipe is.  Still, as best I > > understand, the idea

Re: Oddity with EP configuration

2017-06-14 Thread Benjamin Herrenschmidt
On Wed, 2017-06-14 at 10:19 -0400, Alan Stern wrote: > I think the problem is that you misunderstand how epautoconf is > intended to work. > > I'm not the expert on this stuff -- Felipe is.  Still, as best I > understand, the idea is that a gadget driver or the composite core will > attempt to

Re: Oddity with EP configuration

2017-06-14 Thread Alan Stern
On Wed, 14 Jun 2017, Benjamin Herrenschmidt wrote: > On Wed, 2017-06-14 at 10:33 +1000, Benjamin Herrenschmidt wrote: > > On Tue, 2017-06-13 at 15:08 +1000, Benjamin Herrenschmidt wrote: > > > Now, what I observe is that when the mass storage gets bound to the > > > UDC driver: > > > > > >  -

Re: Oddity with EP configuration

2017-06-13 Thread Benjamin Herrenschmidt
On Wed, 2017-06-14 at 12:00 +1000, Benjamin Herrenschmidt wrote: > On Wed, 2017-06-14 at 10:33 +1000, Benjamin Herrenschmidt wrote: > > On Tue, 2017-06-13 at 15:08 +1000, Benjamin Herrenschmidt wrote: > > > Now, what I observe is that when the mass storage gets bound to the > > > UDC driver: > > >

Re: Oddity with EP configuration

2017-06-13 Thread Benjamin Herrenschmidt
On Wed, 2017-06-14 at 10:33 +1000, Benjamin Herrenschmidt wrote: > On Tue, 2017-06-13 at 15:08 +1000, Benjamin Herrenschmidt wrote: > > Now, what I observe is that when the mass storage gets bound to the > > UDC driver: > > > >  - First the endpoints are properly allocated by my match callback, >

Re: Oddity with EP configuration

2017-06-13 Thread Benjamin Herrenschmidt
On Tue, 2017-06-13 at 15:08 +1000, Benjamin Herrenschmidt wrote: > Now, what I observe is that when the mass storage gets bound to the > UDC driver: > >  - First the endpoints are properly allocated by my match callback, > ie, epautoconf is called to allocate EPs to the function. > >  - But

Oddity with EP configuration

2017-06-12 Thread Benjamin Herrenschmidt
So I'm testing my virtual hub drivers. One problem I have is EP allocation. As I mentioned earlier, I have a shared pool of endpoints shared between multiple UDCs. I've added code to "allocate" those EPs from my own udc->match_ep callback. That works ok so far. When binding legacy mass storage,