Re: [PATCH v2] usb: core: Warn if an URB's transfer_buffer is on stack

2017-04-24 Thread Clemens Ladisch
Florian Fainelli wrote: > We see a large number of fixes to several drivers to remove the usage of > on-stack buffers feeding into USB transfer functions. Make it easier to spot > the offenders by adding a warning in usb_hcd_map_urb_for_dma() checking that > urb->transfer_buffer is not a stack

Re: [PATCH 1/5 v3] usb: host: add DT bindings for faraday fotg2

2017-04-24 Thread Hans Ulli Kroll
Hi Linus On Fri, 21 Apr 2017, Linus Walleij wrote: > From: Hans Ulli Kroll > > This adds device tree bindings for the Faraday FOTG2 > dual-mode host controller. > > Cc: devicet...@vger.kernel.org > Signed-off-by: Hans Ulli Kroll >

Re: [RFC PATCH v5 1/2] usb: typec: USB Type-C Port Manager (tcpm)

2017-04-24 Thread Mats Karrman
Hello Guenter, Some corrections and suggestions follow. And then of course it would be nice to factor out the alternate mode handling so new mode handlers could be registered as needed :) BR // Mats On 04/22/2017 12:15 AM, Guenter Roeck wrote: From: Guenter Roeck This

Re: [PATCH] usb: typec: Don't prevent using constant typec_mode_desc initializers

2017-04-24 Thread Guenter Roeck
Hi Mats, On Mon, Apr 24, 2017 at 7:24 AM, Mats Karrman wrote: > From 98ff2be4de83f4d4b5293bfa424c274b25400e1e Mon Sep 17 00:00:00 2001 > From: Mats Karrman > Date: Mon, 24 Apr 2017 15:21:39 +0200 > Subject: [PATCH] usb: typec: Don't prevent

Re: [RFC PATCH v5 1/2] usb: typec: USB Type-C Port Manager (tcpm)

2017-04-24 Thread Guenter Roeck
Hi Mats, On Mon, Apr 24, 2017 at 8:57 AM, Mats Karrman wrote: > Hello Guenter, > > Some corrections and suggestions follow. > Thanks a lot! > And then of course it would be nice to factor out the alternate mode > handling > so new mode handlers could be registered as

Re: [PATCH v17 2/3] usb: USB Type-C connector class

2017-04-24 Thread Badhri Jagan Sridharan
On Sat, Apr 22, 2017 at 2:23 AM, Rajaram R wrote: > On Fri, Apr 21, 2017 at 10:13 PM, Guenter Roeck wrote: >> On Fri, Apr 21, 2017 at 07:57:52PM +0530, Rajaram R wrote: >>> On Fri, Apr 21, 2017 at 1:16 AM, Badhri Jagan Sridharan >>>

Re: [PATCH 4/5 v3] usb: host: fotg2: add Gemini-specific handling

2017-04-24 Thread Hans Ulli Kroll
Hi Linus On Fri, 21 Apr 2017, Linus Walleij wrote: > The Cortina Systems Gemini has bolted on a PHY inside the > silicon that can be handled by six bits in a MISC register in > the system controller. > > If we are running on Gemini, look up a syscon regmap through > a phandle and enable VBUS

[PATCH v2] usb: typec: Don't prevent using constant typec_mode_desc initializers

2017-04-24 Thread Mats Karrman
Signed-off-by: Mats Karrman --- v2: - Fixed damaged white-space - Added signed-off-by drivers/usb/typec/typec.c | 11 ++- include/linux/usb/typec.h | 6 +++--- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/drivers/usb/typec/typec.c

Re: Options for improving f_fs.c performance?

2017-04-24 Thread Jerry Zhang
That sounds good. Thanks for the explanation. > That would answer several questions, indeed. I wonder, though, when it > comes to your product's policy and what not. Why does your libc lack > kaio? Was it a conscious decision or just happen to be this way? I believe nobody has ever really needed

[PATCH] usb: serial: upd78f0730: Make constants static

2017-04-24 Thread Maksim Salau
Some local constants don't change from call to call and are good candidates to become static. This will prevent copying of these constants to stack during runtime. Signed-off-by: Maksim Salau --- drivers/usb/serial/upd78f0730.c | 6 +++--- 1 file changed, 3

EXTREMELY IMPORTANT

2017-04-24 Thread Ms. Katherine
Dear Beloved, Sorry for the inconvenience, I am getting in touch with you regarding an extremely important and urgent matter, Please I need your urgent assistance and idea to finish up a project (Orphanage Home) Due to my health condition, Everything is available to finish up the project, All I

[PATCH] net: hso: fix module unloading

2017-04-24 Thread Andreas Kemnade
keep tty driver until usb driver is unregistered rmmod hso produces traces like this without that: [40261.645904] usb 2-2: new high-speed USB device number 2 using ehci-omap [40261.854644] usb 2-2: New USB device found, idVendor=0af0, idProduct=8800 [40261.862609] usb 2-2: New USB device strings:

[PATCH v3] usb: typec: Don't prevent using constant typec_mode_desc initializers

2017-04-24 Thread Mats Karrman
Signed-off-by: Mats Karrman --- v3: - Fixed damaged white-space, finally? v2: - Fixed damaged white-space - Added signed-off-by drivers/usb/typec/typec.c | 11 ++- include/linux/usb/typec.h | 6 +++--- 2 files changed, 9 insertions(+), 8 deletions(-) diff

Re: issues with commit c1da59dad0eb ("cdc-wdm: Clear read pipeline in case of error")

