Re: usb: common: otg-fsm: add license to usb-otg-fsm

2016-06-13 Thread Peter Chen
CENSE("GPL"); > -- > To unsubscribe from this list: send the line "unsubscribe linux-usb" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html Good catch, but would you please create the patch

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Peter Chen
On Mon, Jun 13, 2016 at 10:37:59AM +0300, Roger Quadros wrote: > On 13/06/16 10:20, Peter Chen wrote: > > On Mon, Jun 13, 2016 at 10:14:31AM +0300, Roger Quadros wrote: > >> On 12/06/16 14:36, Peter Chen wrote: > >>> On Fri, Jun 10, 2016 at 04:07:2

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-13 Thread Peter Chen
On Mon, Jun 13, 2016 at 10:14:31AM +0300, Roger Quadros wrote: > On 12/06/16 14:36, Peter Chen wrote: > > On Fri, Jun 10, 2016 at 04:07:22PM +0300, Roger Quadros wrote: > >> > >> +/** > >> + * usb_otg_add_gadget_udc - adds a new gadget to the udc class driv

Re: [balbi-usb:testing/next 64/67] otg.c:undefined reference to `usb_gadget_vbus_disconnect'

2016-06-13 Thread Peter Chen
> only GPL drivers will use them. > > As a side effect, it'll be nicer to add tracepoints > to the gadget API. > > While at that, also fix Kconfig dependencies to > avoid randconfig build failures. > > Signed-off-by: Felipe Balbi <felipe.ba...@linux.intel

Re: [RFC v4 01/14] regulator: of: Add helper for getting all supplies

2016-06-12 Thread Peter Chen
On Sun, Jun 12, 2016 at 03:29:01PM +0800, Peter Chen wrote: > On Fri, Jun 10, 2016 at 12:30:56PM -0500, Rob Herring wrote: > > On Thu, Jun 09, 2016 at 01:42:02PM +0200, Krzysztof Kozlowski wrote: > > > On 06/09/2016 12:29 PM, Mark Brown wrote: > > > > On Thu, Ju

Re: [PATCH v10 13/14] usb: gadget: udc: adapt to OTG core

2016-06-12 Thread Peter Chen
vent(>dev.kobj, KOBJ_CHANGE); > return 0; > err1: > - if (ret != -EISNAM) > + if ((ret != -EISNAM) && (ret != -EPROBE_DEFER)) It seems it will not introduce -EPROBE_DEFER with your changes in udc_bind_to_driver -- Best Regards, Peter Chen -- To unsubscribe fro

Re: [PATCH v10 08/14] usb: otg: add OTG/dual-role core

2016-06-12 Thread Peter Chen
ler to OTG core > + * @gadget: gadget controller instance > + * @ops: gadget interface ops > + * > + * This is used by the USB gadget stack to register the gadget controller > + * to the OTG core. Gadget controller must not be started by the > + * caller as it is left

Re: [PATCH v9 08/14] usb: otg: add OTG/dual-role core

2016-06-12 Thread Peter Chen
On Sun, Jun 12, 2016 at 02:26:17PM +0800, Peter Chen wrote: > On Thu, Jun 09, 2016 at 10:24:44AM +0300, Roger Quadros wrote: > > On 08/06/16 15:42, Peter Chen wrote: > > > On Wed, Jun 08, 2016 at 01:12:10PM +0300, Roger Quadros wrote: > > >> Hi, > > >>

Re: [PATCH v10 06/14] usb: gadget.h: Add OTG to gadget interface

2016-06-12 Thread Peter Chen
ouldn't be defined in the built-in symbol table if > CONFIG_USB_GADGET is m. > > Signed-off-by: Roger Quadros <rog...@ti.com> Acked-by: Peter Chen <peter.c...@nxp.com> > --- > include/linux/usb/gadget.h | 16 > 1 file changed, 16 insertions(+) > > d

Re: [PATCH v7 2/4] usb: dwc3: add dual-role support

2016-06-12 Thread Peter Chen
ed (mainly for testing purposes) > * @revision: revision register contents > - * @dr_mode: requested mode of operation > * @usb2_phy: pointer to USB2 PHY > * @usb3_phy: pointer to USB3 PHY > * @usb2_generic_phy: pointer to USB2 PHY > @@ -831,6 +840,9 @@ struct dwc3_scratchp

Re: [RFC v4 01/14] regulator: of: Add helper for getting all supplies

2016-06-12 Thread Peter Chen
o express ordering relationship of supplies, clocks, gpios? We end > up with a scripting language in DT and we don't want to have that. > Can we do things like below: - DT describes hardware elements (clock, gpios, etc) for power sequence, and we need a node for power sequence. - Pow

Re: [PATCH v9 08/14] usb: otg: add OTG/dual-role core

2016-06-12 Thread Peter Chen
On Thu, Jun 09, 2016 at 10:24:44AM +0300, Roger Quadros wrote: > On 08/06/16 15:42, Peter Chen wrote: > > On Wed, Jun 08, 2016 at 01:12:10PM +0300, Roger Quadros wrote: > >> Hi, > >> > >> On 08/06/16 12:53, Peter Chen wrote: > >>> On Wed, Jun 0

Re: [PATCH v3] usb: phy: mxs: Add DT bindings to configure TX settings

2016-06-11 Thread Peter Chen
On Thu, Jun 09, 2016 at 02:07:52PM -0400, Justin Waters wrote: > Peter, > > On Wed, Jun 8, 2016 at 10:41 PM, Peter Chen <hzpeterc...@gmail.com> wrote: > > On Thu, Jun 9, 2016 at 5:27 AM, Jaret Cantu <jaret.ca...@timesys.com> wrote: > >> On 03/23/2016 10:21 PM,

Re: [balbi-usb:testing/next 64/67] otg.c:undefined reference to `usb_gadget_vbus_disconnect'

2016-06-11 Thread Peter Chen
On Wed, Jun 08, 2016 at 12:59:51PM +0300, Felipe Balbi wrote: > > Hi, > > kbuild test robot writes: > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git > > testing/next > > head: fc4d1f3f522648d92d0c046beedbc1469979499a > > commit:

Re: [PATCH v9 00/14] USB OTG/dual-role framework

2016-06-08 Thread Peter Chen
On Wed, Jun 8, 2016 at 5:03 PM, Roger Quadros wrote: > Hi, > > This series centralizes OTG/Dual-role functionality in the kernel. > As of now I've got Dual-role functionality working pretty reliably on > dra7-evm and am437x-gp-evm. > > DWC3 controller and TI platform related

Re: [PATCH v3] usb: phy: mxs: Add DT bindings to configure TX settings

2016-06-08 Thread Peter Chen
On Thu, Jun 9, 2016 at 5:27 AM, Jaret Cantu <jaret.ca...@timesys.com> wrote: > On 03/23/2016 10:21 PM, Peter Chen wrote: >> >> On Wed, Mar 23, 2016 at 02:17:27PM -0400, Jaret Cantu wrote: >>> >>> On 03/23/2016 01:37 PM, Jaret Cantu wrote: >>>

Re: [PATCH v9 08/14] usb: otg: add OTG/dual-role core

2016-06-08 Thread Peter Chen
On Wed, Jun 08, 2016 at 01:12:10PM +0300, Roger Quadros wrote: > Hi, > > On 08/06/16 12:53, Peter Chen wrote: > > On Wed, Jun 08, 2016 at 12:03:40PM +0300, Roger Quadros wrote: > >> +int usb_otg_unregister(struct device *dev) > >> +{ > >> + stru

Re: [balbi-usb:testing/next 64/67] phy-generic.c:undefined reference to `usb_gadget_vbus_connect'

2016-06-08 Thread Peter Chen
On Wed, Jun 08, 2016 at 01:32:29PM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > >> > Would you consider only keeps vbus and pull dp API at gadget.h, and move > >> > out others gadget APIs which is dedicated for gad

Re: [balbi-usb:testing/next 64/67] phy-generic.c:undefined reference to `usb_gadget_vbus_connect'

2016-06-08 Thread Peter Chen
On Wed, Jun 08, 2016 at 12:50:57PM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > >> >> > Hi Felipe, > >> >> > > >> >> > It causes any drivers which use symbols from gadget.h needs t

Re: [PATCH v9 08/14] usb: otg: add OTG/dual-role core

2016-06-08 Thread Peter Chen
} > +#endif /* CONFIG_USB_OTG */ > + > +/*- deprecated interface -*/ > /* Context: can sleep */ > static inline int > otg_start_hnp(struct usb_otg *otg) > @@ -113,6 +264,8 @@ otg_start_srp(struct usb_otg *otg) > return -ENOTSUPP; > } > > +/*---*/ > + > /* for OTG controller drivers (and maybe other stuff) */ > extern int usb_bus_start_enum(struct usb_bus *bus, unsigned port_num); > > @@ -237,4 +390,6 @@ static inline int otg_start_gadget(struct usb_otg *otg, > int on) > return otg->fsm.ops->start_gadget(otg, on); > } > > +int drd_statemachine(struct usb_otg *otg); > + > #endif /* __LINUX_USB_OTG_H */ > -- > 2.7.4 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-usb" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-06-08 Thread Peter Chen
On Wed, Jun 08, 2016 at 10:32:19AM +0300, Roger Quadros wrote: > Hi, > > On 24/05/16 05:53, Peter Chen wrote: > > On Mon, May 23, 2016 at 01:36:51PM +0300, Roger Quadros wrote: > >> On 23/05/16 13:34, Jun Li wrote: > >>> Hi > >>> > >>

