Re: [PATCH 2/3] usb: gadget: configfs: Create control_config group

2018-04-20 Thread Jerry Zhang
> The purpose would be: > 1) Allow writing no descriptors (maybe also skip the strings) when this > flag is set This should be straightforward. I'd rather not skip the strings though since we can already indicate zero strings in the current struct. If we skip strings then the difference between

Re: Representative Needed.

2018-04-20 Thread PPMC OFFSHORE
Good day, I am seeking your concept with great gratitude to present you as a representative to carry out business transactions with a reasonable share upon your interest and cooperation to work with us in trust. If interested please get back. Regards Kingsley --- This email has been

[PATCH v3] usb: mon: Change return type to vm_fault_t

2018-04-20 Thread Souptick Joarder
Use new return type vm_fault_t for the fault handler in struct vm_operations_struct. For now, this is just documenting that the function returns a VM_FAULT value rather than an errno. Once all instances are converted, vm_fault_t will become a distinct type. Reference id -> 1c8f422059ae ("mm:

[PATCH] usb: musb: trace: fix NULL pointer dereference in musb_g_tx()

2018-04-20 Thread Bin Liu
The usb_request pointer could be NULL in musb_g_tx(), where the tracepoint call would trigger the NULL pointer dereference failure when parsing the members of the usb_request pointer. Move the tracepoint call to where the usb_request pointer is already checked to solve the issue. Fixes:

Re: howto debug xhci driver?

2018-04-20 Thread Bin Liu
Hi, On Tue, Mar 20, 2018 at 02:28:00PM -0700, Paul Zimmerman wrote: > Forgot to CC linux-usb. > > > Forwarded Message > Subject: Re: howto debug xhci driver? > Date: Tue, 20 Mar 2018 13:56:21 -0700 > From: Paul Zimmerman > To: Bin Liu > CC:

Re: [PATCH V5] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Alan Stern
On Fri, 20 Apr 2018, Ravi Chandra Sadineni wrote: > On chromebooks we depend on wakeup count to identify the wakeup source. > But currently USB devices do not increment the wakeup count when they > trigger the remote wake. This patch addresses the same. > > Resume condition is reported

Re: [PATCH V3] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Ravi Chandra Sadineni
On Fri, Apr 20, 2018 at 10:29 AM, Alan Stern wrote: > On Fri, 20 Apr 2018, Ravi Chandra Sadineni wrote: > >> On chromebooks we depend on wakeup count to identify the wakeup source. >> But currently USB devices do not increment the wakeup count when they >> trigger the

[PATCH V5] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Ravi Chandra Sadineni
On chromebooks we depend on wakeup count to identify the wakeup source. But currently USB devices do not increment the wakeup count when they trigger the remote wake. This patch addresses the same. Resume condition is reported differently on USB 2.0 and USB 3.0 devices. On USB 2.0 devices, a

[PATCH V4] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Ravi Chandra Sadineni
On chromebooks we depend on wakeup count to identify the wakeup source. But currently USB devices do not increment the wakeup count when they trigger the remote wake. This patch addresses the same. Resume condition is reported differently on USB 2.0 and USB 3.0 devices. On USB 2.0 devices, a

RE: [PATCH 1/1] drivers: usb: Introduce FSL_USB2_PHY_UTMI_DUAL for usb gadget

2018-04-20 Thread Leo Li
> -Original Message- > From: Tiago Brusamarello [mailto:tbr...@gmail.com] > Sent: Thursday, April 19, 2018 6:58 AM > To: Leo Li > Cc: nikhil.bad...@freescale.com; linux-usb@vger.kernel.org > Subject: [PATCH 1/1] drivers: usb: Introduce FSL_USB2_PHY_UTMI_DUAL for >

Re: [PATCH V3] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Alan Stern
On Fri, 20 Apr 2018, Ravi Chandra Sadineni wrote: > On chromebooks we depend on wakeup count to identify the wakeup source. > But currently USB devices do not increment the wakeup count when they > trigger the remote wake. This patch addresses the same. > > Resume condition is reported

Re: [PATCH 1/2] usb: typec: tps6598x: handle block reads separately with plain-I2C adapters

2018-04-20 Thread Guenter Roeck
On Wed, Apr 18, 2018 at 03:34:09PM +0300, Heikki Krogerus wrote: > If the I2C adapter that the PD controller is attached to > does not support SMBus protocol, the driver needs to handle > block reads separately. The first byte returned in block > read protocol will show the total number of bytes.

Re: [PATCH v5 0/5] usb: typec: remove max_snk_mv/ma/mw

2018-04-20 Thread Guenter Roeck
On Mon, Apr 16, 2018 at 02:54:32PM +0800, Li Jun wrote: > This patch set is to remove max_snk_mv/ma/mw configs, as we should > define the sink capability by sink PDOs, the first patch update > the source PDO match policy by compare the voltage range between > source and sink PDOs no matter what

Re: [PATCH V2] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Ravi Chandra Sadineni
On Fri, Apr 20, 2018 at 7:12 AM, Alan Stern wrote: > On Thu, 19 Apr 2018, Ravi Chandra Sadineni wrote: > >> On chromebooks we depend on wakeup count to identify the wakeup source. >> But currently USB devices do not increment the wakeup count when they >> trigger the

[PATCH V3] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Ravi Chandra Sadineni
On chromebooks we depend on wakeup count to identify the wakeup source. But currently USB devices do not increment the wakeup count when they trigger the remote wake. This patch addresses the same. Resume condition is reported differently on USB 2.0 and USB 3.0 devices. On USB 2.0 devices, a

Re: BUG xhci_hcd usb3 module WARNS with JMicron JMS567 when writing to disk

2018-04-20 Thread Tomas M
Hello Menion. Yes, Ive already circunvented it connecting to a USB2 port instead. It would be nice to have this feature working. that is all. ehci-pci kernel module works. xhci-hcd kernel module fails. on both cases its running as UAS, but one module is broken. Are you sure the issue is with

Re: [PATCH v5 1/5] usb: typec: tcpm: pdo matching optimization

2018-04-20 Thread Guenter Roeck
On Fri, Apr 20, 2018 at 06:13:30PM +0300, Heikki Krogerus wrote: > Hi, > > On Mon, Apr 16, 2018 at 02:54:33PM +0800, Li Jun wrote: > > This patch is a combination of commit 57e6f0d7b804 > > ("typec: tcpm: Only request matching pdos") and source > > pdo selection optimization based on it, instead

Re: [PATCH v4 0/3] lan78xx: Read configuration from Device Tree

2018-04-20 Thread David Miller
From: Phil Elwell Date: Thu, 19 Apr 2018 17:59:37 +0100 > The Microchip LAN78XX family of devices are Ethernet controllers with > a USB interface. Despite being discoverable devices it can be useful to > be able to configure them from Device Tree, particularly in low-cost >

Re: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Hans de Goede
Hi, On 04/20/2018 04:13 PM, Guenter Roeck wrote: On 04/20/2018 03:51 AM, Jun Li wrote: -Original Message- From: Hans de Goede [mailto:hdego...@redhat.com] Sent: 2018年4月20日 17:21 To: Jun Li ; li...@roeck-us.net; heikki.kroge...@linux.intel.com Cc:

Re: [PATCH] usb: roles: intel_xhci: Don't use PMIC for port type identification

2018-04-20 Thread Hans de Goede
Hi, On 04/20/2018 04:35 PM, Heikki Krogerus wrote: On Fri, Apr 20, 2018 at 11:16:05AM +0200, Hans de Goede wrote: Hi Heikki, On 20-04-18 10:06, Heikki Krogerus wrote: This will add an array of known USB Type-C Port devices that will be used as a blacklist for enabling userspace-control, and

Re: [PATCH v5 5/5] usb: typec: tcpm: remove max_snk_mv/ma/mw

2018-04-20 Thread Heikki Krogerus
On Mon, Apr 16, 2018 at 02:54:37PM +0800, Li Jun wrote: > Since there is no user of max_snk_*, so we can remove them from tcpm. > > Reviewed-by: Hans de Goede > Signed-off-by: Li Jun Acked-by: Heikki Krogerus > --- >

Re: [PATCH v5 4/5] usb: typec: wcove: remove max_snk_* for sink config

2018-04-20 Thread Heikki Krogerus
On Mon, Apr 16, 2018 at 02:54:36PM +0800, Li Jun wrote: > Since max_snk_* is to be deprecated, so remove max_snk_* by adding a > variable PDO for sink config. > > Reviewed-by: Hans de Goede > Signed-off-by: Li Jun Acked-by: Heikki Krogerus

Re: [PATCH v5 2/5] usb: typec: fusb302: remove max_snk_* for sink config

2018-04-20 Thread Heikki Krogerus
On Mon, Apr 16, 2018 at 02:54:34PM +0800, Li Jun wrote: > Since max_snk_* is to be deprecated, so remove max_snk_* by adding a > variable PDO for sink config. > > Reviewed-by: Hans de Goede > Signed-off-by: Li Jun Acked-by: Heikki Krogerus

Re: [PATCH v5 1/5] usb: typec: tcpm: pdo matching optimization

2018-04-20 Thread Heikki Krogerus
Hi, On Mon, Apr 16, 2018 at 02:54:33PM +0800, Li Jun wrote: > This patch is a combination of commit 57e6f0d7b804 > ("typec: tcpm: Only request matching pdos") and source > pdo selection optimization based on it, instead of only > compare between the same pdo type of sink and source, > we should

Re: [PATCH v5 3/5] dt-bindings: usb: fusb302: remove max-sink-* properties

2018-04-20 Thread Heikki Krogerus
On Mon, Apr 16, 2018 at 02:54:35PM +0800, Li Jun wrote: > Remove max-sink-* properties since they are deprecated. > > Reviewed-by: Rob Herring > Reviewed-by: Hans de Goede > Signed-off-by: Li Jun FWIW: Revieved-by: Heikki Krogerus

Re: [PATCH 2/4] usb: gadget: composite: add function to increment delayed_status

2018-04-20 Thread Roger Quadros
Hi, On 19/04/18 22:42, Laurent Pinchart wrote: > Hi Paul, > > (CC'ing Felipe Balbi and Roger Quadros) > > Thank you for the patch. > > Have you used scripts/get_maintainer.pl ? It should point you to Felipe > Balbi, > the maintainer of the USB gadget subsystem, who I recommend you CC, at

Re: BUG xhci_hcd usb3 module WARNS with JMicron JMS567 when writing to disk

2018-04-20 Thread Menion
I think that JMS567 is mostly broken nowadays in Linux UAS Mine in an Orico multibay encolsure produce a lot of CMD timeout Recently Orico is just silently disabling in firmware the UAS support for this bridge (still advertising it on the webpage, usual chinese behaviour) Try to disable UAS with

Re: [PATCH v1 0/2] usb: dwc2: gadget: Fixes for LPM

2018-04-20 Thread Grigor Tovmasyan
Hi Balbi, On 4/10/2018 2:21 PM, Grigor Tovmasyan wrote: > Here are two little fixes for LPM feature. > > First one is coverity warning fix. > > The Second one was asserted by Stefan Wahren. > > Changes from version 0: > > 1/2: > - Instead of converting parameter in the CHECK_RANGE macro >

Re: [PATCH] usb: roles: intel_xhci: Don't use PMIC for port type identification

2018-04-20 Thread Heikki Krogerus
On Fri, Apr 20, 2018 at 11:16:05AM +0200, Hans de Goede wrote: > Hi Heikki, > > On 20-04-18 10:06, Heikki Krogerus wrote: > > This will add an array of known USB Type-C Port devices that > > will be used as a blacklist for enabling userspace-control, > > and remove the PMIC ACPI HID which was

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 > > >

Re: [PATCH V2] USB: Increment wakeup count on remote wakeup.

2018-04-20 Thread Alan Stern
On Thu, 19 Apr 2018, Ravi Chandra Sadineni wrote: > On chromebooks we depend on wakeup count to identify the wakeup source. > But currently USB devices do not increment the wakeup count when they > trigger the remote wake. This patch addresses the same. > > Resume condition is reported

Re: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Guenter Roeck
On 04/20/2018 03:51 AM, Jun Li wrote: -Original Message- From: Hans de Goede [mailto:hdego...@redhat.com] Sent: 2018年4月20日 17:21 To: Jun Li ; li...@roeck-us.net; heikki.kroge...@linux.intel.com Cc: gre...@linuxfoundation.org; linux-usb@vger.kernel.org; dl-linux-imx

Re: BUG xhci_hcd usb3 module WARNS with JMicron JMS567 when writing to disk

2018-04-20 Thread Tomas M
Hello, Tested 4.16.2 with the same results. Anything i can do to help find the problem? Thanks Tomas On Mon, Mar 12, 2018 at 8:22 AM, Tomas M wrote: > Hello, I think its UAS: > From the dmesg: > [ 652.335275] usb 1-1.3: Product: SABRENT > [ 652.335279] usb 1-1.3:

Re: [PATCH 2/4] usb: gadget: composite: add function to increment delayed_status

2018-04-20 Thread Alan Stern
On Thu, 19 Apr 2018, Laurent Pinchart wrote: > According to include/linux/usb/composite.h, the delayed_status field should > be > protected by cdev->lock, which you should use here. > > I've read through the code and found out that, while all callers of > reset_config(), as well as

[PATCH 1/3] xhci: Fix USB ports for Dell Inspiron 5775

2018-04-20 Thread Mathias Nyman
From: Kai-Heng Feng The Dell Inspiron 5775 is a Raven Ridge. The Enable Slot command timed out when a USB device gets plugged: [ 212.156326] xhci_hcd :03:00.3: Error while assigning device slot ID [ 212.156340] xhci_hcd :03:00.3: Max number of devices this

[PATCH 3/3] usb: host: xhci-plat: Fix clock resource by adding a register clock

2018-04-20 Thread Mathias Nyman
From: Gregory CLEMENT On Armada 7K/8K we need to explicitly enable the register clock. This clock is optional because not all the SoCs using this IP need it but at least for Armada 7K/8K it is actually mandatory. The change was done at xhci-plat level and not at a

[PATCH 0/3] xhci fixes for usb-linus

2018-04-20 Thread Mathias Nyman
Hi Greg A few fixes to get xhci on Aramada 7K/8K and Dell Inspiron 5775 to work properly Armada changes are needed for 4.17, but not stable if I understand Gregory CLEMENT correctly: "I've just realized that this series sent 2 months ago was not merged in v4.17. The issue is that now the USB

[PATCH 2/3] usb: host: xhci-plat: Remove useless test before clk_disable_unprepare

2018-04-20 Thread Mathias Nyman
From: Gregory CLEMENT clk_disable_unprepare() already checks that the clock pointer is valid. No need to test it before calling it. Signed-off-by: Gregory CLEMENT Signed-off-by: Mathias Nyman ---

Re: [RFT/PATCH 00/38] usb: dwc3: gadget: Rework & Refactoring

2018-04-20 Thread Bin Liu
On Fri, Apr 20, 2018 at 01:57:23PM +0300, Felipe Balbi wrote: > > Hi, > > Bin Liu writes: > >> Felipe Balbi writes: > >> >>> Bin Liu writes: > >> >>> > On Mon, Apr 09, 2018 at 02:26:14PM +0300, Felipe Balbi wrote: > >> >>> >> Hi guys,

Re: [PATCH v2 0/3] usb: dwc2: gadget: Update ISOC DDMA flow.

2018-04-20 Thread Minas Harutyunyan
Hi Filipe, On 3/29/2018 6:28 PM, Minas Harutyunyan wrote: > This series fully update existing ISOC DDMA flow which initially based on > 2 descriptor chains. Switching between desc chains performing based on BNA > interrupt. Because of BNA interrupt few packets can be lost. > > 1/3 patch unmask

Re: [PATCH v1 0/2] usb: dwc2: gadget: Fixes for LPM

2018-04-20 Thread Grigor Tovmasyan
Hi Simon, On 4/19/2018 8:31 PM, Simon Shields wrote: > Hi all, > > On 10/04/2018 10:21 PM, Grigor Tovmasyan wrote: >> Here are two little fixes for LPM feature. >> >> First one is coverity warning fix. >> >> The Second one was asserted by Stefan Wahren. >> >> Changes from version 0: >> >> 1/2:

Re: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Hans de Goede
Hi, On 20-04-18 12:51, Jun Li wrote: -Original Message- From: Hans de Goede [mailto:hdego...@redhat.com] Sent: 2018年4月20日 17:21 To: Jun Li ; li...@roeck-us.net; heikki.kroge...@linux.intel.com Cc: gre...@linuxfoundation.org; linux-usb@vger.kernel.org; dl-linux-imx

Re: [RFT/PATCH 00/38] usb: dwc3: gadget: Rework & Refactoring

2018-04-20 Thread Felipe Balbi
Hi, Bin Liu writes: >> Felipe Balbi writes: >> >>> Bin Liu writes: >> >>> > On Mon, Apr 09, 2018 at 02:26:14PM +0300, Felipe Balbi wrote: >> >>> >> Hi guys, >> >>> >> >> >>> >> I've been working on this series for a while now. I feels

RE: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Jun Li
> -Original Message- > From: Hans de Goede [mailto:hdego...@redhat.com] > Sent: 2018年4月20日 17:21 > To: Jun Li ; li...@roeck-us.net; > heikki.kroge...@linux.intel.com > Cc: gre...@linuxfoundation.org; linux-usb@vger.kernel.org; dl-linux-imx > > Subject:

Re: [PATCH v2 4/6] USB: show USB 3.2 Dual-lane devices as Gen Xx2 during device enumeration

2018-04-20 Thread Oliver Neukum
Am Donnerstag, den 19.04.2018, 19:05 +0300 schrieb Mathias Nyman: > USB 3.2 specification adds a Gen XxY notion for USB3 devices where > X is the signaling rate on the wire. Gen 1xY is 5Gbps Superspeed > and Gen 2xY is 10Gbps SuperSpeedPlus. Y is the lane count. > > For normal, non inter-chip

RE: [PATCH resend] usb: chipidea: Don't select EXTCON

2018-04-20 Thread Peter Chen
> > > > Sorry to reply late, are you really care 2KB code side? Since many > > users use EXTCON to handle vbus and id, it is hard just delete it. I > > could accept patch for your specific platforms, like: > > > > + select EXTCON if !ARCH_ > > The patch doesn't remove extcon support from

RE: [PATCH v2] usb: chipidea: Hook into mux framework to toggle usb switch

2018-04-20 Thread Peter Chen
> >> @@ -3,6 +3,8 @@ config USB_CHIPIDEA > >>depends on ((USB_EHCI_HCD && USB_GADGET) || (USB_EHCI_HCD && > >> !USB_GADGET) || (!USB_EHCI_HCD && USB_GADGET)) && HAS_DMA > >>select EXTCON > >>select RESET_CONTROLLER > >> + select MULTIPLEXER > >> + select MUX_GPIO > > > > The above

Re: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Hans de Goede
Hi, On 20-04-18 11:18, Jun Li wrote: -Original Message- From: Hans de Goede [mailto:hdego...@redhat.com] Sent: 2018年4月18日 19:40 To: Jun Li ; li...@roeck-us.net; heikki.kroge...@linux.intel.com Cc: gre...@linuxfoundation.org; linux-usb@vger.kernel.org; dl-linux-imx

RE: [PATCH RFC] usb: typec: tcpm: remove operating_snk_mw for rdo

2018-04-20 Thread Jun Li
> -Original Message- > From: Hans de Goede [mailto:hdego...@redhat.com] > Sent: 2018年4月18日 19:40 > To: Jun Li ; li...@roeck-us.net; > heikki.kroge...@linux.intel.com > Cc: gre...@linuxfoundation.org; linux-usb@vger.kernel.org; dl-linux-imx > > Subject:

Re: [PATCH] usb: roles: intel_xhci: Don't use PMIC for port type identification

2018-04-20 Thread Hans de Goede
Hi Heikki, On 20-04-18 10:06, Heikki Krogerus wrote: This will add an array of known USB Type-C Port devices that will be used as a blacklist for enabling userspace-control, and remove the PMIC ACPI HID which was used for the same purpose. It turns out that on some CHT based platforms the

Re: [PATCH resend] usb: chipidea: Don't select EXTCON

2018-04-20 Thread Jisheng Zhang
Hi Peter On Fri, 20 Apr 2018 01:38:42 + Peter Chen wrote: > > > drivers/usb/chipidea/Kconfig | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/usb/chipidea/Kconfig b/drivers/usb/chipidea/Kconfig > > index > > 785f0ed037f7..97509172d536 100644 > > ---

[PATCH] usb: roles: intel_xhci: Don't use PMIC for port type identification

2018-04-20 Thread Heikki Krogerus
This will add an array of known USB Type-C Port devices that will be used as a blacklist for enabling userspace-control, and remove the PMIC ACPI HID which was used for the same purpose. It turns out that on some CHT based platforms the X-Powers PMIC is handled in firmware. The ACPI HID for it is

Re: [PATCH 55/61] usb: mtu3: simplify getting .drvdata

2018-04-20 Thread Chunfeng Yun
hi, On Thu, 2018-04-19 at 16:06 +0200, Wolfram Sang wrote: > We should get drvdata from struct device directly. Going via > platform_device is an unneeded step back and forth. > > Signed-off-by: Wolfram Sang > --- > > Build tested only. buildbot is happy.

Re: [PATCH v2] usb: chipidea: Hook into mux framework to toggle usb switch

2018-04-20 Thread Peter Rosin
On 2018-04-20 04:00, Peter Chen wrote: > > >> --- a/drivers/usb/chipidea/Kconfig >> +++ b/drivers/usb/chipidea/Kconfig >> @@ -3,6 +3,8 @@ config USB_CHIPIDEA >> depends on ((USB_EHCI_HCD && USB_GADGET) || (USB_EHCI_HCD >> && !USB_GADGET) || (!USB_EHCI_HCD && USB_GADGET)) && HAS_DMA >>