Re: [PATCH 1/1] usb: musb: gadget: nuke endpoint before setting its descriptor to NULL

2016-04-15 Thread Bin Liu
Signed-off-by: Tal Shorer Signed-off-by: Bin Liu Regards, -Bin. > --- > drivers/usb/musb/musb_gadget.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c > index 87bd578..152865b 10

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-04-28 Thread Bin Liu
Hi, On Thu, Apr 28, 2016 at 09:51:37AM +0300, Maxim Uvarov wrote: [snip] > Hello Bin, > > yes, it also works with that reset and go to finish: > > diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c > index c3d5fc9..8cd98e7 100644 > --- a/drivers/usb/musb/musb_host.c > +++

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-05 Thread Bin Liu
Hi, On Thu, May 05, 2016 at 04:21:23PM +0300, Sergei Shtylyov wrote: > Hello. > > On 5/4/2016 10:17 PM, Bin Liu wrote: > > >>>>>>>>>>yes, it also works with that reset and go to finish: > >>>>>>>>>> > &g

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-05 Thread Bin Liu
On Thu, May 05, 2016 at 04:39:06PM +0300, Sergei Shtylyov wrote: > On 5/5/2016 4:31 PM, Bin Liu wrote: > > >>>>>>>>>>>>yes, it also works with that reset and go to finish: > >>>>>>>>>>>> > >>>

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-03 Thread Bin Liu
Hi, On Tue, May 03, 2016 at 12:03:52PM +0200, Yegor Yefremov wrote: > On Thu, Apr 28, 2016 at 4:37 PM, Bin Liu wrote: > > Hi, > > > > On Thu, Apr 28, 2016 at 09:51:37AM +0300, Maxim Uvarov wrote: > > > > [snip] > > > >> Hello Bin, > >>

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-03 Thread Bin Liu
Hi, On Tue, May 03, 2016 at 04:25:58PM +0200, Yegor Yefremov wrote: > On Tue, May 3, 2016 at 3:48 PM, Bin Liu wrote: > > Hi, > > > > On Tue, May 03, 2016 at 12:03:52PM +0200, Yegor Yefremov wrote: > >> On Thu, Apr 28, 2016 at 4:37 PM, Bin Liu wrote: > >> &

Re: [PATCH v4 3/7] phy: Add set_mode callback

2016-05-04 Thread Bin Liu
Hi, On Thu, Apr 14, 2016 at 01:35:14PM -0500, David Lechner wrote: > The initial use for this is for PHYs that have a mode related to USB OTG. > There are several SoCs (e.g. TI OMAP and DA8xx) that have a mode setting > in the USB PHY to override OTG VBUS and ID signals. > > Of course, the enum c

Re: [PATCH v4 3/7] phy: Add set_mode callback

2016-05-04 Thread Bin Liu
On Wed, May 04, 2016 at 01:20:36PM -0500, David Lechner wrote: > On 05/04/2016 01:10 PM, Bin Liu wrote: > >Hi, > > > >On Thu, Apr 14, 2016 at 01:35:14PM -0500, David Lechner wrote: > >>The initial use for this is for PHYs that have a mode related to USB OTG. >

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-04 Thread Bin Liu
Hi, On Wed, May 04, 2016 at 04:49:50PM +0200, Yegor Yefremov wrote: > On Tue, May 3, 2016 at 4:35 PM, Bin Liu wrote: > > Hi, > > > > On Tue, May 03, 2016 at 04:25:58PM +0200, Yegor Yefremov wrote: > >> On Tue, May 3, 2016 at 3:48 PM, Bin Liu wrote: > >> &

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-04 Thread Bin Liu
Hi, On Wed, May 04, 2016 at 10:02:16PM +0300, Sergei Shtylyov wrote: > Hello. > > On 05/04/2016 09:56 PM, Bin Liu wrote: > > >>>>>>>>yes, it also works with that reset and go to finish: > >>>>>>>> > >>>>>&g

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-05-04 Thread Bin Liu
Hi, On Wed, May 04, 2016 at 01:19:27PM -0700, Greg KH wrote: > On Wed, May 04, 2016 at 02:17:15PM -0500, Bin Liu wrote: > > Hi, > > > > On Wed, May 04, 2016 at 10:02:16PM +0300, Sergei Shtylyov wrote: > > > Hello. > > > > > > On 05/04/2016 09:56

Re: [PATCH V3 0/2] usb: musb: fix dropped packets

2016-05-25 Thread Bin Liu
he comment to better reference the manual > V2 added a comment and removed debugging code > > Andrew Goodbody (2): > usb: musb: Ensure rx reinit occurs for shared_fifo endpoints > usb: musb: Stop bulk endpoint while queue is rotated Signed-off-by: Bin Liu Regards, -

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-04-27 Thread Bin Liu
Hi, On Wed, Apr 27, 2016 at 09:51:58AM +0300, Max Uvarov wrote: > Fix soft lockup when resetting remote device attached > to usb host. Configuration: > pppd -> musb hub -> usb-serial -> gsm modem I have heard a few reports similar to this symptom, but never been able to reproduce it on my side.

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-04-27 Thread Bin Liu
Hi, On Wed, Apr 27, 2016 at 09:26:10PM +0300, Maxim Uvarov wrote: > 2016-04-27 18:46 GMT+03:00 Bin Liu : > > Hi, > > > > On Wed, Apr 27, 2016 at 09:51:58AM +0300, Max Uvarov wrote: > >> Fix soft lockup when resetting remote device attached > >> to usb hos

Re: [PATCHv2] musb_host: fix lockup on rxcsr_h_error

