Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Peter Chen
On Mon, Jun 13, 2016 at 10:37:59AM +0300, Roger Quadros wrote: > On 13/06/16 10:20, Peter Chen wrote: > > On Mon, Jun 13, 2016 at 10:14:31AM +0300, Roger Quadros wrote: > >> On 12/06/16 14:36, Peter Chen wrote: > >>> On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: > > +/*

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Roger Quadros
On 13/06/16 10:20, Peter Chen wrote: > On Mon, Jun 13, 2016 at 10:14:31AM +0300, Roger Quadros wrote: >> On 12/06/16 14:36, Peter Chen wrote: >>> On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: +/** + * usb_otg_add_gadget_udc - adds a new gadget to the udc class driv

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Peter Chen
On Mon, Jun 13, 2016 at 10:14:31AM +0300, Roger Quadros wrote: > On 12/06/16 14:36, Peter Chen wrote: > > On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: > >> > >> +/** > >> + * usb_otg_add_gadget_udc - adds a new gadget to the udc class driver list > >> + * @parent: the parent dev

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Roger Quadros
On 12/06/16 14:36, Peter Chen wrote: > On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: >> >> +/** >> + * usb_otg_add_gadget_udc - adds a new gadget to the udc class driver list >> + * @parent: the parent device to this udc. Usually the controller >> + * driver's device. > > It see

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-12 Thread Peter Chen
On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: > > +/** > + * usb_otg_add_gadget_udc - adds a new gadget to the udc class driver list > + * @parent: the parent device to this udc. Usually the controller > + * driver's device. It seems it should be udc device > +/* udc_lock must

[PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-10 Thread Roger Quadros
The OTG state machine needs a mechanism to start and stop the gadget controller as well as connect/disconnect from the bus. Add usb_gadget_start(), usb_gadget_stop() and usb_gadget_connect_control(). Introduce usb_otg_add_gadget_udc() to allow controller drivers to register a gadget controller tha