Re: [RFC][PATCH] usb: gadget: Allow to build both USB functions and legacy gadgets

2016-06-08 Thread Peter Chen
On Tue, Jun 07, 2016 at 11:59:57AM +0200, Krzysztof Opasiak wrote: > Hi, > > On Tue, Jun 7, 2016 at 11:06 AM, Peter Chen <peter.c...@nxp.com> wrote: > > > > > >>-Original Message- > >>From: linux-usb-ow...@vger.kernel.org > >>

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-08 Thread Peter Chen
either by the HW or > within the kernel. > > If we're discussing userspace ABI here, there's something very wrong > with OTG/DRD layer design. Currently, there are some use cases which need to switch role on the fly (will be more for type-c in future), a sysfs for role switch is necessa

Re: [balbi-usb:testing/next 64/67] phy-generic.c:undefined reference to `usb_gadget_vbus_connect'

2016-06-07 Thread Peter Chen
On Tue, Jun 07, 2016 at 01:22:37PM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > >> >> > kbuild test robot <fengguang...@intel.com> writes: > >> >> >> tree: > >> >> >> ht

RE: [RFC][PATCH] usb: gadget: Allow to build both USB functions and legacy gadgets

2016-06-07 Thread Peter Chen
>-Original Message- >From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-ow...@vger.kernel.org] >On Behalf Of Krzysztof Opasiak >Sent: Tuesday, June 07, 2016 3:46 PM >To: Peter Chen <hzpeterc...@gmail.com> >Cc: Krzysztof Opasiak <k.opas...@samsung.com>

Re: [balbi-usb:testing/next 64/67] phy-generic.c:undefined reference to `usb_gadget_vbus_connect'