2016-04-27 Thread Bin Liu
Hi, On Wed, Apr 27, 2016 at 02:13:56PM -0500, Bin Liu wrote: > Hi, > > On Wed, Apr 27, 2016 at 09:26:10PM +0300, Maxim Uvarov wrote: > > 2016-04-27 18:46 GMT+03:00 Bin Liu : > > > Hi, > > > > > > On Wed, Apr 27, 2016 at 09:51:58AM +0300, Max Uvarov wr

Re: [PATCH] usb: musb: USB_TI_CPPI41_DMA requires dmaengine support

2015-11-18 Thread Bin Liu
Hi, On Wed, Nov 18, 2015 at 10:18 AM, Arnd Bergmann wrote: > The CPPI-4.1 driver selects TI_CPPI41, which is a dmaengine > driver and that may not be available when CONFIG_DMADEVICES > is not set: > > warning: (USB_TI_CPPI41_DMA) selects TI_CPPI41 which has unmet direct > dependencies (DMADEVICE

Re: [PATCH] usb: musb: USB_TI_CPPI41_DMA requires dmaengine support

2015-11-18 Thread Bin Liu
Hi, On Wed, Nov 18, 2015 at 1:27 PM, Felipe Balbi wrote: > > Hi, > > Bin Liu writes: >> On Wed, Nov 18, 2015 at 10:18 AM, Arnd Bergmann wrote: >>> The CPPI-4.1 driver selects TI_CPPI41, which is a dmaengine >>> driver and that may not be available w

Re: [PATCH] usb: musb: USB_TI_CPPI41_DMA requires dmaengine support

2015-11-18 Thread Bin Liu
Hi, On Wed, Nov 18, 2015 at 2:27 PM, Arnd Bergmann wrote: > On Wednesday 18 November 2015 12:29:27 Bin Liu wrote: >> > diff --git a/drivers/usb/musb/Kconfig b/drivers/usb/musb/Kconfig >> > index 1f2037bbeb0d..45c83baf675d 100644 >> > --- a/drivers/usb/musb/Kconf

Re: [PATCH] usb: musb: USB_TI_CPPI41_DMA requires dmaengine support

2015-11-18 Thread Bin Liu
On Wed, Nov 18, 2015 at 2:38 PM, Felipe Balbi wrote: > > Hi, > > Bin Liu writes: >>> Bin Liu writes: >>>> On Wed, Nov 18, 2015 at 10:18 AM, Arnd Bergmann wrote: >>>>> The CPPI-4.1 driver selects TI_CPPI41, which is a dmaengine >>>>&

Re: [PATCH] usb: musb: dsps: handle the otg_state_a_wait_vrise_timeout case

2015-12-08 Thread Bin Liu
Felipe, On 12/08/2015 08:20 AM, Felipe Balbi wrote: Hi, Gregory CLEMENT writes: if it is the case then it didn't fix the issue I had. I activated the following debug line: [musb_hdrc]musb_interrupt =_ "** IRQ %s usb%04x tx%04x rx%04x\012" [musb_dsps]dsps_interrupt =p "usbintr (%x) epintr(%

Re: [PATCH] usb: musb: dsps: handle the otg_state_a_wait_vrise_timeout case

2015-12-08 Thread Bin Liu
On 12/08/2015 08:35 AM, Felipe Balbi wrote: Hi, Bin Liu writes: Felipe, On 12/08/2015 08:20 AM, Felipe Balbi wrote: Hi, Gregory CLEMENT writes: if it is the case then it didn't fix the issue I had. I activated the following debug line: [musb_hdrc]musb_interrupt =_ "**

Re: [PATCH] usb: phy-am335x: clarify USB_COMMON dependency

2016-01-20 Thread Bin Liu
Hi, On Wed, Jan 20, 2016 at 11:56:34AM +0100, Arnd Bergmann wrote: > The phy-am335x driver accidentally selects 'USB_COMMON', which is > not correct as that symbol should indicate whether USB host or > target mode is enabled, but it might not: > > warning: (AM335X_PHY_USB) selects USB_COMMON whic

Re: [PATCH] usb: musb: core: Disable the Interrupts till BABBLE is fully handled

2014-11-18 Thread Bin Liu
Felipe, On Tue, Nov 18, 2014 at 3:17 PM, Felipe Balbi wrote: > On Fri, Nov 14, 2014 at 01:54:46PM +0530, George Cherian wrote: >> Disable the MUSB interrupts till MUSB is recovered fully from BABBLE >> condition. There are chances that we could get multiple interrupts >> till the time the babble

Re: [PATCH] phy: Add a driver for dm816x USB PHY

2015-03-09 Thread Bin Liu
Hi, On Mon, Mar 9, 2015 at 3:51 PM, Tony Lindgren wrote: > Add a minimal driver for dm816x USB. Otherwise we can just use > the existing musb_am335x and musb_dsps on dm816x. dm816x has the almost identical usbss as that in am335x, we should be able to adopt musb_am335x and musb_dsps for dm816x,

Re: [PATCH] phy: Add a driver for dm816x USB PHY

2015-03-09 Thread Bin Liu
On Mon, Mar 9, 2015 at 4:13 PM, Felipe Balbi wrote: > On Mon, Mar 09, 2015 at 04:11:28PM -0500, Bin Liu wrote: >> Hi, >> >> On Mon, Mar 9, 2015 at 3:51 PM, Tony Lindgren wrote: >> > Add a minimal driver for dm816x USB. Otherwise we can just use >> > th

Re: [PATCH] phy: Add a driver for dm816x USB PHY

2015-03-09 Thread Bin Liu
On Mon, Mar 9, 2015 at 4:26 PM, Tony Lindgren wrote: > * Felipe Balbi [150309 14:21]: >> On Mon, Mar 09, 2015 at 04:17:29PM -0500, Bin Liu wrote: >> > On Mon, Mar 9, 2015 at 4:13 PM, Felipe Balbi wrote: >> > > On Mon, Mar 09, 2015 at 04:11:28PM -0

Re: [PATCH] phy: Add a driver for dm816x USB PHY

2015-03-09 Thread Bin Liu
On Mon, Mar 9, 2015 at 4:20 PM, Tony Lindgren wrote: > * Bin Liu [150309 14:17]: >> On Mon, Mar 9, 2015 at 4:13 PM, Felipe Balbi wrote: >> > On Mon, Mar 09, 2015 at 04:11:28PM -0500, Bin Liu wrote: >> >> Hi, >> >> >> >> On Mon, Mar 9, 2015 a

Re: [PATCH] phy: Add a driver for dm816x USB PHY

2015-03-10 Thread Bin Liu
On Mon, Mar 9, 2015 at 4:41 PM, Tony Lindgren wrote: > * Bin Liu [150309 14:35]: >> On Mon, Mar 9, 2015 at 4:26 PM, Tony Lindgren wrote: >> > * Felipe Balbi [150309 14:21]: >> >> On Mon, Mar 09, 2015 at 04:17:29PM -0500, Bin Liu wrote: >> >> >

Re: [PATCH v3 15/16] usb: musb: da8xx: Use devm in probe

2016-03-31 Thread Bin Liu
Hi, On Thu, Mar 24, 2016 at 06:51:40PM -0500, David Lechner wrote: > Simplify things a bit by using devm functions where possible. > > Signed-off-by: David Lechner > --- > > v3 changes: > > * Kept clk variable to minimize noise. > > > drivers/usb/musb/da8xx.c | 19 +-- > 1 f

Re: [PATCH v2 06/11] phy: da8xx-usb: new driver for DA8XX SoC USB PHY

2016-04-01 Thread Bin Liu
Hi, On Fri, Apr 01, 2016 at 06:46:28PM +0530, Kishon Vijay Abraham I wrote: > Hi, > > On Thursday 17 March 2016 07:56 AM, David Lechner wrote: > > This is a new phy driver for the SoC USB controllers on the TI DA8XX > > family of microcontrollers. The USB 1.1 PHY is just a simple on/off. > > The

Re: [PATCH v3 15/16] usb: musb: da8xx: Use devm in probe

2016-04-01 Thread Bin Liu
Hi, On Thu, Mar 31, 2016 at 05:28:48PM -0500, David Lechner wrote: > On 03/31/2016 05:21 PM, Bin Liu wrote: > > >>- glue = kzalloc(sizeof(*glue), GFP_KERNEL); > >>+ glue = devm_kzalloc(&pdev->dev, sizeof(*glue), GFP_KERNEL); > >>if (!glue) { > &

Re: [PATCH v2 06/11] phy: da8xx-usb: new driver for DA8XX SoC USB PHY

2016-04-01 Thread Bin Liu
Hi, On Fri, Apr 01, 2016 at 11:02:23AM -0500, David Lechner wrote: > On 04/01/2016 09:45 AM, Bin Liu wrote: > >>>+EXPORT_SYMBOL_GPL(da8xx_usb20_phy_set_mode); > >> > >>Don't prefer export symbols from PHY driver. That'll create unnecessary > >

Re: [PATCH v2 06/11] phy: da8xx-usb: new driver for DA8XX SoC USB PHY

2016-04-01 Thread Bin Liu
Hi, On Fri, Apr 01, 2016 at 10:45:47PM +0300, Sergei Shtylyov wrote: > On 04/01/2016 07:02 PM, David Lechner wrote: > > +EXPORT_SYMBOL_GPL(da8xx_usb20_phy_set_mode); > >>> > >>>Don't prefer export symbols from PHY driver. That'll create unnecessary > >>>dependencies between the controller and

Re: [PATCH v4 5/6] usb: musb: Add musb_clearb/w() interface

2019-01-21 Thread Bin Liu
Hi Min, On Mon, Jan 21, 2019 at 08:22:30PM +0800, min@mediatek.com wrote: > From: Min Guo > > Delete the const attribute of addr parameter in readb/w/l hooks, these > changes are for implementing clearing W1C registers. > Replace musb_readb/w with musb_clearb/w to clear the interrupt status.

Re: [PATCH v4 6/6] usb: musb: Add support for MediaTek musb controller

2019-01-21 Thread Bin Liu
Hi Min, On Mon, Jan 21, 2019 at 08:22:31PM +0800, min@mediatek.com wrote: > From: Min Guo > > This adds support for MediaTek musb controller in > host, peripheral and otg mode. > There are some quirk of MediaTek musb controller, such as: > -W1C interrupt status registers > -Private data to

Re: [PATCH v4 1/6] dt-bindings: usb: musb: Add support for MediaTek musb controller

2019-01-22 Thread Bin Liu
Hi Min, On Tue, Jan 22, 2019 at 05:36:13PM +0800, Min Guo wrote: > Hi Bin, > > Sorry to bother you again, I encounter a problem about the extcon > property. > > I don't find a common driver describing the usb-connector. Is > there any driver that I can refer to, specially the way to switch MUSB

Re: [PATCH v2 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-15 Thread Bin Liu
Hi Min, very close, thanks. Below I tried to explain a further cleanup in musb_clearb/w() and musb_get/set_toggle() implementation. Please let me know if it is not clear. Basically, we don't need musb_default_clearb/w(), just assign the musb_io function pointers to musb_readb/w(). Then the mtk p

Re: [PATCH v2 3/4] usb: musb: Extract set toggle as a separate interface

2019-01-15 Thread Bin Liu
Hi Min, On Tue, Jan 15, 2019 at 04:19:42PM +0100, Matthias Brugger wrote: > > > On 15/01/2019 02:43, min@mediatek.com wrote: > > From: Min Guo > > > > Add a common interface for set data toggle > > > > Signed-off-by: Min Guo > > --- > > drivers/usb/musb/musb_host.c | 37

Re: [PATCH v2 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-16 Thread Bin Liu
On Wed, Jan 16, 2019 at 05:39:02PM +0800, Min Guo wrote: > Hi Bin, > > On Tue, 2019-01-15 at 14:38 -0600, Bin Liu wrote: > > Hi Min, > > > > very close, thanks. > > Below I tried to explain a further cleanup in musb_clearb/w() and > > musb_get/set_toggle(

Re: [PATCH v3] usb: gadget: musb: fix short isoc packets with inventra dma

2019-01-16 Thread Bin Liu
On Tue, Jan 15, 2019 at 07:01:45PM -0500, Paul Elder wrote: > Handling short packets (length < max packet size) in the Inventra DMA > engine in the MUSB driver causes the MUSB DMA controller to hang. An > example of a problem that is caused by this problem is when streaming > video out of a UVC gad

Re: [PATCH v3 0/4] Add MediaTek MUSB Controller Driver

2019-01-17 Thread Bin Liu
On Thu, Jan 17, 2019 at 03:15:44PM +0800, min@mediatek.com wrote: > From: Min Guo > > These patches introduce the MediaTek MUSB controller driver. > > The driver can be configured as Dual-Role Device (DRD), > Peripheral Only and Host Only modes. This has beed tested on > MT2701 with a variet

Re: [PATCH v2 3/4] usb: musb: Kconfig: Drop dependency on MACH_JZ4740 for jz4740

2019-01-15 Thread Bin Liu
Hi Paul, On Thu, Jan 10, 2019 at 10:36:59AM -0300, Paul Cercueil wrote: > Depending on MACH_INGENIC prevent us from creating a generic kernel that Again, did you mean MACH_JZ4740 instead? > works on more than one MIPS board. Instead, we just depend on MIPS being > set. > > Signed-off-by: Paul C

Re: [PATCH v2] usb: gadget: musb: fix short isoc packets with inventra dma

2019-01-15 Thread Bin Liu
Hi Paul, On Fri, Jan 11, 2019 at 12:31:59AM -0500, Paul Elder wrote: > Hi Bin, > > On Wed, Jan 09, 2019 at 09:02:15AM -0600, Bin Liu wrote: > > Hi Paul, > > > > On Wed, Jan 09, 2019 at 02:10:09AM -0500, Paul Elder wrote: > > > Handling short packets (lengt

Re: [PATCH v3 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-18 Thread Bin Liu
Hi Min, On Fri, Jan 18, 2019 at 02:14:14PM +0800, Min Guo wrote: > On Thu, 2019-01-17 at 06:33 -0800, Tony Lindgren wrote: > > Hi, > > > > * min@mediatek.com [190117 07:16]: > > > There are some quirk of MediaTek musb controller, such as: > > > -W1C interrupt status registers > > > -Privat

Re: [PATCH v3 1/4] Documentation: dt: Add binding info for jz4740-musb driver

2019-01-21 Thread Bin Liu
On Thu, Jan 17, 2019 at 07:33:27PM -0300, Paul Cercueil wrote: > This commit adds documentation for the device-tree bindings of the > jz4740-musb driver, which provides support for the USB gadget mode > of the JZ4740 and similar SoCs from Ingenic. > > Signed-off-by: Paul Cercueil > Reviewed-by: R

Re: [PATCH v2 0/6] musb: Improve performance for hub-attached webcams

2019-07-02 Thread Bin Liu
Matwey, On Tue, Jul 02, 2019 at 08:29:03PM +0300, Matwey V. Kornilov wrote: > Ping? I was offline and just got back. I will review it soon. Sorry for the delay. -Bin. > > пт, 14 июн. 2019 г. в 19:47, Matwey V. Kornilov : > > > > The series is concerned to issues with isochronous transfer while

Re: [PATCH 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-08 Thread Bin Liu
Hi, On Thu, Dec 27, 2018 at 03:34:26PM +0800, min@mediatek.com wrote: > From: Min Guo > > This adds support for MediaTek musb controller in > host, peripheral and otg mode > > Signed-off-by: Min Guo > Signed-off-by: Yonglong Wu > --- > drivers/usb/musb/Kconfig | 8 +- > drivers/usb

Re: [PATCH] usb: gadget: musb: fix short isoc packets with inventra dma for pandaboard es

2019-01-08 Thread Bin Liu
On Mon, Jan 07, 2019 at 11:45:24PM -0500, Paul Elder wrote: > Hi Bin, > > On Mon, Jan 07, 2019 at 01:11:57PM -0600, Bin Liu wrote: > > Hi Paul, > > > > Sorry for the delay on reviewing it. > > Thanks for the review. > > > For the subject, can you plea

Re: [PATCH 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-09 Thread Bin Liu
Hi Min, On Wed, Jan 09, 2019 at 08:31:08PM +0800, Min Guo wrote: > Hi Bin, > On Tue, 2019-01-08 at 09:44 -0600, Bin Liu wrote: > > Hi, > > > > On Thu, Dec 27, 2018 at 03:34:26PM +0800, min@mediatek.com wrote: > > > From: Min Guo > > > > > >

Re: [PATCH v2] usb: gadget: musb: fix short isoc packets with inventra dma

2019-01-09 Thread Bin Liu
Hi Paul, On Wed, Jan 09, 2019 at 02:10:09AM -0500, Paul Elder wrote: > Handling short packets (length < max packet size) in the Inventra DMA > engine in the MUSB driver causes the MUSB DMA controller to hang. An > example of a problem that is caused by this problem is when streaming > video out of

Re: [PATCH] USB: musb: mark expected switch fall-through

2019-02-12 Thread Bin Liu
-by: Gustavo A. R. Silva I've closed my musb tree for v5.1-rc1, if you want to directly pick this patch, here is my Acked-by, or I will take it for v5.2-rc1. Acked-by: Bin Liu > --- > drivers/usb/musb/musb_host.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > d

Re: [PATCH 4/4] usb: musb: Add support for MediaTek musb controller

2019-01-10 Thread Bin Liu
Hi Min, Please briefly summarize the controller differences in the commit log, such as - WIC interrupt registers; - data toggle bit; - no dedicated DMA interrupt line; so that we can quickly understand the core driver is modified accordingly to handle the differences. On Thu, Jan 10, 2019 at 03

Re: usb: musb: "(null)" in sysfs mode file after disabling a gadget (and at other times, system hangs)

2018-03-02 Thread Bin Liu
Hi, On Fri, Mar 02, 2018 at 12:47:07AM +0100, Merlijn Wajer wrote: > Hi, > > I found that the "mode" file in musb sys node will return "(null)" when > one would expect it show b_idle. > > Wrong /mode file: > > [Fresh boot, cable not connected yet] > root@n900devuan:~# modprobe g_nokia > [Insert

Re: [PATCH 1/1] usb: musb: gadget: misplaced out of bounds check

2018-03-19 Thread Bin Liu
Hi, On Mon, Mar 19, 2018 at 08:12:28AM +0100, Heinrich Schuchardt wrote: > musb->endpoints[] has array size MUSB_C_NUM_EPS. > We must check array bounds before accessing the array and not afterwards. > > Signed-off-by: Heinrich Schuchardt > --- > drivers/usb/musb/musb_gadget_ep0.c | 7 ++- >

Re: [PATCH] usb: musb: Support gadget mode when the port is set to dual role

2018-04-20 Thread Bin Liu
On Thu, Mar 29, 2018 at 01:57:24PM +0200, Paul Kocialkowski wrote: > Hi, > > On Thu, 2018-03-29 at 11:23 +0200, Maxime Ripard wrote: > > On Wed, Mar 28, 2018 at 11:52:13PM +0200, Paul Kocialkowski wrote: > > > This allows dual-role ports to be reported as having gadget mode by > > > the > > > musb

Re: [PATCH] usb: musb: Support gadget mode when the port is set to dual role

2018-04-21 Thread Bin Liu
On Sat, Apr 21, 2018 at 12:59:23PM +0200, Paul Kocialkowski wrote: > Hi, > > Le vendredi 20 avril 2018 à 09:25 -0500, Bin Liu a écrit : > > On Thu, Mar 29, 2018 at 01:57:24PM +0200, Paul Kocialkowski wrote: > > > Hi, > > > > > > On Thu, 2018-03-29 at 11

Re: [PATCH 3/3] USB: musb: dsps: propagate device-tree node

2018-04-16 Thread Bin Liu
Johan, On Fri, Apr 13, 2018 at 05:15:05PM +0200, Johan Hovold wrote: > To be able to use DSPS-based controllers with device-tree descriptions > of the USB topology, we need to associate the glue device's device-tree > node with the child controller device. > > Note that this can also be used to e

Re: linux-next: build failure after merge of the asm-generic tree

2018-03-15 Thread Bin Liu
Hi, On Fri, Mar 16, 2018 at 09:13:55AM +1100, Stephen Rothwell wrote: > Hi Arnd, > > After merging the asm-generic tree, today's linux-next build (arm > multi_v7_defconfig) failed like this: > > drivers/usb/musb/musb_host.c: In function 'musb_rx_reinit': > drivers/usb/musb/musb_host.c:577:10: er

Re: [PATCH 0/3] USB: musb: dsps: phy fix and DT-topology support

2018-04-18 Thread Bin Liu
Johan, On Fri, Apr 13, 2018 at 05:15:02PM +0200, Johan Hovold wrote: > I've been carrying a patch out-of-tree since my work on improving the > USB device-tree support which is needed to be able to describe USB > topologies for musb based controllers. > > This patch, which associates the platform

Re: [PATCH 0/3] USB: musb: dsps: phy fix and DT-topology support

2018-04-18 Thread Bin Liu
On Wed, Apr 18, 2018 at 08:46:40PM +0200, Johan Hovold wrote: > On Wed, Apr 18, 2018 at 11:20:15AM -0500, Bin Liu wrote: > > Johan, > > > > On Fri, Apr 13, 2018 at 05:15:02PM +0200, Johan Hovold wrote: > > > I've been carrying a patch out-of-tree since my wor

Re: [PATCH 07/12] usb: sunxi: Uses the resource-managed extcon API when registering extcon notifier

2016-12-05 Thread Bin Liu
> Acked-by: Maxime Ripard It would be ideal if the subject was "usb: musb: sunxi: ...". Acked-by: Bin Liu Regards, -Bin.

Re: [PATCH 2/4] musb: sunxi: add support for the variant in H3/V3s SoC

2017-01-17 Thread Bin Liu
On Fri, Jan 06, 2017 at 02:57:15PM +0100, Maxime Ripard wrote: > On Tue, Jan 03, 2017 at 11:25:32PM +0800, Icenowy Zheng wrote: > > Allwinner H3/V3s features a variant of MUSB controller, which lacks one > > endpoint. > > > > Add support for it. > > > > Signed-off-by: Icenowy Zheng > > Acked-by

Re: [PATCH 4/4] ARM: dts: sun8i: add OTG function to Lichee Pi Zero

2017-01-13 Thread Bin Liu
On Thu, Jan 12, 2017 at 06:39:38PM +0100, Maxime Ripard wrote: > Hi Bin, > > On Thu, Jan 12, 2017 at 08:50:14AM -0600, Bin Liu wrote: > > On Wed, Jan 11, 2017 at 10:06:38PM +0100, Maxime Ripard wrote: > > > On Wed, Jan 11, 2017 at 02:08:11PM -0600, Bin Liu wrote: > &g

Re: [PATCH] usb: musb: constify musb_hdrc_config structures

2017-01-25 Thread Bin Liu
On Wed, Jan 25, 2017 at 12:52:22AM +0530, Bhumika Goyal wrote: > Declare musb_hdrc_config structures as const as they are only stored in > the config field of a musb_hdrc_platform_data structure. This field is of > type const, so musb_hdrc_config structures having this property can be > made const

Re: [PATCH] usb: musb: constify musb_hdrc_config structures

2017-01-26 Thread Bin Liu
On Wed, Jan 25, 2017 at 10:24:09PM +0100, Greg KH wrote: > On Wed, Jan 25, 2017 at 10:58:15AM -0600, Bin Liu wrote: > > On Wed, Jan 25, 2017 at 12:52:22AM +0530, Bhumika Goyal wrote: > > > Declare musb_hdrc_config structures as const as they are only stored in > >

Re: Nokia N900: musb is in wrong state after boot

2016-06-09 Thread Bin Liu
Hi, On Sun, May 29, 2016 at 12:38:24PM +0200, Pali Rohár wrote: > > Hello, attached patch for musb debugfs adds option to force both > > hostmode with speed. It is just example, I tested only compilation. > > > > Something like that will be needed for usb host mode on Nokia N900. > > > > -- >

Re: Nokia N900: musb is in wrong state after boot

2016-06-09 Thread Bin Liu
Hi, On Wed, Jun 08, 2016 at 01:02:00PM +0300, Felipe Balbi wrote: > > Hi, > > Tony Lindgren writes: > > * Pali Rohár [160607 05:53]: > >> > Tony, what do you think about that patch? > >> > > >> > >> Tony, PING > > > > Yeah I don't know, AFAIK we don't have a generic way to > > force MUSB to

Re: Nokia N900: musb is in wrong state after boot

2016-06-10 Thread Bin Liu
Hi, On Thu, Jun 09, 2016 at 11:25:57PM +0200, joerg Reisenweber wrote: > On Thu 09 June 2016 15:58:56 Bin Liu wrote: > > But I am not sure how this will fix n900 host mode problem, since > > testmode is not used in normal operation. > > Please see http://talk.maemo.org/sh

Re: Nokia N900: musb is in wrong state after boot

2016-06-10 Thread Bin Liu
Hi, On Fri, Jun 10, 2016 at 05:23:11PM +0200, joerg Reisenweber wrote: > On Fri 10 June 2016 10:08:08 Bin Liu wrote: > > Hi, > > > > On Thu, Jun 09, 2016 at 11:25:57PM +0200, joerg Reisenweber wrote: > > > On Thu 09 June 2016 15:58:56 Bin Liu wrote: > > >

Re: Nokia N900: musb is in wrong state after boot

2016-06-10 Thread Bin Liu
Hi, On Fri, Jun 10, 2016 at 06:15:26PM +0200, joerg Reisenweber wrote: > On Fri 10 June 2016 10:59:40 Bin Liu wrote: > > The musb ug says the testmde is not used in normal operation, so my > > opinion is force_host should not be used for hacking n900 host mode if > > thi

Re: [PATCH] usb: musb_host: Use sizeof(*qh)instead of sizeof *qh.

2016-06-02 Thread Bin Liu
Hi, On Wed, Jun 01, 2016 at 09:40:06AM -0400, Sandhya Bankar wrote: > Use sizeof(*qh)instead of sizeof *qh. > > Signed-off-by: Sandhya Bankar Please revise the subject prefix to "usb: musb: host: ...". Regards, -Bin.

Re: [PATCH] usb: musbhsdma: Add space after that ','.

2016-06-02 Thread Bin Liu
Hi, On Wed, Jun 01, 2016 at 09:49:35AM -0400, Sandhya Bankar wrote: > Add space after that ','. > > Signed-off-by: Sandhya Bankar Please revise the subject prefix to "usb: musb: musbhsdma: ...". Regards, -Bin.

Re: [PATCH v2 3/3] usb: musb: da8xx: Only execute the OTG workaround when phy in OTG mode

2016-10-28 Thread Bin Liu
On Fri, Oct 28, 2016 at 12:11:21PM -0500, David Lechner wrote: > On 10/28/2016 07:39 AM, Alexandre Bailon wrote: > >On 10/28/2016 04:56 AM, David Lechner wrote: > >>On 10/26/2016 05:58 AM, Alexandre Bailon wrote: > >>>When the phy is forced in host mode, only the first hot plug and > >>>hot remove

Re: [PATCH v4 4/4] ARM: dts: da850: Add the usb otg device nodeg

2016-11-16 Thread Bin Liu
On Wed, Nov 16, 2016 at 12:06:51PM +0530, Sekhar Nori wrote: > On Wednesday 16 November 2016 02:49 AM, Bin Liu wrote: > > On Tue, Nov 15, 2016 at 04:16:02PM +0530, Sekhar Nori wrote: > >> On Thursday 03 November 2016 09:29 PM, Alexandre Bailon wrote: > >>> This add

Re: [PATCH v5 3/4] usb: musb: Add a new argument to musb_platform_set_mode()

2016-11-14 Thread Bin Liu
Hi, On Mon, Nov 07, 2016 at 02:05:07PM +0100, Alexandre Bailon wrote: > During the init, the driver will use musb_platform_set_mode() > to configure the controller mode and the PHY mode. > The PHY of DA8xx has some issues when the PHY is forced in host or device, > so we want to keep it in OTG mod

Re: [PATCH v4 4/4] ARM: dts: da850: Add the usb otg device nodeg

2016-11-15 Thread Bin Liu
On Tue, Nov 15, 2016 at 04:16:02PM +0530, Sekhar Nori wrote: > On Thursday 03 November 2016 09:29 PM, Alexandre Bailon wrote: > > This adds the device tree node for the usb otg > > controller present in the da850 family of SoC's. > > This also enables the otg usb controller for the lcdk board. > >

Re: [PATCH v4 0/4] Add DT support for DA8xx

2016-11-15 Thread Bin Liu
On Thu, Nov 03, 2016 at 04:59:08PM +0100, Alexandre Bailon wrote: > Changes in v2: > * Remove unrelated changes in patch 3 > * Rename the device node in patch 4 > > Changes in v3: > * Fix few mistakes in DT binding sample > * Only build the device table if DT is enabled > > Change in v4: > * Fix

Re: [PATCH v4] usb: musb: remove duplicated actions

2016-11-01 Thread Bin Liu
Hi, On Wed, Oct 26, 2016 at 09:10:07PM +0300, Kirill Esipov wrote: > Removing unnecessary duplicated actions that we've got while merging: > 19915e623458 ("Merge 4.1-rc7 into usb-next") > > Signed-off-by: Kirill Esipov Applied. Thanks. Regards, -Bin. > --- > drivers/usb/musb/musb_core.c | 5

Re: [PATCH] usb: musb: da8xx: Don't print phy error on -EPROBE_DEFER

2016-11-01 Thread Bin Liu
Hi, On Tue, Oct 25, 2016 at 02:02:50PM -0500, David Lechner wrote: > This suppresses printing the error message "failed to get phy" in the > kernel log when the error is -EPROBE_DEFER. This prevents usless noise > in the kernel log. > > Signed-off-by: David Lechner Applied. Thanks. Regards, -B

Re: [PATCH v3] usb: musb: debugfs: allow forcing host mode together with speed in testmode

2016-12-19 Thread Bin Liu
On Mon, Dec 19, 2016 at 04:23:47PM +0100, Pali Rohár wrote: > Based on the musb ug, force_host bit is allowed to be set along with > force_hs or force_fs bit. > > It could help to implement forced host mode via testmode on Nokia N900. > > Signed-off-by: Pali Rohár Applied. Thanks. -Bin. > ---

Re: [PATCH v3] usb: musb: remove duplicated actions

2016-10-26 Thread Bin Liu
Hi, On Wed, Oct 26, 2016 at 05:24:27PM +0300, Kirill Esipov wrote: > Removing unnecessary duplicated actions that we've got while merging: > 19915e623458 ("Merge 4.1-rc7 into usb-next") > > Signed-off-by: Kirill Esipov > --- > drivers/usb/musb/musb_core.c | 6 -- > 1 file changed, 6 deletio

Re: [PATCH] usb: musb: debugfs: allow forcing host mode together with speed in testmode

2016-12-15 Thread Bin Liu
On Wed, Dec 14, 2016 at 08:23:45PM +0100, Pali Rohár wrote: > Based on the musb ug, force_host bit is allowed to be set along with > force_hs or force_fs bit. > > It could help to implement forced host mode via testmode on Nokia N900. > > Signed-off-by: Pali Rohár > --- > drivers/usb/musb/musb_

Re: [PATCH v2] usb: musb: debugfs: allow forcing host mode together with speed in testmode

2016-12-19 Thread Bin Liu
On Sun, Dec 18, 2016 at 12:54:40AM +0100, Pali Rohár wrote: > Based on the musb ug, force_host bit is allowed to be set along with > force_hs or force_fs bit. > > It could help to implement forced host mode via testmode on Nokia N900. > > Signed-off-by: Pali Rohár > --- > Changes in v2: > * Use

Re: [PATCH] b: re-queue tx dma request on herror

2016-11-28 Thread Bin Liu
Hi, On Wed, Nov 16, 2016 at 10:42:03AM +0300, Max Uvarov wrote: > Some times dma transfer to usb endpoint fails: > > [ 78.378283] musb-hdrc musb-hdrc.1.auto: Start TX10 dma > [ 78.410763] musb-hdrc musb-hdrc.1.auto: OUT/TX10 end, csr 3400, dma > [ 78.410896] musb-hdrc musb-hdrc.1.auto: complete d

Re: [PATCH v5 0/3] driver: Add DT support for DA8xx

2016-11-18 Thread Bin Liu
On Wed, Nov 16, 2016 at 11:52:22AM +0100, Alexandre Bailon wrote: > Changes in v2: > * Remove unrelated changes in patch 3 > * Rename the device node in patch 4 > > Changes in v3: > * Fix few mistakes in DT binding sample > * Only build the device table if DT is enabled > > Change in v4: > * Fix

Re: [PATCH v6 0/2] usb: musb: da8xx: Fix few issues

2016-11-18 Thread Bin Liu
On Tue, Nov 15, 2016 at 06:42:45PM +0100, Alexandre Bailon wrote: > This series require the following patch to build: > [PATCH 1/6] usb: musb: Fix broken use of static variable for multiple > instances > > Currently, the USB OTG of the da8xx doesn't work. > This series intend to fix them. > > Ch

Re: [PATCH] usb: musb: cppi_dma.c: use DIV_ROUND_UP macro in cppi_next_(r|t)x_segment()

2017-03-24 Thread Bin Liu
On Wed, Feb 15, 2017 at 11:12:36AM +0300, Ivan Safonov wrote: > DIV_ROUND_UP is bit useful than series of "/" and "%" operations. > Replace "/%" sequence with DIV_ROUND_UP macro. > > Signed-off-by: Ivan Safonov > --- > drivers/usb/musb/cppi_dma.c | 10 -- > 1 file changed, 4 insertions(+

Re: [PATCH] usb-musb: keep VBUS on when device is disconnected

2017-03-24 Thread Bin Liu
On Wed, Mar 15, 2017 at 09:08:01AM -0500, Moreno Bartalucci wrote: > With usb-musb port in host mode, when the device > is disconnected, either logically (because of a mode switch) or > physically (by pulling the cable), the USB port should keep > suppling VBUS, with no interruption, to prevent pow

Re: [PATCH] usb-musb: keep VBUS on when device is disconnected

2017-03-27 Thread Bin Liu
On Mon, Mar 27, 2017 at 02:53:27PM +0200, Moreno Bartalucci wrote: > > Il giorno 25 mar 2017, alle ore 08:21, Lars Melin ha > > scritto: > > > >> > >> The usb device has been disconnected, why it still cares about VBUS > >> power? > > > > Morphing devices (3G dongles, wifi dongles, some printe

Re: [PATCH v2] usb: musb: cppi_dma.c: use DIV_ROUND_UP macro in cppi_next_(r|t)x_segment()

2017-03-27 Thread Bin Liu
On Sat, Mar 25, 2017 at 12:52:58PM +0300, Ivan Safonov wrote: > DIV_ROUND_UP is bit useful than series of "/" and "%" operations. > Replace "/%" sequence with DIV_ROUND_UP macro. > > Signed-off-by: Ivan Safonov Applied. Thanks. -Bin. > --- > Changes in v2: > - little style fix > > drivers/us

Re: [PATCH] usb-musb: keep VBUS on when device is disconnected

2017-03-27 Thread Bin Liu
On Mon, Mar 27, 2017 at 09:59:47AM -0700, Tony Lindgren wrote: > * Moreno Bartalucci [170327 09:23]: > > If I understood your patch, however, if the device (anyone, not just my > > one) takes longer to switch, VBUS is deasserted anyway. > > Yeah some of them can take at least 10 seconds even to

Re: [PATCH] uvc-gadget: Fix Set Interface (alternate setting) response behaviour

2017-03-06 Thread Bin Liu
On Mon, Mar 06, 2017 at 04:29:33PM +0200, Felipe Balbi wrote: > > Hi, > > Roger Quadros writes: > > <<< No Message Collected >>> > > You need to resend this. See also [1] Not sure what is wrong. This happens to me too, see [2]. And I sent the patch v2 an hour ago, but the patch is still not on

Re: [PATCH] usb: musb: da8xx: Don't print phy error on -EPROBE_DEFER

2016-11-03 Thread Bin Liu
On Wed, Nov 02, 2016 at 10:45:59PM +0100, Ladislav Michl wrote: > Hi, > > On Tue, Oct 25, 2016 at 02:02:50PM -0500, David Lechner wrote: > > This suppresses printing the error message "failed to get phy" in the > > kernel log when the error is -EPROBE_DEFER. This prevents usless noise > > in the k

Re: [PATCH v3 5/5] usb: musb: da8xx: Remove set_mode callback

2016-11-03 Thread Bin Liu
On Thu, Nov 03, 2016 at 12:18:53PM -0500, David Lechner wrote: > On 11/03/2016 10:26 AM, Alexandre Bailon wrote: > >The USB PHY is able to operate in OTG, host or peripheral. > >Some board may be wired to work act only as host or peripheral. > >In such case, the dr_mode property of controller must

Re: [PATCH v2] usb: musb: add code comment for clarification

2017-02-14 Thread Bin Liu
On Tue, Feb 14, 2017 at 10:25:11AM -0800, Greg KH wrote: > On Tue, Feb 14, 2017 at 12:20:39PM -0600, Gustavo A. R. Silva wrote: > > Add code comment to make it clear that the fall-through is intentional. > > Read the link for more details: https://lkml.org/lkml/2017/2/9/292 > > > > Addresses-Cover

Re: [PATCH] drivers: usb: musb: add code comment for clarification

2017-02-10 Thread Bin Liu
On Thu, Feb 09, 2017 at 09:56:54PM -0600, Gustavo A. R. Silva wrote: > Add code comment to make it clear that the fall-through is intentional. > Read the link for more details: https://lkml.org/lkml/2017/2/9/292 > Don't need 'drivers:' in the subject. > Signed-off-by: Gustavo A. R. Silva > ---

Re: drivers: usb: musb: question about missing break in switch

2017-02-09 Thread Bin Liu
On Thu, Feb 09, 2017 at 02:37:34AM -0600, Gustavo A. R. Silva wrote: > Hello everybody, > > I ran into the following piece of code at > drivers/usb/musb/musb_core.c:1854 (linux-next) > > 1854/* > 1855 * Check the musb devctl session bit to determine if we want to > 1856 * allow PM runtime for the

Re: [PATCH 4/4] ARM: dts: sun8i: add OTG function to Lichee Pi Zero

2017-01-10 Thread Bin Liu
On Tue, Jan 03, 2017 at 11:25:34PM +0800, Icenowy Zheng wrote: > Lichee Pi Zero features a USB OTG port. > > Add support for it. > > Note: in order to use the Host mode, the board must be powered via the > +5V and GND pins. > > Signed-off-by: Icenowy Zheng > --- > arch/arm/boot/dts/sun8i-v3s-l

Re: [PATCH v2] usb: musb: sunxi: Uses the resource-managed extcon API when registering extcon notifier

2017-01-10 Thread Bin Liu
On Tue, Jan 10, 2017 at 05:20:38PM +0900, Chanwoo Choi wrote: > Hi Felipe, > > This patch got the acked-by from Bin Liu and. > Could you please apply this patch? I have picked this one. Regards, -Bin. > > On 2016년 12월 30일 13:19, Chanwoo Choi wrote: > > This patc

Re: [PATCH 4/4] ARM: dts: sun8i: add OTG function to Lichee Pi Zero

2017-01-11 Thread Bin Liu
On Thu, Jan 12, 2017 at 03:55:33AM +0800, Icenowy Zheng wrote: > > > 11.01.2017, 04:24, "Bin Liu" : > > On Tue, Jan 03, 2017 at 11:25:34PM +0800, Icenowy Zheng wrote: > >>  Lichee Pi Zero features a USB OTG port. > >> > >>  Add support for it.

<    1   2   3   >