[PATCH 3/5] USB: serial: f81232: enable remote wakeup via RX/RI pin

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
The F81232 can do remote wakeup via RX/RI pin with pulse. This patch will use device_set_wakeup_enable to enable this feature. Signed-off-by: Ji-Ze Hong (Peter Hong) --- drivers/usb/serial/f81232.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH 5/5] USB: serial: f81232: fix bulk_in/out size

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
Fix Fintek F81232 bulk_in/out size to 64/16 according to the spec. http://html.alldatasheet.com/html-pdf/406315/FINTEK/F81232/1762/8/F81232.html Signed-off-by: Ji-Ze Hong (Peter Hong) --- drivers/usb/serial/f81232.c | 3 +-- 1 file changed, 1 insertion(+), 2

[PATCH 2/5] USB: serial: f81232: add high baud rate support

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
The F81232 had 4 clocksource 1.846/18.46/14.77/24MHz and baud rates can be up to 1.5Mbits with 24MHz. F81232 Clock registers (106h) Bit1-0: Clock source selector 00: 1.846MHz. 01: 18.46MHz. 10: 24MHz. 11:

[PATCH 1/5] USB: serial: f81232: clear overrun flag

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
The F81232 will report data and LSR with bulk like following format: bulk-in data: [LSR(1Byte)+DATA(1Byte)][LSR(1Byte)+DATA(1Byte)]... LSR will auto clear frame/parity/break error flag when reading by H/W, but overrrun will only cleared when reading LSR. So this patch add a worker to read LSR

Re: [BUG] SD card reader disappears after suspend

2018-01-22 Thread Samuel Sadok
As requested by Chen Yu on bugzilla, I added no_console_suspend=1 to the kernel cmdline and updated to the (roughly) latest kernel, 4.14.14-1-ARCH. Here's the new log: https://pastebin.com/buhEMyKk >From a quick comparison with the old log I don't see any significant difference, except that

at91_udc Bug: USB gadget unplug not noticed by kernel

2018-01-22 Thread Ana Rodriguez Lopez
Hello Felipe, I am not an expert on Linux Kernel but I have a problem with the USB gadget and the origin seems to be there. I am working with Kernel 4.13.0 on Stamp 9G20 from Taskit GmbH (CPU: Atmel AT91SAM9G20 Embedded Processor featuring an ARM926EJ-STM ARM® Thumb® Core). The problem is, the

Re: [PATCH 1/5] USB: serial: f81232: clear overrun flag

2018-01-22 Thread Oliver Neukum
Am Montag, den 22.01.2018, 15:58 +0800 schrieb Ji-Ze Hong (Peter Hong) : > The F81232 will report data and LSR with bulk like following format: > bulk-in data: [LSR(1Byte)+DATA(1Byte)][LSR(1Byte)+DATA(1Byte)]... > > LSR will auto clear frame/parity/break error flag when reading by H/W, > but

Re: [PATCH v2] usb: phy: mxs: Fix NULL pointer dereference on i.MX23/28

2018-01-22 Thread Fabio Estevam
Hi Felipe, On Thu, Jan 18, 2018 at 12:22 AM, Fabio Estevam wrote: > From: Fabio Estevam > > Commit e93650994a95 ("usb: phy: mxs: add usb charger type detection") > causes the following kernel hang on i.MX28: > > [2.207973] usbcore: registered new

Re: at91_udc Bug: USB gadget unplug not noticed by kernel

2018-01-22 Thread Felipe Balbi
Hi, Ana Rodriguez Lopez writes: > Hello Felipe, > > I am not an expert on Linux Kernel but I have a problem with the USB > gadget and the origin seems to be there. > > I am working with Kernel 4.13.0 on Stamp 9G20 from Taskit GmbH (CPU: rather recent, kudos :-) >

[PATCH] usb: serial: keyspan: remove unused USB_SERIAL_KEYSPAN_X firmware kconfig

2018-01-22 Thread Corentin Labbe
All USB_SERIAL_KEYSPAN_X are not used anywhere in kernel tree. Furthermore all firmware files was removed since commit 2971c579f93bi ("keyspan: use request_firmware()") So let's clean thoses unused symbols. Signed-off-by: Corentin Labbe --- drivers/usb/serial/Kconfig

