Re: [PATCH] USB: cp210x: add ID for ELV Marble Sound Board 1.

2015-12-28 Thread Johan Hovold
On Sun, Dec 27, 2015 at 08:49:22PM +0100, Oliver Freyermuth wrote: > Dear kernel-hackers, > > this adds the PID and VID for the ELV Marble Sound Board which uses a > CP2102 as USB-serial converter. > I hope linux-usb is the correct list for this patch, otherwise please > redirect me. > > Details

[PATCH] ehci-hcd: Disable memory-write-invalidate when the driver is removed

2015-12-28 Thread Jia-Ju Bai
Signed-off-by: Jia-Ju Bai --- drivers/usb/host/ehci-hcd.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index 48c92bf..c02ec42 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c @@ -422,6 +422,7 @@ static

[PATCH] ehci-hcd: Cleanup memory resources when ehci_halt fails

2015-12-28 Thread Jia-Ju Bai
Signed-off-by: Jia-Ju Bai --- drivers/usb/host/ehci-hcd.c |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index 48c92bf..015b411 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c @@ -675,8

[PATCH 0/7][v5]Add OTG support for FSL socs

2015-12-28 Thread Ramneek Mehresh
Add support for otg for all freescale socs having internal usb phy. Ramneek Mehresh (7): usb:fsl:otg: Make fsl otg driver as tristate usb:fsl:otg: Add controller version based ULPI and UTMI phy usb:fsl:otg: Add support to add/remove usb host driver usb:fsl:otg: Signal host drv when host is

[PATCH 1/7][v5]usb:fsl:otg: Make fsl otg driver as tristate

2015-12-28 Thread Ramneek Mehresh
Provide option to load fsl otg driver as loadable module. Signed-off-by: Ramneek Mehresh --- drivers/usb/phy/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/phy/Kconfig b/drivers/usb/phy/Kconfig index 22e8ecb..b6de4a7 100644 --- a/drivers/usb/phy/Kconfig +

[PATCH 6/7][v5]usb:fsl:otg: Combine host/gadget start/resume for ID change

2015-12-28 Thread Ramneek Mehresh
Make call to fsl_otg_event for each id change even. Signed-off-by: Ramneek Mehresh Reviewed-by: Fleming Andrew-AFLEMING Tested-by: Fleming Andrew-AFLEMING --- drivers/usb/phy/phy-fsl-usb.c | 15 +++ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/drivers/usb/phy/phy-

[PATCH 7/7][v5]usb:fsl:otg: Add host-gadget drv sync delay

2015-12-28 Thread Ramneek Mehresh
Resolve synchronization issue between host and gadget drivers upon role-reversal. Signed-off-by: Ramneek Mehresh Reviewed-by: Li Yang-R58472 Reviewed-by: Fleming Andrew-AFLEMING Tested-by: Fleming Andrew-AFLEMING --- drivers/usb/phy/phy-fsl-usb.c | 12 +++- 1 file changed, 11 insertio

[PATCH 5/7][v5]usb:fsl:otg: Modify otg_event to start host drv

2015-12-28 Thread Ramneek Mehresh
Add mechanism to start host driver from inside fsl_otg_even upon each id change interrupt. Signed-off-by: Ramneek Mehresh Reviewed-by: Fleming Andrew-AFLEMING Tested-by: Fleming Andrew-AFLEMING --- drivers/usb/phy/phy-fsl-usb.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/us

[PATCH 2/7][v5]usb:fsl:otg: Add controller version based ULPI and UTMI phy

2015-12-28 Thread Ramneek Mehresh
Add controller version based ULPI and UTMI phy initialization for otg driver. Signed-off-by: Shengzhou Liu Signed-off-by: Ramneek Mehresh Reviewed-by: Fleming Andrew-AFLEMING Tested-by: Fleming Andrew-AFLEMING --- drivers/usb/phy/phy-fsl-usb.c | 20 drivers/usb/phy/phy-fs

[PATCH 4/7][v5]usb:fsl:otg: Signal host drv when host is otg

2015-12-28 Thread Ramneek Mehresh
Set is_otg boolean flag to signal host driver when host is running in context of otg host suspend/resume. Signed-off-by: Ramneek Mehresh --- drivers/usb/phy/phy-fsl-usb.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/usb/phy/phy-fsl-usb.c b/drivers/usb/phy/phy