2017-04-24 Thread Robert Foss
On 2017-04-24 08:02 AM, Bjørn Mork wrote: Aleksander Morgado writes: On Thu, Apr 20, 2017 at 10:32 AM, Bjørn Mork wrote: Sorry for being much too late here, but during recent attemts to debug issues caused by my commit 833415a3e781 ("cdc-wdm: fix

Re: issues with commit c1da59dad0eb ("cdc-wdm: Clear read pipeline in case of error")

2017-04-24 Thread Aleksander Morgado
Hey Bjørn, On Thu, Apr 20, 2017 at 10:32 AM, Bjørn Mork wrote: > Sorry for being much too late here, but during recent attemts to debug > issues caused by my commit 833415a3e781 ("cdc-wdm: fix "out-of-sync" due > to missing notifications") I believe I found a couple of issues with

Re: issues with commit c1da59dad0eb ("cdc-wdm: Clear read pipeline in case of error")

2017-04-24 Thread Bjørn Mork
Aleksander Morgado writes: > On Thu, Apr 20, 2017 at 10:32 AM, Bjørn Mork wrote: >> Sorry for being much too late here, but during recent attemts to debug >> issues caused by my commit 833415a3e781 ("cdc-wdm: fix "out-of-sync" due >> to missing

Re: Options for improving f_fs.c performance?

2017-04-24 Thread Felipe Balbi
Hi, Jerry Zhang writes: > Hi all, > > Thanks for the replies. > >> That wait_for_completion_interruptible() is what's killing >> performance. Each and every read/write waits for the USB side to >> complete. It would've been much better to have something like: > >> This

Re: [PATCH v3] usb: typec: Don't prevent using constant typec_mode_desc initializers

2017-04-24 Thread Guenter Roeck
On Mon, Apr 24, 2017 at 11:52 AM, Mats Karrman wrote: > Signed-off-by: Mats Karrman > --- > v3: > - Fixed damaged white-space, finally? > Yes, this one finally applied. Some description in addition to the subject line might be nice. Other than

Re: [PATCH] usb: chipidea: Fix missing resume call after suspend

2017-04-24 Thread Bernhard Walle
Hi, > Peter Chen hat am 24. April 2017 um 05:51 geschrieben: > > > The current code logic is: > - When the resume is received from host, the ci->dirver->resume is > called, and suspended is cleared. > - When the reset is received from host, the isr_reset_handler is called, >

[PATCH] usb: chipidea: udc: fix NULL pointer dereference if udc_start failed

2017-04-24 Thread Jisheng Zhang
Fix below NULL pointer dereference. we set ci->roles[CI_ROLE_GADGET] too early in ci_hdrc_gadget_init(), if udc_start() fails due to some reason, the ci->roles[CI_ROLE_GADGET] check in ci_hdrc_gadget_destroy can't protect us. We fix this issue by only setting ci->roles[CI_ROLE_GADGET] if

Re: [PATCH] usb: Make sure usb/phy/of gets built-in

2017-04-24 Thread Alexey Brodkin
Hello, On Tue, 2017-04-18 at 12:23 +, Alexey Brodkin wrote: > Hello Frank, > > On Mon, 2017-04-17 at 20:15 -0700, Frank Rowand wrote: > > > > On 04/13/17 05:33, Alexey Brodkin wrote: > > > > > > > > > DWC3 driver uses of_usb_get_phy_mode() which is > > > implemented in

Re: [PATCH V3 4/4] soc/tegra: pmc: Use the new reset APIs to manage reset controllers

2017-04-24 Thread Jon Hunter
On 18/04/17 12:21, Vivek Gautam wrote: > Make use of reset_control_array_*() set of APIs to manage > an array of reset controllers available with the device. Before we apply this patch, I need to check to see if the order of the resets managed by the PMC driver matter. Today the order of the

Re: [PATCH v2] usb: core: Warn if an URB's transfer_buffer is on stack

2017-04-24 Thread Alan Stern
On Sun, 23 Apr 2017, Florian Fainelli wrote: > We see a large number of fixes to several drivers to remove the usage of > on-stack buffers feeding into USB transfer functions. Make it easier to spot > the offenders by adding a warning in usb_hcd_map_urb_for_dma() checking that >

Re: Regression - Linux 4.9: ums_eneub6250 broken: transfer buffer not dma capable - Trace

2017-04-24 Thread Alan Stern
On Sun, 23 Apr 2017, Andreas Hartmann wrote: > Am 23.04.2017 um 18:09 schrieb Alan Stern: > > On Sat, 22 Apr 2017, Andreas Hartmann wrote: > > > >>> In the meanwhile, I see another problem. The SCSI residue value is > >>> getting overwritten when new firmware is sent to the device. Like I said

[PATCH] usb: typec: Don't prevent using constant typec_mode_desc initializers

2017-04-24 Thread Mats Karrman
From 98ff2be4de83f4d4b5293bfa424c274b25400e1e Mon Sep 17 00:00:00 2001 From: Mats Karrman Date: Mon, 24 Apr 2017 15:21:39 +0200 Subject: [PATCH] usb: typec: Don't prevent using constant typec_mode_desc initializers --- drivers/usb/typec/typec.c | 11 ++-

Re: [PATCH V3 4/4] soc/tegra: pmc: Use the new reset APIs to manage reset controllers

2017-04-24 Thread Vivek Gautam
On 04/24/2017 06:15 PM, Jon Hunter wrote: On 18/04/17 12:21, Vivek Gautam wrote: Make use of reset_control_array_*() set of APIs to manage an array of reset controllers available with the device. Before we apply this patch, I need to check to see if the order of the resets managed by the PMC