Re: [RFT/PATCH 18/38] usb: dwc3: gadget: check for Missed Isoc from event status

2018-04-12 Thread Felipe Balbi
Hi, Thinh Nguyen writes: > Hi, > > On 4/11/2018 1:21 AM, Felipe Balbi wrote: >> >> Hi, >> >> Felipe Balbi writes: > Without XferNotReady, we won't have a reliable way to know the uFrame > number. Read the Isochronous programming sequence from your databook. Right. We need Xf

Re: [PATCH v2] usb: typec: ucsi: fix tracepoint related build error

2018-04-12 Thread Heikki Krogerus
On Tue, Apr 10, 2018 at 10:38:06AM +0200, Tobias Regnery wrote: > There is the following build error with CONFIG_TYPEC_UCSI=m, CONFIG_FTRACE=y > and CONFIG_TRACING=n: > > ERROR: "__tracepoint_ucsi_command" [drivers/usb/typec/ucsi/typec_ucsi.ko] > undefined! > ERROR: "__tracepoint_ucsi_register_po

Re: [PATCH] usb: typec: ucsi: fix link error on randconfig

2018-04-12 Thread Heikki Krogerus
On Tue, Apr 10, 2018 at 10:51:13AM +0300, Heikki Krogerus wrote: > If building a kernel without FTRACE but with TRACING, > ucsi.ko fails to link due to missing trace events. Fix this > by using the correct Kconfig symbol on Makefile. > > Reported-by: Tobias Regnery > Fixes: c1b0bc2dabfa ("usb: ty

[PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
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 applications without an EEPROM or programmed OTP. Document the supported properties in

[PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Phil Elwell
Add support for DT property "microchip,led-modes", a vector of two cells (u32s) in the range 0-15, each of which sets the mode for one of the two LEDs. Some possible values are: 0=link/activity 1=link1000/activity 2=link100/activity 3=link10/activity 4=link100/1000/activ

[PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Phil Elwell
Add two new Device Tree properties: * microchip,eee-enabled - a boolean to enable EEE * microchip,tx-lpi-timer - time in microseconds to wait after TX goes idle before entering the low power state (default 600) Signed-off-by: Phil Elwell ---

[PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Phil Elwell
There is a standard mechanism for locating and using a MAC address from the Device Tree. Use this facility in the lan78xx driver to support applications without programmed EEPROM or OTP. At the same time, regularise the handling of the different address sources. Signed-off-by: Phil Elwell --- dr

[PATCH 0/4] lan78xx: Read configuration from Device Tree

2018-04-12 Thread Phil Elwell
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 applications without an EEPROM or programmed OTP. This patch set adds support for readi

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > 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 > applications withou

Re: [PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Andrew Lunn
Hi Phil > - ret = lan78xx_write_reg(dev, RX_ADDRL, addr_lo); > - ret = lan78xx_write_reg(dev, RX_ADDRH, addr_hi); > + mac_addr = of_get_mac_address(dev->udev->dev.of_node); It might be better to use the higher level eth_platform_get_mac_address(

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:04, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: >> 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 De

Re: [PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:34PM +0100, Phil Elwell wrote: > Add two new Device Tree properties: > * microchip,eee-enabled - a boolean to enable EEE > * microchip,tx-lpi-timer - time in microseconds to wait after TX goes >idle before entering the low power state >

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 03:10:57PM +0100, Phil Elwell wrote: > Hi Andrew, > > On 12/04/2018 15:04, Andrew Lunn wrote: > > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > >> The Microchip LAN78XX family of devices are Ethernet controllers with > >> a USB interface. Despite being disc

Re: [PATCH 1/4] lan78xx: Read MAC address from DT if present

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:06, Andrew Lunn wrote: > Hi Phil > >> -ret = lan78xx_write_reg(dev, RX_ADDRL, addr_lo); >> -ret = lan78xx_write_reg(dev, RX_ADDRH, addr_hi); >> +mac_addr = of_get_mac_address(dev->udev->dev.of_node); > > It might be

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:35PM +0100, Phil Elwell wrote: > Add support for DT property "microchip,led-modes", a vector of two > cells (u32s) in the range 0-15, each of which sets the mode for one > of the two LEDs. Some possible values are: > > 0=link/activity 1=link1000/activity

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:26, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:35PM +0100, Phil Elwell wrote: >> Add support for DT property "microchip,led-modes", a vector of two >> cells (u32s) in the range 0-15, each of which sets the mode for one >> of the two LEDs. Some possible values ar

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Andrew Lunn
On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: > 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 > applications withou

Re: [PATCH 4/4] dt-bindings: Document the DT bindings for lan78xx

2018-04-12 Thread Phil Elwell
Hi Andrew, On 12/04/2018 15:30, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:36PM +0100, Phil Elwell wrote: >> 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 De

Re: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Andrew Lunn
> @@ -2097,6 +2098,25 @@ static int lan78xx_phy_init(struct lan78xx_net *dev) > (void)lan78xx_set_eee(dev->net, &edata); > } > > + if (!of_property_read_u32_array(dev->udev->dev.of_node, > + "microchip,led-modes", > +

Re: [PATCH 2/4] lan78xx: Read initial EEE setting from Device Tree

2018-04-12 Thread Phil Elwell
Andrew, On 12/04/2018 15:16, Andrew Lunn wrote: > On Thu, Apr 12, 2018 at 02:55:34PM +0100, Phil Elwell wrote: >> Add two new Device Tree properties: >> * microchip,eee-enabled - a boolean to enable EEE >> * microchip,tx-lpi-timer - time in microseconds to wait after TX goes >>

RE: [PATCH 3/4] lan78xx: Read LED modes from Device Tree

2018-04-12 Thread Woojung.Huh
> > @@ -2097,6 +2098,25 @@ static int lan78xx_phy_init(struct lan78xx_net *dev) > > (void)lan78xx_set_eee(dev->net, &edata); > > } > > > > + if (!of_property_read_u32_array(dev->udev->dev.of_node, > > + "microchip,led-modes", > > +

[PATCH] Revert "xhci: plat: Register shutdown for xhci_plat"

2018-04-12 Thread Greg Hackmann
Pixel 2 field testers reported that when they tried to reboot their phones with some USB devices plugged in, the reboot would get wedged and eventually trigger watchdog reset. Once the Pixel kernel team found a reliable repro case, they narrowed it down to this commit's 4.4.y backport. Reverting

Re: [RFT/PATCH 18/38] usb: dwc3: gadget: check for Missed Isoc from event status

2018-04-12 Thread Thinh Nguyen
Hi, On 4/12/2018 12:18 AM, Felipe Balbi wrote: > > Hi, > > Thinh Nguyen writes: >> Hi, >> >> On 4/11/2018 1:21 AM, Felipe Balbi wrote: >>> >>> Hi, >>> >>> Felipe Balbi writes: >> Without XferNotReady, we won't have a reliable way to know the uFrame >> number. Read the Isochronous progr

Re: [PATCH] Revert "xhci: plat: Register shutdown for xhci_plat"

2018-04-12 Thread Harsh Shandilya
On 13 April 2018 5:59:51 AM IST, Greg Hackmann wrote: >Pixel 2 field testers reported that when they tried to reboot their >phones with some USB devices plugged in, the reboot would get wedged >and >eventually trigger watchdog reset. Once the Pixel kernel team found a >reliable repro case, they n

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

2018-04-12 Thread Li Jun
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 check source pdo voltage range is within the voltage range of one sink pd

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

2018-04-12 Thread Li Jun
Since max_snk_* is to be deprecated, so remove max_snk_* by adding a variable PDO for sink config. Signed-off-by: Li Jun --- drivers/usb/typec/typec_wcove.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/usb/typec/typec_wcove.c b/drivers/usb/typec/typec_wcove.c in

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

2018-04-12 Thread Li Jun
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 type they are, the following patchs remove those 3 variables from 2

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

2018-04-12 Thread Li Jun
Since there is no user of max_snk_*, so we can remove them from tcpm. Signed-off-by: Li Jun --- drivers/usb/typec/tcpm.c | 12 include/linux/usb/tcpm.h | 9 - 2 files changed, 21 deletions(-) diff --git a/drivers/usb/typec/tcpm.c b/drivers/usb/typec/tcpm.c index c127339..3

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

2018-04-12 Thread Li Jun
Since max_snk_* is to be deprecated, so remove max_snk_* by adding a variable PDO for sink config. Signed-off-by: Li Jun --- drivers/usb/typec/fusb302/fusb302.c | 34 -- 1 file changed, 20 insertions(+), 14 deletions(-) diff --git a/drivers/usb/typec/fusb302/fusb

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

2018-04-12 Thread Li Jun
Remove max-sink-* properties since they are deprecated. Reviewed-by: Rob Herring Signed-off-by: Li Jun --- Documentation/devicetree/bindings/usb/fcs,fusb302.txt | 6 -- 1 file changed, 6 deletions(-) diff --git a/Documentation/devicetree/bindings/usb/fcs,fusb302.txt b/Documentation/device

Re: [PATCH] Revert "xhci: plat: Register shutdown for xhci_plat"

2018-04-12 Thread Greg Kroah-Hartman
On Fri, Apr 13, 2018 at 08:12:31AM +0530, Harsh Shandilya wrote: > On 13 April 2018 5:59:51 AM IST, Greg Hackmann wrote: > >Pixel 2 field testers reported that when they tried to reboot their > >phones with some USB devices plugged in, the reboot would get wedged > >and > >eventually trigger watch