[PATCH 3/7][v5]usb:fsl:otg: Add support to add/remove usb host driver

2015-12-28 Thread Ramneek Mehresh
Add workqueue to add/remove host driver (outside interrupt context) upon each id change, and to remove host driver upon otg initialization by changing have_hcd variable. Signed-off-by: Li Yang Signed-off-by: Ramneek Mehresh Reviewed-by: Alan Stern --- drivers/usb/host/ehci-fsl.c | 73 +

Re: [PATCH] Add support for usbfs zerocopy.

2015-12-28 Thread Steinar H. Gunderson
On Fri, Dec 25, 2015 at 01:36:44PM -0500, Alan Stern wrote: > That's okay; lots of drivers do this and people expect it. It also > reduces the total amount of code. Okay, fixed. > > > > + mem = usb_alloc_coherent(ps->dev, size, GFP_KERNEL, > > > > &dma_handle); > > > Shouldn't this be GF

[PATCH] Add support for usbfs zerocopy.

2015-12-28 Thread Steinar H. Gunderson
Add a new interface for userspace to preallocate memory that can be used with usbfs. This gives two primary benefits: - Zerocopy; data no longer needs to be copied between the userspace and the kernel, but can instead be read directly by the driver from userspace's buffers. This works for a

Re: [PATCH 4/4] HID: usbhid: use to_usb_device

2015-12-28 Thread Jiri Kosina
On Wed, 23 Dec 2015, Geliang Tang wrote: > Use to_usb_device() instead of open-coding it. > > Signed-off-by: Geliang Tang > --- > drivers/hid/usbhid/usbhid.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/hid/usbhid/usbhid.h b/drivers/hid/usbhid/usbhid.h > ind

Re: [PATCH v5] USB: serial: add Moxa UPORT 11x0 driver

2015-12-28 Thread Johan Hovold
On Sun, Dec 06, 2015 at 12:29:43PM +0100, Mathieu OTHACEHE wrote: > Add a driver which supports : > > - UPort 1110 : 1 port RS-232 USB to Serial Hub. > - UPort 1130 : 1 port RS-422/485 USB to Serial Hub. > - UPort 1130I : 1 port RS-422/485 USB to Serial Hub with Isolation. > - UPort 1150 : 1 po

Re: [PATCH v5] USB: serial: add Moxa UPORT 11x0 driver

2015-12-28 Thread One Thousand Gnomes
> https://lkml.kernel.org/r/201102171210.03474.fr...@tennebo.com > > However, the TIOCSRS485-ioctl might not even be the right interface for > changing transceiver modes, and instead a sysfs-based > usb-serial-specific interface could be more appropriate for example. sysfs works out very ba

Re: [PATCH] ehci-hcd: Disable memory-write-invalidate when the driver is removed

2015-12-28 Thread Sergei Shtylyov
Hello. On 12/28/2015 01:36 PM, Jia-Ju Bai wrote: Signed-off-by: Jia-Ju Bai --- drivers/usb/host/ehci-hcd.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index 48c92bf..c02ec42 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b

Re: [PATCH v5] USB: serial: add Moxa UPORT 11x0 driver

2015-12-28 Thread Johan Hovold
On Mon, Dec 28, 2015 at 02:39:44PM +, One Thousand Gnomes wrote: > > https://lkml.kernel.org/r/201102171210.03474.fr...@tennebo.com > > > > However, the TIOCSRS485-ioctl might not even be the right interface for > > changing transceiver modes, and instead a sysfs-based > > usb-serial-speci

Re: [PATCH] ehci-hcd: Disable memory-write-invalidate when the driver is removed

2015-12-28 Thread Alan Stern
On Mon, 28 Dec 2015, Jia-Ju Bai wrote: -ENOCHANGELOG Why do you want to disable MWI in the first place? And why disable it here? Shouldn't it be disabled in the same source file that enabled it originally? (Actually in this case that's not possible. It might be better to move the code that

[PATCH] USB: cp210x: add ID for ELV Marble Sound Board 1. (resent)

2015-12-28 Thread Oliver Freyermuth
Dear kernel-hackers, dear Johan, thanks for your assistance, and the hint to the documentation, as you may have guessed, that's my first patch - I hereby resend it inline and added the signed-off-by statement. Cheers and thanks, Oliver >From 743e9446334c973ef4a740b2b38effc8a5dd0693

Re: [PATCH] ehci-hcd: Cleanup memory resources when ehci_halt fails