question concerning termios

2018-01-22 Thread Oliver Neukum
Hi, do you have any pointers about documentation concerning tty_std_termios? Is a driver allowed to change them for convinience? Regards Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org

Re: [PATCH 1/2] USB: storage: remove invalid URL from drivers

2018-01-22 Thread Alan Stern
On Mon, 22 Jan 2018, Greg Kroah-Hartman wrote: > The old URL for usb-storage driver help is long gone. So remove it from > the comments to not confuse people anymore. > > Reported-by: Matthew Dharm > Cc: Alan Stern > Signed-off-by:

[PATCH 2/2] usb: dwc3: drd: Fix lock-up on ID change during system suspend/resume

2018-01-22 Thread Roger Quadros
Adding/removing host/gadget controller before .pm_complete() causes a lock-up. Let's prevent any dual-role state change between .pm_prepare() and .pm_complete() to fix this. Signed-off-by: Roger Quadros --- drivers/usb/dwc3/core.c | 31 +++

[PATCH 1/2] usb: dwc3: omap: don't miss events during suspend/resume

2018-01-22 Thread Roger Quadros
The USB cable state can change during suspend/resume so be sure to check and update the extcon state. Signed-off-by: Roger Quadros --- drivers/usb/dwc3/dwc3-omap.c | 16 1 file changed, 16 insertions(+) diff --git a/drivers/usb/dwc3/dwc3-omap.c

[PATCH 0/2] usb: dwc3: Fix dual role during system suspend/resume

2018-01-22 Thread Roger Quadros
Hi Felipe, These patches address issues with system suspend/resume when we're in dual-role configuration and the ID pin state toggles while the system is suspended. This series depends on https://www.mail-archive.com/linux-usb@vger.kernel.org/msg98771.html Roger Quadros (2): usb: dwc3: omap:

[PATCH 4/4] ARM: dts: am43xx: Enable dual-role mode for USB1

2018-01-22 Thread Roger Quadros
USB1 port is micro-AB type and can function as peripheral as well as host. Enable dual-role mode for USB1. Signed-off-by: Roger Quadros --- arch/arm/boot/dts/am437x-gp-evm.dts | 2 +- arch/arm/boot/dts/am437x-sk-evm.dts | 2 +- arch/arm/boot/dts/am43x-epos-evm.dts | 2 +- 3

[PATCH 3/4] usb: dwc3: add dual role support using OTG block

2018-01-22 Thread Roger Quadros
This is useful on platforms (e.g. TI AM437x) that don't have ID available on a GPIO but do have the OTG block. We can obtain the ID state via the OTG block and use it for dual-role switching. Signed-off-by: Roger Quadros --- drivers/usb/dwc3/core.c | 73 +--

[PATCH 0/4] usb: dwc3: Add dual-role support using OTG core

