Re: linux-next build broken for renesas-usb3?

2018-08-15 Thread John Garry
On 10/08/2018 07:24, Felipe Balbi wrote: Hi Yoshihiro, I see Arnd is fixing it here: https://lore.kernel.org/patchwork/patch/974025/ I am not on that thread, so will comment here: > tristate 'Renesas USB3.0 Peripheral controller' > depends on ARCH_RENESAS || COMPILE_TEST > depends o

Re: g_mass_storage performance on partition vs. file

2018-08-15 Thread Martin Hicks
On Fri, Aug 03, 2018 at 12:56:37PM -0400, Alan Stern wrote: > On Fri, 3 Aug 2018, Martin Hicks wrote: > > > > > Hi, > > > > I've run into a huge performance gap between running a g_mass_storage > > gadget with the backing file pointing to a raw partition (/dev/mmcblk1) > > vs. creating a file on

Re: g_mass_storage performance on partition vs. file

2018-08-15 Thread Alan Stern
On Wed, 15 Aug 2018, Martin Hicks wrote: > On Fri, Aug 03, 2018 at 12:56:37PM -0400, Alan Stern wrote: > > On Fri, 3 Aug 2018, Martin Hicks wrote: > > > > > > > > Hi, > > > > > > I've run into a huge performance gap between running a g_mass_storage > > > gadget with the backing file pointing to

Re: usb typec not doing handling in-kernel

2018-08-15 Thread Heikki Krogerus
Hi, On Tue, Aug 14, 2018 at 03:58:31PM +0200, Heiko Stuebner wrote: > Am Montag, 13. August 2018, 15:36:37 CEST schrieb Heikki Krogerus: > > On Mon, Aug 13, 2018 at 12:36:55PM +0200, Heiko Stuebner wrote: > > > I'm currently trying to wrap my head around the new typec subsystem and > > > also how

[PATCH 1/2] USB: yurex: Fix buffer over-read in yurex_write()

2018-08-15 Thread Ben Hutchings
If the written data starts with a digit, yurex_write() tries to parse it as an integer using simple_strtoull(). This requires a null- terminator, and currently there's no guarantee that there is one. (The sample program at https://github.com/NeoCat/YUREX-driver-for-Linux/blob/master/sample/yurex_

[PATCH 2/2] USB: yurex: Check for truncation in yurex_read()

2018-08-15 Thread Ben Hutchings
snprintf() always returns the full length of the string it could have printed, even if it was truncated because the buffer was too small. So in case the counter value is truncated, we will over-read from in_buffer and over-write to the caller's buffer. I don't think it's actually possible for this

Re: [PATCH 1/2] USB: yurex: Fix buffer over-read in yurex_write()

2018-08-15 Thread Jann Horn
On Wed, Aug 15, 2018 at 10:44 PM Ben Hutchings wrote: > > If the written data starts with a digit, yurex_write() tries to parse > it as an integer using simple_strtoull(). This requires a null- > terminator, and currently there's no guarantee that there is one. Oh, good catch. > (The sample pro

Re: [PATCH] Driver for MaxLinear/Exar USB (UART) Serial Adapters

2018-08-15 Thread Patong Yang
Greg, Please see my response inline below. Patong > But there is a bigger problem here: > > > + xrusb_tty_driver = alloc_tty_driver(XRUSB_TTY_MINORS); > > + if (!xrusb_tty_driver) > > + return -ENOMEM; > > Why are you not using the usb serial core here? You need to do that, > no

Re: [PATCH] Driver for MaxLinear/Exar USB (UART) Serial Adapters

2018-08-15 Thread Greg KH
On Wed, Aug 15, 2018 at 10:56:47PM -0700, Patong Yang wrote: > Greg, > > Please see my response inline below. > > Patong > > > But there is a bigger problem here: > > > > > + xrusb_tty_driver = alloc_tty_driver(XRUSB_TTY_MINORS); > > > + if (!xrusb_tty_driver) > > > + return -ENOMEM; >