2015-12-28 Thread Alan Stern
On Mon, 28 Dec 2015, Jia-Ju Bai wrote: Please add a changelog. > Signed-off-by: Jia-Ju Bai > --- > drivers/usb/host/ehci-hcd.c |4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c > index 48c92bf..015b411 10064

[PATCH 2/5] usb: dwc2: gadget: fix TX FIFO size and address initialization

2015-12-28 Thread Robert Baldyga
According to DWC2 documentation, DPTxFSize field of DPTXFSIZn register is read only, which means that software cannot change FIFO size. Register description says: "The value of this register is the Largest Device Mode Periodic Tx Data FIFO Depth (parameter OTG_TX_DPERIO_DFIFO_DEPTH_n), as specifie

[PATCH 4/5] usb: dwc2: gadget: remove dead code from dwc2_hsotg_ep_enable()

2015-12-28 Thread Robert Baldyga
Since FIFO is always freed in dwc2_hsotg_ep_disable(), ep->fifo_index is always 0 in dwc2_hsotg_ep_enable(), hence code inside if() block is never executed. Signed-off-by: Robert Baldyga --- drivers/usb/dwc2/gadget.c | 13 + 1 file changed, 1 insertion(+), 12 deletions(-) diff --git

[PATCH 3/5] usb: dwc2: gadget: change variable name to more meaningful

2015-12-28 Thread Robert Baldyga
Since we handle FIFOs and endpoint separately, using variable named 'ep' in context of FIFO is misleading, hence we rename it to 'fifo'. Signed-off-by: Robert Baldyga --- drivers/usb/dwc2/gadget.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/usb/dwc2/gadget

[PATCH 5/5] usb: dwc2: gadget: free TX FIFO after killing requests

2015-12-28 Thread Robert Baldyga
As kill_all_requests() potentially flushes TX FIFO, we should should free FIFO after calling it. Otherwise FIFO could stay unflushed properly. Signed-off-by: Robert Baldyga --- drivers/usb/dwc2/gadget.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/usb/dwc2/

[PATCH 0/5] usb: dwc2: gadget: Fix TX FIFO handling

2015-12-28 Thread Robert Baldyga
Hello, This patch series fixes TX FIFO handling in UDC part of DWC2 driver. It gets rid of few bugs, improves compliance with DWC2 documentation and cleanes up driver code. More detailed description is provided in commit messages. Best regards, Robert Baldyga Robert Baldyga (5): usb: dwc2: gad

[PATCH 1/5] usb: dwc2: gadget: use ep->fifo_index in context of FIFO registers

2015-12-28 Thread Robert Baldyga
In context of FIFO registers we use ep->fifo_index instead of ep->index. Signed-off-by: Robert Baldyga --- drivers/usb/dwc2/gadget.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c index 4e9fc92..773d121 100644 --- a/

Re: [PATCH] USB: cp210x: add ID for ELV Marble Sound Board 1. (resent)

2015-12-28 Thread Johan Hovold
On Mon, Dec 28, 2015 at 05:03:19PM +0100, Oliver Freyermuth wrote: > Dear kernel-hackers, dear Johan, > > thanks for your assistance, and the hint to the documentation, > as you may have guessed, that's my first patch - > I hereby resend it inline and added the signed-off-by statement. Thanks

[PATCH v3] USB: cp210x: add ID for ELV Marble Sound Board 1.

2015-12-28 Thread Oliver Freyermuth
Add the USB device ID for ELV Marble Sound Board 1. Signed-off-by: Oliver Freyermuth --- Dear kernel-hackers, dear Johan, thanks for all the help! This is v3, now sent with git-send-email which I found astonishingly easy to use, and without whitespace changes. I promise to make use of the newly

Re: [PATCH v3] USB: cp210x: add ID for ELV Marble Sound Board 1.

2015-12-28 Thread Johan Hovold
On Mon, Dec 28, 2015 at 06:37:38PM +0100, Oliver Freyermuth wrote: > Add the USB device ID for ELV Marble Sound Board 1. > > Signed-off-by: Oliver Freyermuth > --- > Dear kernel-hackers, dear Johan, > > thanks for all the help! > This is v3, now sent with git-send-email which I found astonishing

Re: 4.3.0: AUKEY CB-H16 13+2port USB3 VIA812 hub does not recognize Prolific-based USB3-SATA dongle

