Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-19 Thread Peter Hurley
On 11/19/2015 01:48 AM, Baolin Wang wrote: >> >>> +{ >>> + struct gscons_info *info = gserial_cons.data; >>> + int port_num = gserial_cons.index; >>> + struct usb_request *req; >>> + struct gs_port *port; >>> + struct usb_ep *ep; >>> + >>> + if (port_num >=

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-19 Thread Baolin Wang
On 19 November 2015 at 17:36, Peter Hurley wrote: > On 11/19/2015 01:48 AM, Baolin Wang wrote: >>> +{ + struct gscons_info *info = gserial_cons.data; + int port_num = gserial_cons.index; + struct usb_request *req; + struct gs_port

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-19 Thread Baolin Wang
On 19 November 2015 at 18:28, Peter Hurley wrote: > On 11/18/2015 09:35 PM, Baolin Wang wrote: >> On 18 November 2015 at 23:32, Peter Hurley wrote: >>> Hi Baolin, >>> >>> On 11/16/2015 02:05 AM, Baolin Wang wrote: It dose not work when we

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-19 Thread Peter Hurley
On 11/18/2015 09:35 PM, Baolin Wang wrote: > On 18 November 2015 at 23:32, Peter Hurley wrote: >> Hi Baolin, >> >> On 11/16/2015 02:05 AM, Baolin Wang wrote: >>> It dose not work when we want to use the usb-to-serial port based >>> on one usb gadget as a console. Thus

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Peter Hurley
Hi Baolin, On 11/16/2015 02:05 AM, Baolin Wang wrote: > It dose not work when we want to use the usb-to-serial port based > on one usb gadget as a console. Thus this patch adds the console > initialization to support this request. I have some high level concerns. 1. I would defer registering

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Baolin Wang
On 18 November 2015 at 17:32, Andy Shevchenko wrote: > On Wed, Nov 18, 2015 at 4:15 AM, Baolin Wang wrote: >> On 17 November 2015 at 21:34, Andy Shevchenko >> wrote: >>> On Mon, Nov 16, 2015 at 9:05 AM, Baolin Wang

RE: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread David Laight
From: Baolin Wang > Sent: 18 November 2015 10:45 > On 18 November 2015 at 17:32, Andy Shevchenko > wrote: > > On Wed, Nov 18, 2015 at 4:15 AM, Baolin Wang wrote: > >> On 17 November 2015 at 21:34, Andy Shevchenko >

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Baolin Wang
On 18 November 2015 at 20:05, David Laight wrote: > From: Baolin Wang >> Sent: 18 November 2015 10:45 >> On 18 November 2015 at 17:32, Andy Shevchenko >> wrote: >> > On Wed, Nov 18, 2015 at 4:15 AM, Baolin Wang >> >

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Andy Shevchenko
On Wed, Nov 18, 2015 at 4:15 AM, Baolin Wang wrote: > On 17 November 2015 at 21:34, Andy Shevchenko > wrote: >> On Mon, Nov 16, 2015 at 9:05 AM, Baolin Wang wrote: >>> It dose not work when we want to use the

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Baolin Wang
On 18 November 2015 at 23:32, Peter Hurley wrote: > Hi Baolin, > > On 11/16/2015 02:05 AM, Baolin Wang wrote: >> It dose not work when we want to use the usb-to-serial port based >> on one usb gadget as a console. Thus this patch adds the console >> initialization to

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-18 Thread Baolin Wang
> >> +{ >> + struct gscons_info *info = gserial_cons.data; >> + int port_num = gserial_cons.index; >> + struct usb_request *req; >> + struct gs_port *port; >> + struct usb_ep *ep; >> + >> + if (port_num >= MAX_U_SERIAL_PORTS || port_num < 0) { >> + pr_err("%s:

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-17 Thread Andy Shevchenko
On Mon, Nov 16, 2015 at 9:05 AM, Baolin Wang wrote: > It dose not work when we want to use the usb-to-serial port based > on one usb gadget as a console. Thus this patch adds the console > initialization to support this request. > @@ -79,6 +80,16 @@ > */ > #define

Re: [PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-17 Thread Baolin Wang
On 17 November 2015 at 21:34, Andy Shevchenko wrote: > On Mon, Nov 16, 2015 at 9:05 AM, Baolin Wang wrote: >> It dose not work when we want to use the usb-to-serial port based >> on one usb gadget as a console. Thus this patch adds the console

[PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-11-15 Thread Baolin Wang
It dose not work when we want to use the usb-to-serial port based on one usb gadget as a console. Thus this patch adds the console initialization to support this request. Signed-off-by: Baolin Wang --- drivers/usb/gadget/Kconfig |6 +

[PATCH] usb: gadget: Add the console support for usb-to-serial port

2015-10-22 Thread Baolin Wang
It dose not work when we want to use the usb-to-serial port based on one usb gadget as a console. Thus this patch adds the console initialization to support this request. Signed-off-by: Baolin Wang --- drivers/usb/gadget/Kconfig |6 +