2016-06-07 Thread Peter Chen
On Tue, Jun 07, 2016 at 12:36:13PM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > > On Mon, Jun 06, 2016 at 04:16:17PM +0300, Felipe Balbi wrote: > >> > >> Hi, > >> > >> Felipe Balbi <felipe.b

Re: [balbi-usb:testing/next 64/67] phy-generic.c:undefined reference to `usb_gadget_vbus_connect'

2016-06-06 Thread Peter Chen
help > Enable this to support Keystone USB phy. This driver provides > interface to interact with USB 2.0 and USB 3.0 PHY that is part > @@ -63,9 +64,10 @@ config AM335X_CONTROL_USB > config AM335X_PHY_USB > tristate "AM335x USB PHY Driver" > depends on ARM || COMPILE_TEST > + depends on USB_GADGET=y || USB_GADGET=NOP_USB_XCEIV > + depends on NOP_USB_XCEIV > select USB_PHY > select AM335X_CONTROL_USB > - select NOP_USB_XCEIV > select USB_COMMON > help > This driver provides PHY support for that phy which part for the > > > Anybody has any problems with this being amended to original patch? Note > that NOP_USB_XCEIV should never have been selected with "select" to > start with. > > -- > balbi -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [RFC][PATCH] usb: gadget: Allow to build both USB functions and legacy gadgets

2016-06-06 Thread Peter Chen
CM > + depends on USB_LIBCOMPOSITE > + select USB_G_CDC_COMPOSITE_REQ_F_ACM > + select USB_G_CDC_COMPOSITE_REQ_F_ECM > help > This driver provides two functions in one configuration: > a CDC Ethernet (ECM) link, and a CDC ACM (serial port) link.

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-06 Thread Peter Chen
On Mon, Jun 06, 2016 at 11:04:48AM +0800, Lu Baolu wrote: > Hi Peter, > > On 06/06/2016 09:25 AM, Peter Chen wrote: > > On Sun, Jun 05, 2016 at 02:55:56PM +0800, Lu Baolu wrote: > >> Hi Peter, > >> > >> On 06/04/2016 10:28 AM, Peter Chen wrote: > >

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-06 Thread Peter Chen
On Mon, Jun 06, 2016 at 10:45:34AM +0800, Lu Baolu wrote: > Hi Peter, > > On 06/06/2016 10:05 AM, Peter Chen wrote: > > On Sun, Jun 05, 2016 at 04:46:55PM +0800, Lu Baolu wrote: > >> Hi, > >> > >> On 06/05/2016 04:33 PM, Jun Li wrote: > >>>>

Re: [PATCH v3 06/12] power: pwrseq: simple: Add support for regulator and generic property

2016-06-05 Thread Peter Chen
7 > > How do you like that approach? > Rob, I am trying to implement the dts layout you suggested (see below), but I find it is very hard to it due to the device is still not created, without device, it is hard to manage the resources under this device ( Eg, de-initialization for probe deferral

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-05 Thread Peter Chen
is OTG core. > > Why do we need an OTG framework to support a device driver? Just like you said above, OTG framework can manage role switch, the role switch may need to start or stop host/gadget driver according to different hardware signals or user input. > Is it something like a bus or cla

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-05 Thread Peter Chen
On Sun, Jun 05, 2016 at 02:55:56PM +0800, Lu Baolu wrote: > Hi Peter, > > On 06/04/2016 10:28 AM, Peter Chen wrote: > > On Sat, Jun 04, 2016 at 12:06:06AM +0800, Lu Baolu wrote: > >>> from my point,it is a dual-role switch > >>> driver too, >

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-03 Thread Peter Chen
On Sat, Jun 04, 2016 at 12:06:06AM +0800, Lu Baolu wrote: > Hi Peter, > > On 06/03/2016 03:41 PM, Peter Chen wrote: > > On Thu, Jun 02, 2016 at 09:37:24AM +0800, Lu Baolu wrote: > >> > Several Intel platforms implement USB dual role by having completely > >>

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-03 Thread Peter Chen
On Fri, Jun 03, 2016 at 11:16:32AM +0300, Heikki Krogerus wrote: > On Fri, Jun 03, 2016 at 03:41:13PM +0800, Peter Chen wrote: > > On Thu, Jun 02, 2016 at 09:37:24AM +0800, Lu Baolu wrote: > > > Several Intel platforms implement USB dual role by having completely > > >

Re: [PATCH v10 2/7] usb: mux: add generic code for dual role port mux

2016-06-03 Thread Peter Chen
; + struct device *dev; > + const struct portmux_ops *ops; > +}; > + > +/** > + * enum portmux_role - role of the port > + */ > +enum portmux_role { > + PORTMUX_UNKNOWN, > + PORTMUX_HOST, > + PORTMUX_DEVICE, > +}; > + > +/** > + * struct po

Re: [PATCH v3 12/12] ARM: dts: exynos: Fix LAN and HUB after bootloader initialization on Odroid U3

2016-06-02 Thread Peter Chen
On Thu, Jun 02, 2016 at 09:26:57AM +0200, Krzysztof Kozlowski wrote: > On 06/01/2016 01:59 PM, Peter Chen wrote: > > On Wed, Jun 01, 2016 at 10:02:21AM +0200, Krzysztof Kozlowski wrote: > >> On Odroid U3 (Exynos4412-based) board if USB was initialized by > >> bootl

Re: [PATCH v3 09/12] EXAMPLE CODE: usb: port: Parse pwrseq phandle from Device Tree

2016-06-01 Thread Peter Chen
y to do it at bootloader to see if it works for you. -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v3 12/12] ARM: dts: exynos: Fix LAN and HUB after bootloader initialization on Odroid U3

2016-06-01 Thread Peter Chen
status = "okay"; }; 2. USB device { vbus-supply = <_usb_otg1_vbus>; pinctrl-names = "default"; pinctrl-0 = <_usb_otg1_id>; status = "okay"; #address-cells = <1>; #size-cells = <0>; hub: g

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-06-01 Thread Peter Chen
struct usb_gadget *gadget, > + struct device *otg_dev); > + > /*-----*/ > > /* utility to simplify dealing with string descriptors */ > -- > 2.7.4 > > -- > To un

Re: [PATCH 2/2] usb: gadget: add tracepoints to the gadget API

2016-05-31 Thread Peter Chen
d, length) > + __field(unsigned, actual) > + __field(unsigned, num_sgs) > + __field(unsigned, num_mapped_sgs) > + __field(unsigned, stream_id) > + __field(unsigned, no_interrupt) > + __field(unsigned, zero) > +

Re: [PATCH 1/2] usb: gadget: move gadget API functions to udc-core

2016-05-31 Thread Peter Chen
tic inline int usb_gadget_disconnect(struct usb_gadget *gadget) > -{ > - int ret; > - > - if (!gadget->ops->pullup) > - return -EOPNOTSUPP; > - > - if (gadget->deactivate

Re: [RFC v2 00/13] usb/mmc/power: Fix USB/LAN when TFTP booting

2016-05-30 Thread Peter Chen
On Sat, May 28, 2016 at 11:36:13AM +0800, Peter Chen wrote: > On Tue, May 10, 2016 at 01:02:08PM +0200, Ulf Hansson wrote: > > + Arnd > > > > [...] > > > > >> >> Solution > > >> >> > > >> >> This is very s

Re: [PATCH v8 00/14] USB OTG/dual-role framework

2016-05-30 Thread Peter Chen
| 22 + > include/linux/usb/hcd.h | 29 + > include/linux/usb/of.h|9 + > include/linux/usb/otg-fsm.h | 154 +-- > include/linux/usb/otg.h | 264 +- > include/linux/usb/xhci_pdriver.h |3 + > 26 files changed, 2013 insertions(+), 438 deletions(-) > create mode 100644 drivers/usb/common/usb-otg.c > > -- > 2.7.4 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-usb" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [RFC v2 00/13] usb/mmc/power: Fix USB/LAN when TFTP booting

2016-05-27 Thread Peter Chen
on pwrseq > driver framework. > > Although, I do remember from an older conversations around some of > mine submission for the mmc pwrseq code, that some people (maybe > Arnd?) wasn't keen on adding a new framework for this. Perhaps that > has changed? > All, how we move on for this? 1. Using a generic driver to manage both mmc and USB (and further subsystem), USB and further subsystem do not use pwrseq node in dts. 2. USB creates the similar driver under drivers/usb for its own use. Which one do you prefer, thanks. -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] usb: select NOP_USB_XCEIV by drivers that require it

2016-05-26 Thread Peter Chen
; diff --git a/drivers/usb/phy/Kconfig b/drivers/usb/phy/Kconfig > index c690474..a0bdfd3 100644 > --- a/drivers/usb/phy/Kconfig > +++ b/drivers/usb/phy/Kconfig > @@ -57,6 +57,8 @@ config NOP_USB_XCEIV > built-in with usb ip or which are autonomous and doesn't require any >

Re: [RFC 4/5] ARM: tegra: Enable UDC on Dalmore

2016-05-26 Thread Peter Chen
dr_mode = "otg"; > + }; > + > + usb-phy@7d00 { > + status = "okay"; > + dr_mode = "otg"; > + }; > + It is a USB PHY node, you don't need to set dr_mode for it. -- Best Regards, Peter Chen -- To unsubscribe fr

Re: [RFC 0/5] usb: chipidea: Add support for Tegra20 through Tegra124

2016-05-26 Thread Peter Chen
ample: Using ID pin which is at Micro-B receptacle on the board to determine host (ID = 0) or device (ID = 1 )mode. - ID pin connects to CPU, and ID interrupt and value can be get through register OTGSC. - ID pin does not connect to CPU, and there is a dedicated GPIO for ID. -- Best Regards

Re: [PATCH v8 08/14] usb: otg: add OTG/dual-role core

2016-05-24 Thread Peter Chen
et/udc/host driver if otg driver is not probed, in that case, some designs can be simpler like wait list in otg driver. > mutex_unlock(_lock); > usb_otg_register_gadget(udc->gadget, _gadget_intf); > mutex_lock(_lock); >

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-23 Thread Peter Chen
On Mon, May 23, 2016 at 01:36:51PM +0300, Roger Quadros wrote: > On 23/05/16 13:34, Jun Li wrote: > > Hi > > > >> -Original Message- > >> From: Roger Quadros [mailto:rog...@ti.com] > >> Sent: Monday, May 23, 2016 6:12 PM > >> To: Pete

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-20 Thread Peter Chen
On Fri, May 20, 2016 at 10:26:03AM +0300, Roger Quadros wrote: > Peter, > > On 20/05/16 04:39, Peter Chen wrote: > > On Wed, May 18, 2016 at 03:45:11PM +0300, Roger Quadros wrote: > >> On 18/05/16 06:18, Peter Chen wrote: > >>> On Mon, May 16, 2016 at 1

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-20 Thread Peter Chen
t/device driver's probe return -EPROBE_DEFER. When the otg driver is probed successfully, the host/device will be re-probed again, and usb_otg_register_hcd will be called again. And let OTG depends on HCD && GADGET, and delete otg_hcd_ops and otg_gadget_ops. Below build dependency issues can be f

Re: [PATCH v8 08/14] usb: otg: add OTG/dual-role core

2016-05-20 Thread Peter Chen
On Fri, May 20, 2016 at 12:19:07PM +0300, Roger Quadros wrote: > On 20/05/16 11:31, Roger Quadros wrote: > > On 18/05/16 15:59, Roger Quadros wrote: > >> Hi Peter, > >> > >> On 18/05/16 10:45, Peter Chen wrote: > >>> > >>> > &g

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-19 Thread Peter Chen
On Wed, May 18, 2016 at 03:45:11PM +0300, Roger Quadros wrote: > On 18/05/16 06:18, Peter Chen wrote: > > On Mon, May 16, 2016 at 12:51:53PM +0300, Roger Quadros wrote: > >> On 16/05/16 12:23, Peter Chen wrote: > >>> On Mon, May 16, 2016 at 11:26:57AM +0300,

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-17 Thread Peter Chen
On Mon, May 16, 2016 at 12:51:53PM +0300, Roger Quadros wrote: > On 16/05/16 12:23, Peter Chen wrote: > > On Mon, May 16, 2016 at 11:26:57AM +0300, Roger Quadros wrote: > >> Hi, > >> > >> On 16/05/16 10:02, Peter Chen wrote: > >>> On Fri, May 1

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-16 Thread Peter Chen
On Mon, May 16, 2016 at 11:26:57AM +0300, Roger Quadros wrote: > Hi, > > On 16/05/16 10:02, Peter Chen wrote: > > On Fri, May 13, 2016 at 01:03:27PM +0300, Roger Quadros wrote: > >> + > >> +static int usb_gadget_connect_control(struct usb_gadget *gadget, bool >

Re: [PATCH v7 10/14] usb: otg: add hcd companion support

2016-05-16 Thread Peter Chen
On Mon, May 16, 2016 at 11:01:27AM +0300, Roger Quadros wrote: > On 16/05/16 05:13, Peter Chen wrote: > > On Thu, May 12, 2016 at 03:13:48PM +0300, Roger Quadros wrote: > >> Hi, > >> > >> On 12/05/16 13:31, Yoshihiro Shimoda wrote: > >>> Hi, > &

Re: [PATCH v8 13/14] usb: gadget: udc: adapt to OTG core

2016-05-16 Thread Peter Chen
uot;); > + return -EOPNOTSUPP; > + } > + The soft-connect can be supported at dual-role mode currently, we can use b_bus_req entry once it is implemented later. > if (sysfs_streq(buf, "connect")) { > usb_gadget_udc_start(udc); >

Re: [PATCH v7 10/14] usb: otg: add hcd companion support

2016-05-15 Thread Peter Chen
2) has USB 2.0 host controllers via PCI > > bus and > > one high speed function controller via AXI bus. > > One of channel can be used as host or function. > > > >> For DT case we could have a DT binding to tie the EHCI and companion and > >> use t

Re: [RFC PATCH v2 4/4] ARM: dts: vf-colibri: USB device/host switch using extcon gpio

2016-05-13 Thread Peter Chen
On Thu, May 12, 2016 at 02:47:09PM +0530, maitysancha...@gmail.com wrote: > Hello Peter, > > On 16-05-12 16:40:16, Peter Chen wrote: > > On Wed, May 11, 2016 at 06:11:36PM +0530, Sanchayan Maity wrote: > > > Use USBC_DET feature of standard Colibri SODIMM pin 137 f

Re: [RFC PATCH v2 4/4] ARM: dts: vf-colibri: USB device/host switch using extcon gpio

2016-05-12 Thread Peter Chen
l_usbh1_reg: gpio_usb_vbus { > fsl,pins = < > VF610_PAD_PTD4__GPIO_83 0x22ed > -- > 2.8.2 > > -- > To unsubscribe from this list: send the line "unsubscribe linux-usb" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v7 05/14] usb: otg-fsm: move host controller operations into usb_otg->hcd_ops

2016-05-12 Thread Peter Chen
On Wed, May 11, 2016 at 03:32:30PM +0300, Roger Quadros wrote: > Peter, > > On 11/05/16 14:02, Roger Quadros wrote: > > On 11/05/16 09:10, Peter Chen wrote: > >> On Mon, May 02, 2016 at 03:18:48PM +0300, Roger Quadros wrote: > >>> This is to preve

Re: [PATCH v7 14/14] usb: host: xhci-plat: Add otg device to platform data

2016-05-11 Thread Peter Chen
/usb/xhci_pdriver.h > @@ -18,10 +18,13 @@ > * > * @usb3_lpm_capable:determines if this xhci platform supports USB3 > * LPM capability > + * @otg_dev: OTG controller device. Only requied if part of > + * OTG/dual-

Re: [PATCH v7 12/14] usb: hcd: Adapt to OTG core

2016-05-11 Thread Peter Chen
otg_dev is NULL > then the device tree node's otg-controller property is used to > get the otg_dev device. > > Signed-off-by: Roger Quadros <rog...@ti.com> Acked-by: Peter Chen <peter.c...@nxp.com> > --- > drivers/usb/core/hcd.c | 55 > +

Re: [PATCH v7 11/14] usb: otg: use dev_dbg() instead of VDBG()

2016-05-11 Thread Peter Chen
On Mon, May 09, 2016 at 12:48:28PM +0300, Roger Quadros wrote: > On 06/05/16 12:04, Peter Chen wrote: > > On Mon, May 02, 2016 at 03:18:54PM +0300, Roger Quadros wrote: > >> Now that we have a device reference in struct usb_otg > >> let's use dev_dbg() for debug mes

Re: [PATCH v7 10/14] usb: otg: add hcd companion support

2016-05-11 Thread Peter Chen
core. > > Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda...@renesas.com> > Signed-off-by: Roger Quadros <rog...@ti.com> Acked-by: Peter Chen <peter.c...@nxp.com> > --- > Documentation/devicetree/bindings/usb/generic.txt | 3 +++ >

Re: [PATCH v7 09/14] usb: of: add an API to get OTG device from USB controller node

2016-05-11 Thread Peter Chen
On Mon, May 02, 2016 at 03:18:52PM +0300, Roger Quadros wrote: > The OTG controller and the USB controller an be linked via the Typo? Others are ok for me. Acked-by: Peter Chen <peter.c...@nxp.com> > 'otg-controller' property in the USB controller's device node. > > of

Re: [PATCH v7 00/14] USB OTG/dual-role framework

2016-05-11 Thread Peter Chen
/linux/usb/gadget.h | 20 + > include/linux/usb/hcd.h| 29 + > include/linux/usb/of.h |9 + > include/linux/usb/otg-fsm.h| 154 +-- > include/linux/usb/otg.h

Re: [PATCH v7 08/14] usb: otg: add OTG/dual-role core

2016-05-11 Thread Peter Chen
ESS_VLD (1000) Seems you agree to remove above definitions. > > /* Current usb protocol used: 0:undefine; 1:host; 2:client */ > diff --git a/include/linux/usb/otg.h b/include/linux/usb/otg.h > index 85b8fb5..b094352 100644 > --- a/include/linux/usb/otg.h > +++ b/incl

Re: [PATCH v7 07/14] usb: otg: get rid of CONFIG_USB_OTG_FSM in favour of CONFIG_USB_OTG

2016-05-11 Thread Peter Chen
Roger Quadros <rog...@ti.com> Acked-by: Peter Chen <peter.c...@nxp.com> > --- > Documentation/usb/chipidea.txt | 2 +- I have updated this file, so you will meet a conflict if you rebase with newest usb-next tree. > drivers/usb/chipidea/Makefile | 2 +- > drivers/us

Re: [PATCH v7 02/14] usb: otg-fsm: Prevent build warning "VDBG" redefined

2016-05-11 Thread Peter Chen
1: >include/linux/usb/composite.h:615:1: warning: this is the location >of the previous definition > > Signed-off-by: Roger Quadros <rog...@ti.com> Acked-by: Peter Chen <peter.c...@nxp.com> > --- > drivers/usb/common/usb-otg-fsm.c | 7 +++ > drivers/usb/phy/phy-fs

Re: [PATCH v7 03/14] usb: hcd.h: Add OTG to HCD interface

2016-05-11 Thread Peter Chen
On Tue, May 10, 2016 at 12:20:28PM +0300, Roger Quadros wrote: > On 10/05/16 11:03, Jun Li wrote: > > Hi > > > >> -Original Message- > >> From: Roger Quadros [mailto:rog...@ti.com] > >> Sent: Tuesday, May 10, 2016 3:35 PM > >> To:

Re: [PATCH v7 05/14] usb: otg-fsm: move host controller operations into usb_otg->hcd_ops

2016-05-11 Thread Peter Chen
On Mon, May 02, 2016 at 03:18:48PM +0300, Roger Quadros wrote: > This is to prevent missing symbol build error if OTG is > enabled (built-in) and HCD core (CONFIG_USB) is module. > > Signed-off-by: Roger Quadros <rog...@ti.com> > Acked-by: Peter Chen <peter.c...@nxp.c

Re: [PATCH v7 03/14] usb: hcd.h: Add OTG to HCD interface

2016-05-09 Thread Peter Chen
On Mon, May 09, 2016 at 12:45:38PM +0300, Roger Quadros wrote: > On 06/05/16 12:41, Peter Chen wrote: > > On Mon, May 02, 2016 at 03:18:46PM +0300, Roger Quadros wrote: > >> The OTG core will use struct otg_hcd_ops to interface > >> with the HCD controller.

Re: [PATCH v7 03/14] usb: hcd.h: Add OTG to HCD interface

2016-05-06 Thread Peter Chen
he built-in symbol table if > CONFIG_USB is m. > > Signed-off-by: Roger Quadros <rog...@ti.com> > Acked-by: Peter Chen <peter.c...@nxp.com> Roger, after thinking more, I still think current dependency between OTG, HCD and gadget are too complicated. Since the OTG can't work i

Re: [PATCH v7 01/14] usb: hcd: Initialize hcd->flags to 0

2016-05-06 Thread Peter Chen
sbcore] > [ 91.759260] Disabling IRQ #254 > > Signed-off-by: Roger Quadros <rog...@ti.com> > --- > drivers/usb/core/hcd.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c > index 2ca2cef..9484539 100644 > --

Re: [PATCH v7 11/14] usb: otg: use dev_dbg() instead of VDBG()

2016-05-06 Thread Peter Chen
t; - VDBG("quit statemachine, changed = %d\n", fsm->state_changed); > + dev_vdbg(otg->dev, "quit statemachine, changed = %d\n", > + fsm->state_changed); > return fsm->state_changed; > } > EXPORT_SYMBOL_GPL(otg_statemachine); > -- Could you squash patch 2 with this one? -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] usb: dwc3: usb/dwc3: fake dissconnect event when turn off pullup

2016-05-06 Thread Peter Chen
On Fri, May 06, 2016 at 10:01:20AM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > >> "Du, Changbin" <changbin...@intel.com> writes: > >> > Hi, Balbi, > >> > > >> > The s

Re: [RFC v2 00/13] usb/mmc/power: Fix USB/LAN when TFTP booting

2016-05-06 Thread Peter Chen
On Fri, May 06, 2016 at 08:12:24AM +0200, Krzysztof Kozlowski wrote: > On 05/06/2016 07:44 AM, Peter Chen wrote: > > On Thu, May 05, 2016 at 05:42:40PM -0500, Rob Herring wrote: > >> On Thu, May 05, 2016 at 02:34:13PM +0200, Krzysztof Kozlowski wrote: > >>> Hi, &

Re: [RFC v2 00/13] usb/mmc/power: Fix USB/LAN when TFTP booting

2016-05-05 Thread Peter Chen
d by USB driver. > > 2. Extend the pwrseq-simple with regulator toggling, > > 3. Add support to USB hub and port core for pwrseq, > > We discussed this for USB already[1] and is why we defined how to add > USB child devices. The idea is not to add pwrseq to that. >

Re: [PATCH] usb: dwc3: usb/dwc3: fake dissconnect event when turn off pullup

2016-05-05 Thread Peter Chen
its disconnect explicitly. Another thing is the gadget driver should not call usb_gadget_disconnect directly, it should call usb_gadget_deactivate or usb_function_deactivate. Since currently, calling usb_gadget_disconnect may not do real pull down dp, Felipe, will you consider adding gadget_driver->d

Re: [PATCH v6 09/12] usb: gadget: udc: adapt to OTG core

2016-05-04 Thread Peter Chen
On Wed, May 04, 2016 at 09:37:29AM +0300, Roger Quadros wrote: > Peter, > > On 04/05/16 06:35, Peter Chen wrote: > > On Tue, May 03, 2016 at 06:44:46PM +0300, Roger Quadros wrote: > >> Hi, > >> > >>

[GIT PULL] usb: Chipidea and OTG FSM changes for v4.7-rc1

2016-05-04 Thread Peter Chen
. Peter Chen (2): usb: chipidea: imx: delete the redundant setting default DMA mask code doc: usb: chipidea: update the doc for OTG FSM Roger Quadros (2): usb: otg-fsm: Add documentation for struct otg_fsm usb

Re: [PATCH v6 09/12] usb: gadget: udc: adapt to OTG core

2016-05-03 Thread Peter Chen
But I am still in favor of > doing a connect in usb_gadget_start(), because > > 1) If we split connect/disconnect() and usb_gadget_start/stop() then there is > additional overhead of keeping track whether connect was called or not during > usb_gadget_stop(). Plus we need to take care

Re: [PATCH v6 09/12] usb: gadget: udc: adapt to OTG core

2016-05-03 Thread Peter Chen
iable and it corresponds to our > >> gadget_start/stop() state. > > > > It's not an internal variable, there are OTG state machine > > parameters tables(table 7-x) in OTG spec which have clear lists > > which are "internal variable", which are "in

Re: [PATCH] usb: misc: usbtest: fix pattern tests for scatterlists.

2016-05-03 Thread Peter Chen
On Tue, May 03, 2016 at 12:31:21PM +0300, Felipe Balbi wrote: > > Hi, > > Peter Chen <hzpeterc...@gmail.com> writes: > > On Mon, May 02, 2016 at 11:39:03AM +0300, Mathias Nyman wrote: > >> The current implemenentation restart the sent pattern for each ent

Re: [PATCH] usb: misc: usbtest: fix pattern tests for scatterlists.

2016-05-03 Thread Peter Chen
from this list: send the line "unsubscribe linux-usb" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v6 07/12] usb: otg: add OTG/dual-role core

2016-04-27 Thread Peter Chen
On Wed, Apr 27, 2016 at 01:59:44PM +0300, Roger Quadros wrote: > Hi, > > On 27/04/16 06:15, Peter Chen wrote: > > On Tue, Apr 26, 2016 at 04:21:07PM +0800, Peter Chen wrote: > >> On Tue, Apr 26, 2016 at 07:00:22AM +, Jun Li wrote: > >>> Hi > >>&g

Re: [PATCH 1/2] usb: chipidea: add flag CI_HDRC_DP_ALWAYS_PULLUP

2016-04-26 Thread Peter Chen
C_BSVIS | OTGSC_BSVIE); > > > > + if (ci->dp_always_pullup) > > + usb_gadget_vbus_connect(>gadget); > > + > > return 0; > > } > > > > Tried the above none the less, but no change in previous observations. > -- Be

Re: [PATCH v2 0/4] usb: chipidea: Add usb charger detection support

2016-04-26 Thread Peter Chen
nclude/linux/usb/chipidea.h | 18 ++ > 6 files changed, 303 insertions(+), 1 deletion(-) > > -- > 1.9.1 > Since Baolin's usb charger patch set has not been merged, please re-send them after merging. I have not found problem during this cycle review. --

Re: [PATCH v6 07/12] usb: otg: add OTG/dual-role core

2016-04-26 Thread Peter Chen
On Tue, Apr 26, 2016 at 04:21:07PM +0800, Peter Chen wrote: > On Tue, Apr 26, 2016 at 07:00:22AM +, Jun Li wrote: > > Hi > > > > > -Original Message- > > > From: Peter Chen [mailto:hzpeterc...@gmail.com] > > > Sent: Tuesday, April 26, 201

Re: [PATCH RFT] usb: chipidea: host: disable io watchdog

2016-04-26 Thread Peter Chen
On Tue, Apr 26, 2016 at 11:27:17AM +0200, Lucas Stach wrote: > Am Dienstag, den 26.04.2016, 09:58 +0800 schrieb Peter Chen: > > On Mon, Apr 25, 2016 at 12:55:42PM +0200, Lucas Stach wrote: > > > The Chipidea EHCI core seems to behave sanely and doesn't need > > > the IO

Re: [PATCH v6 07/12] usb: otg: add OTG/dual-role core

2016-04-26 Thread Peter Chen
On Tue, Apr 26, 2016 at 07:00:22AM +, Jun Li wrote: > Hi > > > -Original Message- > > From: Peter Chen [mailto:hzpeterc...@gmail.com] > > Sent: Tuesday, April 26, 2016 2:28 PM > > To: Jun Li <jun...@nxp.com> > > Cc: Roger Quadros <rog.

Re: [PATCH v6 07/12] usb: otg: add OTG/dual-role core

2016-04-26 Thread Peter Chen
On Tue, Apr 26, 2016 at 05:11:36AM +, Jun Li wrote: > Hi > > > -Original Message- > > From: Peter Chen [mailto:hzpeterc...@gmail.com] > > Sent: Tuesday, April 26, 2016 11:47 AM > > To: Jun Li <jun...@nxp.com> > > Cc: Roger Quadros <rog.

Re: [PATCH v6 07/12] usb: otg: add OTG/dual-role core

2016-04-25 Thread Peter Chen
gt; > + wait = usb_otg_get_wait(dev); > > + mutex_unlock(_list_mutex); > > + if (wait) { > > + /* register pending host/gadget and flush from list */ > > + usb_otg_flush_wait(dev); > > + } > > + > > + return otg; > &g

Re: [PATCH RFT] usb: chipidea: host: disable io watchdog

2016-04-25 Thread Peter Chen
t; if (ret) > return ret; > > + ehci->need_io_watchdog = 0; > + > ci_platform_configure(ci); > > return ret; -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 5/5] doc: usb: ci-hdrc-usb2: add property usb-charger-detection

2016-04-25 Thread Peter Chen
On Mon, Apr 25, 2016 at 10:09:20AM +, Jun Li wrote: > Hi > > > -Original Message- > > From: Peter Chen [mailto:hzpeterc...@gmail.com] > > Sent: Monday, April 25, 2016 2:23 PM > > To: Jun Li <jun...@nxp.com> > > Cc: Peter Chen <p

Re: [PATCH 5/5] doc: usb: ci-hdrc-usb2: add property usb-charger-detection

2016-04-25 Thread Peter Chen
ger detect function provided by usb > + module; if your usb charger type detection done by PMIC, don't enable this. > If the user doesn't set it at dts, and detection is done by PMIC, would you show us the flow how it work at chipidea driver? -- Best Regards, Peter Chen -- To unsubscribe

Re: [PATCH 1/5] usb: chipidea: add usb charger detection support

2016-04-25 Thread Peter Chen
BIT(12) > enum usb_dr_modedr_mode; > #define CI_HDRC_CONTROLLER_RESET_EVENT 0 > #define CI_HDRC_CONTROLLER_STOPPED_EVENT 1 > void(*notify_event) (struct ci_hdrc *ci, unsigned event); > + enum usb_charger_type (*usb_charger_det)(struct c

Re: [PATCH 4/5] usb: chipidea: imx: add usb charger detection for imx7d

2016-04-25 Thread Peter Chen
On Mon, Apr 18, 2016 at 04:17:48PM +0800, Li Jun wrote: > Adds imx7d usb charger detection implementation, which needs pull up > DP line before do secondary detection and pull down DP afterwards. > You can merge patch 3 and patch 4 as one patch. Acked-by: Peter Chen <peter.

<    4   5   6   7   8   9   10   11   12   13   >