2015-12-28 Thread Martin MOKREJŠ
Hi Mathias, I re-tried if this issue exists with linux-4.4-rc7 and I reproduced it. Actually, with ASM-based USB3-to-SATA dongle instead of the one with Prolific chipset. I suspect it is maybe more prone to happen or even specific to my back side USB3.0 port of my Dell Vostro 3550 laptop, in

[PULL] Moxa UPORT 11x0 firmware

2015-12-28 Thread Mathieu OTHACEHE
Hi, Here is a pull request for firmware for Moxa UPORT 11x0 devices. The associated driver mxu11x0 is almost ready for merging: https://lkml.org/lkml/2015/12/6/43 Thanks, Mathieu The following changes since commit bbe4917c054eb0a73e250c6363341e3bf6725839: WHENCE: use https://linuxtv.org for

[PATCH v6] USB: serial: add Moxa UPORT 11x0 driver

2015-12-28 Thread Mathieu OTHACEHE
Add a driver which supports : - UPort 1110 : 1 port RS-232 USB to Serial Hub. - UPort 1130 : 1 port RS-422/485 USB to Serial Hub. - UPort 1130I : 1 port RS-422/485 USB to Serial Hub with Isolation. - UPort 1150 : 1 port RS-232/422/485 USB to Serial Hub. - UPort 1150I : 1 port RS-232/422/485 USB

Re: [PATCH v2] usb: gadget: fix double mem free for usb_request caused by wild pointers

2015-12-28 Thread Laurent Pinchart
Hi Changbin, Thank you for the patch. On Monday 28 December 2015 14:25:50 changbin...@intel.com wrote: > From: "Du, Changbin" > > acm, ecm, hid, ncm, phonet, rndis and uvc functions all have double > memory free issue. Set pointers to NULL after freed to avoid this. For drivers/usb/gadget/func

Re: [PATCH v2] usb: gadget: fix double mem free for usb_request caused by wild pointers

2015-12-28 Thread Robert Baldyga
Hi, On 12/28/2015 07:25 AM, changbin...@intel.com wrote: > From: "Du, Changbin" > > acm, ecm, hid, ncm, phonet, rndis and uvc functions all have double > memory free issue. Set pointers to NULL after freed to avoid this. > > Here explain how it happen on acm function, others has analogical case

usb: wrong compatible string for MX23?

2015-12-28 Thread Stefan Wahren
Hi Peter, i was inspired by the discussion about the USB runtime suspend issue on MX28. I think i've found another issue. In the dtsi for the MX23 the usb node has the following compatible: usb0: usb@8008 { compatible = "fsl,imx23-usb", "fsl,imx27-usb"; ... But in ci_hdrc_imx.c there

[PATCH] usb: phy: mxs: Remove unused flags

2015-12-28 Thread Fabio Estevam
From: Fabio Estevam MXS_PHY_ABNORMAL_IN_SUSPEND and MXS_PHY_SENDING_SOF_TOO_FAST flags are never used, so let's get rid of them. Reported-by: Stefan Wahren Signed-off-by: Fabio Estevam --- drivers/usb/phy/phy-mxs-usb.c | 31 +++ 1 file changed, 3 insertions(+), 28

Re: usb: wrong compatible string for MX23?

2015-12-28 Thread Peter Chen
On Tue, Dec 29, 2015 at 12:45:51AM +0100, Stefan Wahren wrote: > Hi Peter, > > i was inspired by the discussion about the USB runtime suspend issue on MX28. > I > think i've found another issue. > In the dtsi for the MX23 the usb node has the following compatible: > > usb0: usb@8008 { >

[PATCH 1/1] usb: cdc-acm: handle unlinked urb in acm read callback

2015-12-28 Thread Lu Baolu
In current acm driver, the bulk-in callback function ignores the URBs unlinked in usb core. This causes unexpected data loss in some cases. For example, runtime suspend entry will unlinked all urbs and set urb->status to -ENOENT even those urbs might have data not processed yet. Hence, data loss o

[PATCH] usb: f_fs: avoid race condition with ffs_epfile_io_complete

2015-12-28 Thread changbin . du
From: "Du, Changbin" ffs_epfile_io and ffs_epfile_io_complete runs in different context, but there is no synchronization between them. consider the following scenario: 1) ffs_epfile_io interrupted by sigal while wait_for_completion_interruptible 2) then ffs_epfile_io set ret to -EINTR 3) just be