2018-01-22 Thread Roger Quadros
Hi Felipe, Some platforms (e.g. TI's AM437x) don't have USB ID pin state available over GPIO/extcon but need to rely on the DWC3 core's OTG block to get the ID pin state instead. This series implements simple dual-role functionality using DWC3's OTG block. Debugfs 'mode' override is also

[PATCH 2/4] usb: dwc3: core.h: add some register definitions

2018-01-22 Thread Roger Quadros
Add OTG and GHWPARAMS6 register definitions Signed-off-by: Roger Quadros --- drivers/usb/dwc3/core.h | 82 + 1 file changed, 82 insertions(+) diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h index f5eb474..8006335

[PATCH 1/4] usb: dwc3: prevent setting PRTCAP to OTG from debugfs

2018-01-22 Thread Roger Quadros
We don't support PRTCAP == OTG so prevent user from setting it via debugfs. Signed-off-by: Roger Quadros --- drivers/usb/dwc3/core.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c index 85388dd..2929b1d 100644 ---

Re: [PATCH v4 0/7] typec: tcpm: Add sink side support for PPS

2018-01-22 Thread Greg Kroah-Hartman
On Tue, Jan 02, 2018 at 03:50:48PM +, Adam Thomson wrote: > This patch set adds sink side support for the PPS feature introduced in the > USB PD 3.0 specification. Heikki and Guenter, any thoughts on this patch series? thanks, greg k-h -- To unsubscribe from this list: send the line

Re: [PATCH v3 2/3] usb/gadget: Add an EP dispose() callback for EP lifetime tracking

2018-01-22 Thread Greg KH
On Fri, Jan 12, 2018 at 05:50:03PM +1100, Benjamin Herrenschmidt wrote: > Some UDC may want to allocate endpoints dynamically, either because > the HW supports an arbitrary large number or because (like the Aspeed > BMC SoCs), the pool of HW endpoints is shared between multiple gadgets. > > The

Re: [PATCH 2/5] USB: serial: f81232: add high baud rate support

2018-01-22 Thread Andy Shevchenko
On Mon, Jan 22, 2018 at 9:58 AM, Ji-Ze Hong (Peter Hong) wrote: > The F81232 had 4 clocksource 1.846/18.46/14.77/24MHz and baud rates > can be up to 1.5Mbits with 24MHz. > > F81232 Clock registers (106h) > > Bit1-0: Clock source selector > 00: 1.846MHz. >

Re: [PATCH 1/2] usb: misc: xapea00x: add driver for Xaptum ENF Access Card

2018-01-22 Thread Greg Kroah-Hartman
On Mon, Jan 22, 2018 at 09:07:34AM -0600, David R. Bild wrote: > On Mon, Jan 22, 2018 at 8:28 AM, Greg Kroah-Hartman > wrote: > > > > On Wed, Jan 10, 2018 at 10:58:29AM -0600, David R. Bild wrote: > > > +/** > > > + * xapea00x_spi_cleanup > > > + * > > > + * Context:

[PATCH 2/2] usb: gadget: udc: atmel: Consolidate error messages

2018-01-22 Thread Ladislav Michl
Use the same format for all error messages of driver probe function. Signed-off-by: Ladislav Michl --- drivers/usb/gadget/udc/atmel_usba_udc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/gadget/udc/atmel_usba_udc.c

[PATCH 1/2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Ladislav Michl
As devm_ioremap_resource() checks for valid resource, make use of it instead of testing ourselves. As a bonus memory region is requested. Signed-off-by: Ladislav Michl --- drivers/usb/gadget/udc/atmel_usba_udc.c | 40 - 1 file changed, 19

Re: [PATCH 4/4] ARM: dts: am43xx: Enable dual-role mode for USB1

2018-01-22 Thread Roger Quadros
+Tony On 22/01/18 15:11, Roger Quadros wrote: > USB1 port is micro-AB type and can function as peripheral > as well as host. Enable dual-role mode for USB1. > > Signed-off-by: Roger Quadros > --- > arch/arm/boot/dts/am437x-gp-evm.dts | 2 +- >

Re: [PATCH] CDC-ACM: apply quirk for card reader

2018-01-22 Thread Greg KH
On Thu, Jan 18, 2018 at 12:13:45PM +0100, Oliver Neukum wrote: > This devices drops random bytes from messages if you talk to it > too fast. > > Signed-off-by: Full name here please :( I'll go edit it, you should know better... greg k-h -- To unsubscribe from this list: send

Re: [PATCH 2/9] USB: storage: Remove redundant license text

2018-01-22 Thread Greg Kroah-Hartman
On Fri, Nov 03, 2017 at 01:32:38PM -0400, Alan Stern wrote: > On Fri, 3 Nov 2017, Greg Kroah-Hartman wrote: > > > On Fri, Nov 03, 2017 at 10:01:01AM -0700, Matthew Dharm wrote: > > > Alan, this might also be a good time to remove the "Please see [...] > > > for more information" bits also. That

Re: [PATCH 2/9] USB: storage: Remove redundant license text

2018-01-22 Thread Greg Kroah-Hartman
On Fri, Nov 03, 2017 at 10:01:01AM -0700, Matthew Dharm wrote: > Alan, this might also be a good time to remove the "Please see [...] > for more information" bits also. That URL hasn't worked for well, > a very very long time. Patch now sent out, thanks. greg k-h -- To unsubscribe from this

Re: [PATCH] USB TYPEC: RT1711H Type-C Chip Driver

2018-01-22 Thread Guenter Roeck
On Mon, Jan 22, 2018 at 02:01:13AM +, shufan_lee(李書帆) wrote: > Dear Heikki and Guenter, > > Because there are still other controls of RT1711H that are different from > standard TCPCI, e.x. flow of drp toggling. > > Is the suggestion to customize the difference based on tcpci.c for

[PATCH v3 1/2] usb/gadget: Add an EP dispose() callback for EP lifetime tracking

2018-01-22 Thread Benjamin Herrenschmidt
Some UDC may want to allocate endpoints dynamically, either because the HW supports an arbitrary large number or because (like the Aspeed BMC SoCs), the pool of HW endpoints is shared between multiple gadgets. The allocation side can be done rather easily using the existing match_ep() UDC hook.

[PATCH v3 2/2] usb/gadget: Add driver for Aspeed SoC virtual hub

2018-01-22 Thread Benjamin Herrenschmidt
The Aspeed BMC SoCs support a "virtual hub" function. It provides some HW support for a top-level USB2 hub behind which sit 5 gadget "ports". This driver adds support for the full functionality, emulating the hub standard requests and exposing 5 UDC gadget drivers corresponding to the ports. The

Re: [BUG] SD card reader disappears after suspend

2018-01-22 Thread Alan Stern
On Mon, 22 Jan 2018, Samuel Sadok wrote: > As requested by Chen Yu on bugzilla, I added no_console_suspend=1 to > the kernel cmdline and updated to the (roughly) latest kernel, > 4.14.14-1-ARCH. > > Here's the new log: > https://pastebin.com/buhEMyKk > > From a quick comparison with the old log

Re: [PATCH v3 2/3] usb/gadget: Add an EP dispose() callback for EP lifetime tracking

2018-01-22 Thread Benjamin Herrenschmidt
On Mon, 2018-01-22 at 15:33 +0100, Greg KH wrote: > On Fri, Jan 12, 2018 at 05:50:03PM +1100, Benjamin Herrenschmidt wrote: > > Some UDC may want to allocate endpoints dynamically, either because > > the HW supports an arbitrary large number or because (like the Aspeed > > BMC SoCs), the pool of

Re: question concerning termios

2018-01-22 Thread Johan Hovold
On Mon, Jan 22, 2018 at 01:50:16PM +0100, Oliver Neukum wrote: > Hi, > > do you have any pointers about documentation > concerning tty_std_termios? Is a driver allowed > to change them for convinience? No, I'm not aware of any documentation, I'm afraid. But a driver may use tty_std_termios to

Re: [PATCH v2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Nicolas Ferre
On 23/01/2018 at 00:05, Ladislav Michl wrote: > As devm_ioremap_resource() checks for valid resource, > make use of it instead of testing ourselves. As a bonus > memory region is requested. > > Signed-off-by: Ladislav Michl Acked-by: Nicolas Ferre

Re: [PATCH 1/5] USB: serial: f81232: clear overrun flag

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
Hi Oliver, Oliver Neukum 於 2018/1/22 下午 06:06 寫道: +static void f81232_lsr_worker(struct work_struct *work) +{ + struct f81232_private *priv; + struct usb_serial_port *port; + int status; + u8 tmp; + + priv = container_of(work, struct f81232_private, lsr_work); +

Re: [PATCH 2/5] USB: serial: f81232: add high baud rate support

2018-01-22 Thread Ji-Ze Hong (Peter Hong)
Hi Andy, Andy Shevchenko 於 2018/1/22 下午 10:55 寫道: On Mon, Jan 22, 2018 at 9:58 AM, Ji-Ze Hong (Peter Hong) wrote: The F81232 had 4 clocksource 1.846/18.46/14.77/24MHz and baud rates can be up to 1.5Mbits with 24MHz. F81232 Clock registers (106h) Bit1-0: Clock source

Re: [PATCH 2/2] usb: dwc3: drd: Fix lock-up on ID change during system suspend/resume

2018-01-22 Thread Manu Gautam
Hi, On 1/22/2018 6:31 PM, Roger Quadros wrote: > Adding/removing host/gadget controller before .pm_complete() > causes a lock-up. Let's prevent any dual-role state change > between .pm_prepare() and .pm_complete() to fix this. What kind of lock-up are you seeing? Some hardware lockup or

Re: [PATCH 1/2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Sergei Shtylyov
Hello! On 01/22/2018 06:21 PM, Ladislav Michl wrote: > As devm_ioremap_resource() checks for valid resource, > make use of it instead of testing ourselves. As a bonus > memory region is requested. > > Signed-off-by: Ladislav Michl > --- >

Re: [PATCH 1/2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Ladislav Michl
Hello Sergei, On Mon, Jan 22, 2018 at 06:34:21PM +0300, Sergei Shtylyov wrote: > Hello! > > On 01/22/2018 06:21 PM, Ladislav Michl wrote: > > > As devm_ioremap_resource() checks for valid resource, > > make use of it instead of testing ourselves. As a bonus > > memory region is requested. > >

Re: [PATCH 1/2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Sergei Shtylyov
On 01/22/2018 06:44 PM, Ladislav Michl wrote: >>> As devm_ioremap_resource() checks for valid resource, >>> make use of it instead of testing ourselves. As a bonus >>> memory region is requested. >>> >>> Signed-off-by: Ladislav Michl >>> --- >>>

[PATCH v2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Ladislav Michl
As devm_ioremap_resource() checks for valid resource, make use of it instead of testing ourselves. As a bonus memory region is requested. Signed-off-by: Ladislav Michl --- Changes: - v2: Drop uneeded error message drivers/usb/gadget/udc/atmel_usba_udc.c | 34

Re: [PATCH 1/2] usb: gadget: udc: atmel: Use devm_ioremap_resource()

2018-01-22 Thread Ladislav Michl
On Mon, Jan 22, 2018 at 06:53:38PM +0300, Sergei Shtylyov wrote: > On 01/22/2018 06:44 PM, Ladislav Michl wrote: > > >>> As devm_ioremap_resource() checks for valid resource, > >>> make use of it instead of testing ourselves. As a bonus > >>> memory region is requested. > >>> > >>> Signed-off-by:

Re: [PATCH v4 0/7] typec: tcpm: Add sink side support for PPS

2018-01-22 Thread Guenter Roeck
On Mon, Jan 22, 2018 at 03:31:29PM +0100, Greg Kroah-Hartman wrote: > On Tue, Jan 02, 2018 at 03:50:48PM +, Adam Thomson wrote: > > This patch set adds sink side support for the PPS feature introduced in the > > USB PD 3.0 specification. > > Heikki and Guenter, any thoughts on this patch

Re: [PATCH 1/2] usb: misc: xapea00x: add driver for Xaptum ENF Access Card

2018-01-22 Thread David R. Bild
On Mon, Jan 22, 2018 at 8:28 AM, Greg Kroah-Hartman wrote: > > On Wed, Jan 10, 2018 at 10:58:29AM -0600, David R. Bild wrote: > > +/** > > + * xapea00x_spi_cleanup > > + * > > + * Context: !in_interrupt() > > + */ > > No need to have kerneldoc formatting for static

Re: [PATCH 1/2] usb: misc: xapea00x: add driver for Xaptum ENF Access Card

2018-01-22 Thread Greg Kroah-Hartman
On Wed, Jan 10, 2018 at 10:58:29AM -0600, David R. Bild wrote: > +/** > + * xapea00x_spi_cleanup > + * > + * Context: !in_interrupt() > + */ No need to have kerneldoc formatting for static functions, nor the whole Context thing, but it's your code to maintain over time, not mine :) > +static

[PATCH 2/2] USB: storage: remove old wording about how to submit a change

2018-01-22 Thread Greg Kroah-Hartman
It's best to just send new updates to the usb-storage quirk table to the linux-usb@vger.kernel.org mailing list, no need to bother Phil and Alan or the almost defunct usb-storage list. Reported-by: Alan Stern Cc: Matthew Dharm Cc: Phil

[PATCH 1/2] USB: storage: remove invalid URL from drivers

2018-01-22 Thread Greg Kroah-Hartman
The old URL for usb-storage driver help is long gone. So remove it from the comments to not confuse people anymore. Reported-by: Matthew Dharm Cc: Alan Stern Signed-off-by: Greg Kroah-Hartman ---