Re: [PATCH v4 4/4] phy: add phy-hi6220-usb

2015-02-26 Thread zhangfei
Hi, Roger On 02/24/2015 06:13 PM, Roger Quadros wrote: On Sat, Feb 21, 2015 at 11:03:05PM +0800, zhangfei wrote: +static void hi6220_start_peripheral(struct hi6220_priv *priv, bool on) +{ +struct usb_otg *otg = priv->phy.otg; + +if (!otg->gadget) +return; + +if (on) +

Re: [PATCH v4 4/4] phy: add phy-hi6220-usb

2015-02-26 Thread Roger Quadros
Zhangfei, On 26/02/15 10:48, zhangfei wrote: > Hi, Roger > > On 02/24/2015 06:13 PM, Roger Quadros wrote: On Sat, Feb 21, 2015 at 11:03:05PM +0800, zhangfei wrote: > +static void hi6220_start_peripheral(struct hi6220_priv *priv, bool > on) > +{ > +struct

[PATCH V8 00/10] USB: f81232: V8 patches

2015-02-26 Thread Peter Hung
This series patch V8 is changed from V7 as following: 1. The V7 MSR strange delta value is checked with locking problem. We changed f81232_set_mctrl() & f81232_read_msr() lock mechanism, the old version is only locked with variable protection, new version will lock from start to end with

[PATCH V8 10/10] USB: f81232: modify/add author

2015-02-26 Thread Peter Hung
Add me to co-author and fix no '>' in greg kh's email Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/serial/f81232.c b/drivers/usb/serial/f81232.c index 0b7b69a..65d5cf6 100644 --- a/drivers/usb/serial/f

[PATCH V8 08/10] USB: f81232: clarify f81232_ioctl() and fix

2015-02-26 Thread Peter Hung
We extract TIOCGSERIAL section in f81232_ioctl() to f81232_get_serial_info() to make it clarify. Also we fix device type from 16654 to 16550A, and set it's baud_base to 115200 (1.8432MHz/16). Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 30 +++--- 1 file c

[PATCH V8 09/10] USB: f81232: cleanup non-used define

2015-02-26 Thread Peter Hung
We remove non-used define in this patch to avoid wrong usage. Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 14 -- 1 file changed, 14 deletions(-) diff --git a/drivers/usb/serial/f81232.c b/drivers/usb/serial/f81232.c index 21f2342..0b7b69a 100644 --- a/drivers/usb/ser

[PATCH V8 07/10] USB: f81232: implement set_termios()

2015-02-26 Thread Peter Hung
The original driver had do not any h/w change in driver. This patch implements with configure H/W for baud/parity/word length/stop bits functional in f81232_set_termios(). This patch also implement DTR/RTS control when baudrate B0. We drop DTR/RTS when B0, otherwise enable it. We are checking bau

[PATCH V8 04/10] USB: f81232: implement read IIR/MSR with endpoint

2015-02-26 Thread Peter Hung
The interrupt endpoint will report current IIR. If we got IIR with MSR changed , We will do read MSR with interrupt_work worker to do f81232_read_msr() function. Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 126 +--- 1 file changed, 118 inse

[PATCH V8 06/10] USB: f81232: implement port enable/disable method

2015-02-26 Thread Peter Hung
We put FCR/IER initial step to f81232_port_enable()/f81232_port_disable(). When port is open, it set MSR interrupt on. Otherwise set it off. Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 49 + 1 file changed, 49 insertions(+) diff --git

[PATCH V8 05/10] USB: f81232: implement MCR/MSR function

2015-02-26 Thread Peter Hung
This patch implement relative MCR/MSR function, such like tiocmget()/tiocmset()/dtr_rts()/carrier_raised() original f81232_carrier_raised() compared with wrong value UART_DCD. It's should compared with UART_MSR_DCD. Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 139 +++

[PATCH V8 02/10] USB: f81232: implement RX bulk-in EP

2015-02-26 Thread Peter Hung
The F81232 bulk-in is RX data + LSR channel, data format is [LSR+Data][LSR+Data]. , We had implemented in f81232_process_read_urb(). Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 71 +++-- 1 file changed, 37 insertions(+), 34 deletions(-)

[PATCH V8 03/10] USB: f81232: change lock mechanism

2015-02-26 Thread Peter Hung
The original driver lock with spin_lock_irqsave()/spin_unlock_irqrestore() because of it's maybe used in interrupt context f81232_process_read_urb(). We had remove it from previous patch "implement RX bulk-in EP", so we can change it from busying loop spin_lock to sleepable mutex_lock. Signed-off

[PATCH V8 01/10] USB: f81232: rename private struct member name

2015-02-26 Thread Peter Hung
Change private struct member name from line_status to modem_status. It will store MSR for some functions used Signed-off-by: Peter Hung --- drivers/usb/serial/f81232.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/usb/serial/f81232.c b/drivers/usb/serial/f81

Re: [PATCH] usb: isp1760: fix peripheral/device controller chip id

2015-02-26 Thread Sudeep Holla
Hi Laurent, On 25/02/15 22:27, Laurent Pinchart wrote: Hi Sudeep, Thank you for the patch. On Tuesday 24 February 2015 17:53:42 Sudeep Holla wrote: As per the ISP1761 data sheet, the DcChipID register represents the hardware version number (0015h) and the chip ID (8210h) for the Peripheral Co

[PATCH] pidff driver should work correctly with more than one concurrent effect

2015-02-26 Thread Jim Keir
The PID driver (usbhid/hid-pidff.c) does not set the effect ID when uploading an effect. The result is that the initial upload works but subsequent uploads to modify effect parameters are all directed at the last-created effect. The targeted effect ID must be passed back to the device when effect

re: usb-gadget: Initial merge of target module for UASP + BOT

2015-02-26 Thread Dan Carpenter
Hello Sebastian Andrzej Siewior, The patch c52661d60f63: "usb-gadget: Initial merge of target module for UASP + BOT" from May 3, 2012, leads to the following static checker warning: drivers/usb/gadget/legacy/tcm_usb_gadget.c:1155 usbg_submit_command() warn: bool is not less than z

[PATCH v2] usb: isp1760: add peripheral/device controller chip id

2015-02-26 Thread Sudeep Holla
As per the SAF1761 data sheet[0], the DcChipID register represents the hardware version number (0001h) and the chip ID (1582h) for the Peripheral Controller. However as per the ISP1761 data sheet[1], the DcChipID register represents the hardware version number (0015h) and the chip ID (8210h) for t

Re: [PATCH 3/3] usb: chipidea: use hrtimer for otg fsm timers

2015-02-26 Thread Peter Chen
On Mon, Feb 09, 2015 at 02:54:48PM +0800, Li Jun wrote: > From: Li Jun > > Current otg fsm timers are using controller 1ms irq and count it, this patch > is to replace it with hrtimer solution, use one hrtimer for all otg timers. > > Signed-off-by: Li Jun > --- > drivers/usb/chipidea/ci.h

[PATCH 0/4] xen, usb: support pvUSB drivers

2015-02-26 Thread Juergen Gross
This series adds XEN pvUSB support. With pvUSB it is possible to use physical USB devices from a XEN domain. The support consists of a backend in the privileged Domain-0 doing the real I/O and a frontend in the unprivileged domU passing I/O-requests to the backend. The code is taken (and adapted)

[PATCH 1/4] usb: Add Xen pvUSB protocol description

2015-02-26 Thread Juergen Gross
Add the definition of pvUSB protocol used between the pvUSB frontend in a Xen domU and the pvUSB backend in a Xen driver domain (usually Dom0). This header was originally provided by Fujitsu for Xen based on Linux 2.6.18. Changes are: - adapt to Linux style guide Signed-off-by: Juergen Gross --

[PATCH 3/4] usb: Introduce Xen pvUSB backend

2015-02-26 Thread Juergen Gross
Introduces the Xen pvUSB backend. With pvUSB it is possible for a Xen domU to communicate with a USB device assigned to that domU. The communication is all done via the pvUSB backend in a driver domain (usually Dom0) which is owner of the physical device. The code is taken from the pvUSB implement

[PATCH 2/4] usb: Introduce Xen pvUSB frontend

2015-02-26 Thread Juergen Gross
Introduces the Xen pvUSB frontend. With pvUSB it is possible for a Xen domU to communicate with a USB device assigned to that domU. The communication is all done via the pvUSB backend in a driver domain (usually Dom0) which is owner of the physical device. The code is taken from the pvUSB implemen

[PATCH 4/4] xen: add Xen pvUSB maintainer

2015-02-26 Thread Juergen Gross
Add myself as maintainer for the Xen pvUSB stuff. Signed-off-by: Juergen Gross --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index ddc5a8c..8ec1e1f 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10787,6 +10787,14 @@ F: drivers/scsi/xen-

Re: [PATCH 2/4] usb: Introduce Xen pvUSB frontend

2015-02-26 Thread Oliver Neukum
On Thu, 2015-02-26 at 14:35 +0100, Juergen Gross wrote: > + > + /* reset completion */ > + if ((info->ports[wIndex].status & > USB_PORT_STAT_RESET) != 0 && > + time_after_eq(jiffies, > info->ports[wIndex].timeout)) { > + info->port

Re: [PATCH v3] xhci: fix reporting of 0-sized URBs in control endpoint

2015-02-26 Thread Mathias Nyman
... > > The second event is always COMP_SUCCESS and the event->transfer_len is > always set to 0 in that one. The 3 cases I've seen are: > > case 1: 1 event on last TRB > COMP_SUCCESS, event->len=0 > > case 2: short event but with data > COMP_SHORT_TX, event->len < urb->transfer_buffer_len

Re: Additional device id's for cp210x

2015-02-26 Thread Johan Hovold
[ Adding the linux-usb list as CC. ] On Thu, Feb 26, 2015 at 02:04:46PM +0100, Michiel vdG wrote: > Hi! > > I'm contacting you for Lunatico Astronomia S. L. in Spain, they produce > among other things USB devices for astronomy hobbyists and professionals. > One such device should trigger the cp21

[PATCH 1/8] ARM OMAP2+ GPMC: don't undef DEBUG

2015-02-26 Thread Robert ABEL
OMAP2+ GPMC driver undefines DEBUG, which makes it unnecessarily hard to turn DEBUG on. Remove the offending lines. Signed-off-by: Robert ABEL --- drivers/memory/omap-gpmc.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/memory/omap-gpmc.c b/drivers/memory/omap-gpmc.c index 24696f5

[PATCH 8/8] ARM OMAP2+ GPMC: fix programming/showing reserved timing parameters

2015-02-26 Thread Robert ABEL
GPMC_CONFIG1_i parameters CLKACTIVATIONTIME and WAITMONITORINGTIME have reserved values. Raise an error if calculated timings try to program reserved values. GPMC_CONFIG1_i ATTACHEDDEVICEPAGELENGTH and DEVICESIZE were already checked when parsing the DT. Explicitly comment invalid values on gpmc_

[PATCH 4/8] ARM OMAP2+ GPMC: change get_gpmc_timing_reg output for DTS

2015-02-26 Thread Robert ABEL
DTS output was formatted to require additional work when copy-pasting into DTS. Nano-second timings were replaced with interval of values that produce the same number of clock ticks. Signed-off-by: Robert ABEL --- drivers/memory/omap-gpmc.c | 35 ++- 1 file change

[PATCH 2/8] ARM OMAP2+ GPMC: add bus children

2015-02-26 Thread Robert ABEL
This patch adds support for spawning buses as children of the GPMC. Signed-off-by: Robert ABEL --- drivers/memory/omap-gpmc.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/drivers/memory/omap-gpmc.c b/drivers/memory/omap-gpmc.c index 5cabac8..74a8c52 1006

[PATCH 0/8] ARM OMAP2+ GPMC: fixes and bus children

2015-02-26 Thread Robert ABEL
These are the changes I proposed in three separate patchsets #([1], [2], [3]) rebased to 3.19 as well as new changes for little bugs I noticed while preparing this patchset. 1. DEBUG was undefined in source code --> remove offending lines 2. add capability to have busses as children of the GPMC an

[PATCH 4/8] ARM OMAP2+ GPMC: fix debug output alignment

2015-02-26 Thread Robert ABEL
GPMC debug output is aligned to 10 characters for field names. However, some fields have bigger names, screwing up the alignment. Consequently, alignment was changed to longest field name (17 chars) for now. Signed-off-by: Robert ABEL --- drivers/memory/omap-gpmc.c | 2 +- 1 file changed, 1 inse

[PATCH 7/8] ARM OMAP2+ GPMC: fix WAITMONITORINGTIME divider bug

2015-02-26 Thread Robert ABEL
The WAITMONITORINGTIME is expressed as a number of GPMC_CLK clock cycles, even though the access is defined as asynchronous, and no GPMC_CLK clock is provided to the external device. Still, GPMCFCLKDIVIDER is used as a divider for the GPMC clock, so it must be programmed to define the correct WAITM

Re: [PATCH v3] xhci: fix reporting of 0-sized URBs in control endpoint

2015-02-26 Thread Alan Stern
On Thu, 26 Feb 2015, Mathias Nyman wrote: > I'm starting to like your idea of setting the urb->actual_length in advance, > It may actually simplify things. But it will make unlinking more difficult. Also, what will you do if there is more than one TRB? Alan Stern -- To unsubscribe from this l

[PATCH 5/8] ARM OMAP2+ GPMC: always program GPMCFCLKDIVIDER

2015-02-26 Thread Robert ABEL
The WAITMONITORINGTIME is expressed as a number of GPMC_CLK clock cycles, even though the access is defined as asynchronous, and no GPMC_CLK clock is provided to the external device. Still, GPMCFCLKDIVIDER is used as a divider for the GPMC clock, so it must be programmed to define the correct WAITM

[PATCH 6/8] ARM OMAP2+ GPMC: calculate GPMCFCLKDIVIDER based on WAITMONITORINGTIME

2015-02-26 Thread Robert ABEL
The WAITMONITORINGTIME is expressed as a number of GPMC_CLK clock cycles, even though the access is defined as asynchronous, and no GPMC_CLK clock is provided to the external device. Still, GPMCFCLKDIVIDER is used as a divider for the GPMC clock, so it must be programmed to define the correct WAITM

Re: [PATCH 4/8] ARM OMAP2+ GPMC: change get_gpmc_timing_reg output for DTS

2015-02-26 Thread Sergei Shtylyov
Hello. On 02/26/2015 05:45 PM, Robert ABEL wrote: DTS output was formatted to require additional work when copy-pasting into DTS. Nano-second timings were replaced with interval of values that produce the same number of clock ticks. Signed-off-by: Robert ABEL --- drivers/memory/omap-gpmc.

[PATCH 6/7] usb: musb: core: there is no connect interrupt in peripheral mode

2015-02-26 Thread Felipe Balbi
MUSB does not generate a connect IRQ when working in peripheral mode. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 9beb724a586a..e23eb3e517de 100644 --- a/driv

[PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
There was already a proper place where we were checking for babble interrupts, move babble recovery there. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/mus

[PATCH 7/7] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Felipe Balbi
musb->int_usb already contains the correct information for musb-core to handle babble. In fact, this very check was just causing a nonsensical babble interrupt storm because. With this I can get test.sh to run and, even though all tests fail with timeout, that's still better than locking up the s

[PATCH 5/7] usb: musb: core: remove unnecessary reg access from resume IRQ

2015-02-26 Thread Felipe Balbi
when musb is operating as host and a remote wakeup fires up, a resume interrupt will be raised. At that point SUSPENDM bit is automatically cleared and RESUME bit is automatically set. Remove those two from IRQ handler. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 15 -

[PATCH 2/7] usb: musb: core: add missing curly braces

2015-02-26 Thread Felipe Balbi
no functional changes, clean up only. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 625ff4321505..2767ce1bf016 100644 --- a/drivers/usb/musb/mu

[PATCH 1/7] usb: musb: core: remove unnecessary logical comparison

2015-02-26 Thread Felipe Balbi
devctl & MUSB_DEVCTL_HM represents a single bit, just check for the bit, there's really no need to compare the result against 0. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers

Re: [PATCH 7/7] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > musb->int_usb already contains the correct > information for musb-core to handle babble. > > In fact, this very check was just causing a > nonsensical babble interrupt storm because. because of what? > > With this I can get test.sh

[PATCH 4/7] usb: musb: core: break long line

2015-02-26 Thread Felipe Balbi
no functional changes, clean up only. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 0569b24719e6..ad895da33047 100644 --- a/drivers/usb/musb/musb

[PATCH 2/5] can: kvaser_usb: Read all messages in a bulk-in URB buffer

2015-02-26 Thread Ahmed S. Darwish
From: Ahmed S. Darwish The Kvaser firmware can only read and write messages that are not crossing the USB endpoint's wMaxPacketSize boundary. While receiving commands from the CAN device, if the next command in the same URB buffer crossed that max packet size boundary, the firmware puts a zero-le

[PATCH 3/5] can: kvaser_usb: Utilize all possible tx URBs

2015-02-26 Thread Ahmed S. Darwish
From: Ahmed S. Darwish The driver currently limits the number of outstanding, not yet ACKed, transfers to 16 URBs. Meanwhile, the Kvaser firmware provides its actual max supported number of outstanding transmissions in its reply to the CMD_GET_SOFTWARE_INFO message. One example is the UsbCan-II

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > There was already a proper place where we were > checking for babble interrupts, move babble > recovery there. I commented on the same before, discussed in [1]. [1]: http://marc.info/?l=linux-usb&m=140109400304196&w=2 > > Signed-o

[PATCH] USB: pl2303: disable break on shutdown

2015-02-26 Thread Johan Hovold
Currently an enabled break state is not disabled on final close nor on re-open and has to be disabled manually. Fix this by disabling break on port shutdown. Reported-by: Jari Ruusu Tested-by: Jari Ruusu Signed-off-by: Johan Hovold --- drivers/usb/serial/pl2303.c | 18 +- 1 fi

Re: [PATCH 7/7] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 09:18:04AM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > > musb->int_usb already contains the correct > > information for musb-core to handle babble. > > > > In fact, this very check was just causing a > > nonsensical babble int

Re: [PATCH v3] xhci: fix reporting of 0-sized URBs in control endpoint

2015-02-26 Thread Mathias Nyman
On 26.02.2015 16:57, Alan Stern wrote: > On Thu, 26 Feb 2015, Mathias Nyman wrote: > >> I'm starting to like your idea of setting the urb->actual_length in advance, >> It may actually simplify things. > > But it will make unlinking more difficult. Also, what will you do if > there is more than

[RFC PATCH] xhci: fix reporting of 0-sized URBs in control endpoints

2015-02-26 Thread Mathias Nyman
When a control transfer has a short data stage, the xHCI controller generates two transfer events: a COMP_SHORT_TX event that specifies the untransferred amount, and a COMP_SUCCESS event. But when the data stage is not short, only the COMP_SUCCESS event occurs. Therefore, xhci-hcd sets urb->actual_

Re: [RFC PATCH] xhci: fix reporting of 0-sized URBs in control endpoints

2015-02-26 Thread Mathias Nyman
On 26.02.2015 18:12, Mathias Nyman wrote: > When a control transfer has a short data stage, the xHCI controller generates > two transfer events: a COMP_SHORT_TX event that specifies the untransferred > amount, and a COMP_SUCCESS event. But when the data stage is not short, only > the COMP_SUCCESS e

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > There was already a proper place where we were > checking for babble interrupts, move babble > recovery there. > > Signed-off-by: Felipe Balbi > --- > drivers/usb/musb/musb_core.c | 13 ++--- > 1 file changed, 6 insertions(+

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 10:21:38AM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > > There was already a proper place where we were > > checking for babble interrupts, move babble > > recovery there. > > > > Signed-off-by: Felipe Balbi > > --- > > driv

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 10:31 AM, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 10:21:38AM -0600, Bin Liu wrote: >> Felipe, >> >> On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: >> > There was already a proper place where we were >> > checking for babble interrupts, move babble >> >

Re: [PATCH v2 1/1] USB: ch341: set tty baud speed according to tty struct

2015-02-26 Thread Johan Hovold
On Thu, Feb 19, 2015 at 11:43:27AM +0700, Johan Hovold wrote: > On Wed, Feb 18, 2015 at 03:22:30PM -0500, Nicolas PLANEL wrote: > > The ch341_set_baudrate() function initialize the device baud speed according > > to the value on priv->baud_rate. By default the ch341_open() set it to a > > hardcoded

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 10:37:50AM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 10:31 AM, Felipe Balbi wrote: > > On Thu, Feb 26, 2015 at 10:21:38AM -0600, Bin Liu wrote: > >> Felipe, > >> > >> On Thu, Feb 26, 2015 at 9:07 AM, Felipe Balbi wrote: > >> > There was already a proper

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 10:44:15AM -0600, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 10:37:50AM -0600, Bin Liu wrote: > > Felipe, > > > > On Thu, Feb 26, 2015 at 10:31 AM, Felipe Balbi wrote: > > > On Thu, Feb 26, 2015 at 10:21:38AM -0600, Bin Liu wrote: > > >> Felipe, > > >> > > >> On Thu, Fe

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 10:54 AM, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 10:44:15AM -0600, Felipe Balbi wrote: >> On Thu, Feb 26, 2015 at 10:37:50AM -0600, Bin Liu wrote: >> > Felipe, >> > >> > On Thu, Feb 26, 2015 at 10:31 AM, Felipe Balbi wrote: >> > > On Thu, Feb 26, 2015 at 10

Re: [PATCH 4/4] xen: add Xen pvUSB maintainer

2015-02-26 Thread Konrad Rzeszutek Wilk
On February 26, 2015 8:35:17 AM EST, Juergen Gross wrote: >Add myself as maintainer for the Xen pvUSB stuff. > >Signed-off-by: Juergen Gross >--- > MAINTAINERS | 8 > 1 file changed, 8 insertions(+) > >diff --git a/MAINTAINERS b/MAINTAINERS >index ddc5a8c..8ec1e1f 100644 >--- a/MAINTAINER

[PATCH] USB: serial: cp210x: Adding Seletek device id's

2015-02-26 Thread Michiel vdG
These device ID's are not associated with the cp210x module currently, but should be. This patch allows the devices to operate upon connecting them to the usb bus as intended. Tested personally, reviewed by manufacturer diff --git a/drivers/usb/serial/cp210x.c b/drivers/usb/serial/cp210x.c index

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
Hi, On Thu, Feb 26, 2015 at 11:20:29AM -0600, Bin Liu wrote: > >> > >> > There was already a proper place where we were > >> > >> > checking for babble interrupts, move babble > >> > >> > recovery there. > >> > >> > > >> > >> > Signed-off-by: Felipe Balbi > >> > >> > --- > >> > >> > drivers/usb/

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 11:40 AM, Felipe Balbi wrote: > Hi, > > On Thu, Feb 26, 2015 at 11:20:29AM -0600, Bin Liu wrote: >> >> > >> > There was already a proper place where we were >> >> > >> > checking for babble interrupts, move babble >> >> > >> > recovery there. >> >> > >> > >> >> > >

Re: [PATCH] USB: serial: cp210x: Adding Seletek device id's

2015-02-26 Thread Johan Hovold
On Thu, Feb 26, 2015 at 06:37:17PM +0100, Michiel vdG wrote: > These device ID's are not associated with the cp210x module currently, > but should be. This patch allows the devices to operate upon > connecting them to the usb bus as intended. > > Tested personally, reviewed by manufacturer Thanks

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 11:51:11AM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 11:40 AM, Felipe Balbi wrote: > > Hi, > > > > On Thu, Feb 26, 2015 at 11:20:29AM -0600, Bin Liu wrote: > >> >> > >> > There was already a proper place where we were > >> >> > >> > checking for babble in

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
Hi again, On Thu, Feb 26, 2015 at 11:54:43AM -0600, Felipe Balbi wrote: > > >> >> > >> > There was already a proper place where we were > > >> >> > >> > checking for babble interrupts, move babble > > >> >> > >> > recovery there. > > >> >> > >> > > > >> >> > >> > Signed-off-by: Felipe Balbi > > >

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 11:54 AM, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 11:51:11AM -0600, Bin Liu wrote: >> Felipe, >> >> On Thu, Feb 26, 2015 at 11:40 AM, Felipe Balbi wrote: >> > Hi, >> > >> > On Thu, Feb 26, 2015 at 11:20:29AM -0600, Bin Liu wrote: >> >> >> > >> > There was al

Re: [PATCH v3] xhci: fix reporting of 0-sized URBs in control endpoint

2015-02-26 Thread Alan Stern
On Thu, 26 Feb 2015, Mathias Nyman wrote: > On 26.02.2015 16:57, Alan Stern wrote: > > On Thu, 26 Feb 2015, Mathias Nyman wrote: > > > >> I'm starting to like your idea of setting the urb->actual_length in > >> advance, > >> It may actually simplify things. > > > > But it will make unlinking mo

Re: [PATCH 3/7] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Bin Liu
On Thu, Feb 26, 2015 at 11:56 AM, Felipe Balbi wrote: > Hi again, > > On Thu, Feb 26, 2015 at 11:54:43AM -0600, Felipe Balbi wrote: >> > >> >> > >> > There was already a proper place where we were >> > >> >> > >> > checking for babble interrupts, move babble >> > >> >> > >> > recovery there. >> >

Re: [RFC PATCH] xhci: fix reporting of 0-sized URBs in control endpoints

2015-02-26 Thread Alan Stern
On Thu, 26 Feb 2015, Mathias Nyman wrote: > On 26.02.2015 18:12, Mathias Nyman wrote: > > When a control transfer has a short data stage, the xHCI controller > > generates > > two transfer events: a COMP_SHORT_TX event that specifies the untransferred > > amount, and a COMP_SUCCESS event. But whe

[PATCH v2 01/15] usb: musb: core: remove unnecessary logical comparison

2015-02-26 Thread Felipe Balbi
devctl & MUSB_DEVCTL_HM represents a single bit, just check for the bit, there's really no need to compare the result against 0. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers

[PATCH v2 03/15] usb: musb: core: fix highspeed check

2015-02-26 Thread Felipe Balbi
FSDEV is set for both HIGH and FULL speeds, the correct HIGHSPEED check is done through power register's HSMODE bit. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 21 ++--- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/drivers/usb/musb/musb_core.

[PATCH v2 04/15] usb: musb: dsps: return error code if reset fails

2015-02-26 Thread Felipe Balbi
if reset fails, we should return a *negative* error code, not a positive value. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_dsps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c index 53bd0e71d19f..7584601

[PATCH v2 07/15] usb: musb: core: remove unnecessary reg access from resume IRQ

2015-02-26 Thread Felipe Balbi
when musb is operating as host and a remote wakeup fires up, a resume interrupt will be raised. At that point SUSPENDM bit is automatically cleared and RESUME bit is automatically set. Remove those two from IRQ handler. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 15 -

[PATCH v2 06/15] usb: musb: core: break long line

2015-02-26 Thread Felipe Balbi
no functional changes, clean up only. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index f63599368645..10d3f10ba728 100644 --- a/drivers/usb/musb/musb

[PATCH v2 09/15] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Felipe Balbi
musb->int_usb already contains the correct information for musb-core to handle babble. In fact, this very check was just causing a nonsensical babble interrupt storm because. With this I can get test.sh to run and, even though all tests fail with timeout, that's still better than locking up the s

[PATCH v2 13/15] usb: musb: core: refactor IRQ enable/disable to separate functions

2015-02-26 Thread Felipe Balbi
sometimes we want to just mask/unmask interrupts without touching devctl register. For those cases, let's introduce musb_enable_interrupts and musb_disable_interrupts() Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 37 ++--- 1 file changed, 26 ins

[PATCH v2 12/15] usb: musb: dsps: add dsps_ prefix to sw_babble_control

2015-02-26 Thread Felipe Balbi
this makes it easier to filter function traces. No functional changes. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_dsps.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c index 285f0e4b083d..b52eecaf11a4

[PATCH v2 08/15] usb: musb: core: there is no connect interrupt in peripheral mode

2015-02-26 Thread Felipe Balbi
MUSB does not generate a connect IRQ when working in peripheral mode. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 81909ea74353..c3c5a6462600 100644 --- a/driv

[PATCH v2 11/15] usb: musb: core: controller drops session automatically

2015-02-26 Thread Felipe Balbi
Whenever babble happens, MUSB controller will drop session automatically. The only case where it won't drop the session, is when we're running on AM335x and SW_SESSION_CTRL bit has been set. In that case, controller will not touch session bit so SW has a chance to recover from babble condition. S

[PATCH v2 02/15] usb: musb: core: add missing curly braces

2015-02-26 Thread Felipe Balbi
no functional changes, clean up only. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index 625ff4321505..2767ce1bf016 100644 --- a/drivers/usb/musb/mu

[PATCH v2 05/15] usb: musb: core: move babble recovery inside babble check

2015-02-26 Thread Felipe Balbi
There was already a proper place where we were checking for babble interrupts, move babble recovery there. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/mus

[PATCH v2 15/15] usb: musb: core: decrease delayed_work time

2015-02-26 Thread Felipe Balbi
When babble IRQ happens, we need to wait only 5.3us (320 cycles of 60MHz clock), we will give it some slack and schedule our work a 10 usecs into the future. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/u

[PATCH v2 14/15] usb: musb: don't touch devctl from babble recovery

2015-02-26 Thread Felipe Balbi
We do *not* want to touch devctl at all when trying to recover from babble. All we want to do is mask IRQs until we're done without our babble recovery, at which point we will unmask IRQs. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_core.c | 6 -- 1 file changed, 4 insertions(+), 2

[PATCH v2 10/15] usb: musb: dsps: check for the single bit

2015-02-26 Thread Felipe Balbi
We want to check if that particular bit is set. It could very well be that bootloader (or romcode) has fiddled with MUSB before us which could leave other bits set in this register. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_dsps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

Re: [PATCH v2 03/15] usb: musb: core: fix highspeed check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 12:25:16PM -0600, Felipe Balbi wrote: > FSDEV is set for both HIGH and FULL speeds, > the correct HIGHSPEED check is done through > power register's HSMODE bit. > > Signed-off-by: Felipe Balbi I'm still unsure if we should really ignore babble on FS/LS. It seems to me we

[PATCH] usb: gadget: f_mass_storage: use defined constant instead of numeric value

2015-02-26 Thread Tal Shorer
Signed-off-by: Tal Shorer --- drivers/usb/gadget/function/f_mass_storage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/function/f_mass_storage.c b/drivers/usb/gadget/function/f_mass_storage.c index 811929c..6d5ca2b 100644 --- a/drivers/usb/gadget/functi

Re: URB IRQ fires on URB after usb_kill_urb() already completed

2015-02-26 Thread Alan Stern
On Wed, 25 Feb 2015, Devin Heitmueller wrote: > Hi Alan, > > I think I see what's going on. Permit me to comment on your > explanation of urb->use_count first, since it's relevant later on. I won't go over this in great detail, because I think your proposed explanation is wrong. My impression

Re: [PATCH v2] usb: isp1760: add peripheral/device controller chip id

2015-02-26 Thread Laurent Pinchart
Hi Sudeep, Thank you for the patch. On Thursday 26 February 2015 11:47:57 Sudeep Holla wrote: > As per the SAF1761 data sheet[0], the DcChipID register represents > the hardware version number (0001h) and the chip ID (1582h) for the > Peripheral Controller. > > However as per the ISP1761 data sh

Re: [PATCH] USB: serial: cp210x: Adding Seletek device id's

2015-02-26 Thread Michiel
On 26-02-15 18:54, Johan Hovold wrote: > Thanks for the patch. Looks good, but there are a few minor issues: Oh webmail... :/ version 2 here: These device ID's are not associated with the cp210x module currently, but should be. This patch allows the devices to operate upon connecting them to the u

Re: [PATCH v2 03/15] usb: musb: core: fix highspeed check

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 12:27 PM, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 12:25:16PM -0600, Felipe Balbi wrote: >> FSDEV is set for both HIGH and FULL speeds, >> the correct HIGHSPEED check is done through >> power register's HSMODE bit. >> >> Signed-off-by: Felipe Balbi > > I'm st

Re: [PATCH v2 09/15] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 12:25 PM, Felipe Balbi wrote: > musb->int_usb already contains the correct > information for musb-core to handle babble. > > In fact, this very check was just causing a > nonsensical babble interrupt storm because. I guess this is my English problem. I thought you

[PATCH net-next] usbnet: Fix tx_packets stat for FLAG_MULTI_FRAME drivers

2015-02-26 Thread Ben Hutchings
Currently the usbnet core does not update the tx_packets statistic for drivers with FLAG_MULTI_PACKET and there is no hook in the TX completion path where they could do this. cdc_ncm and dependent drivers are bumping tx_packets stat on the transmit path while asix and sr9800 aren't updating it at

Re: [PATCH v2 11/15] usb: musb: core: controller drops session automatically

2015-02-26 Thread Bin Liu
Felipe, On Thu, Feb 26, 2015 at 12:25 PM, Felipe Balbi wrote: > Whenever babble happens, MUSB controller will > drop session automatically. > > The only case where it won't drop the session, > is when we're running on AM335x and SW_SESSION_CTRL > bit has been set. In that case, controller will >

[RFC][PATCH] usbnet: Fix tx_bytes statistic running backward in cdc_ncm

2015-02-26 Thread Ben Hutchings
cdc_ncm disagrees with usbnet about how much framing overhead should be counted in the tx_bytes statistics, and tries 'fix' this by decrementing tx_bytes on the transmit path. But statistics must never be decremented except due to roll-over; this will thoroughly confuse user-space. Also, tx_bytes

Re: [PATCH v2 03/15] usb: musb: core: fix highspeed check

2015-02-26 Thread Bin Liu
On Thu, Feb 26, 2015 at 1:48 PM, Felipe Balbi wrote: > On Thu, Feb 26, 2015 at 01:30:21PM -0600, Bin Liu wrote: >> Felipe, >> >> On Thu, Feb 26, 2015 at 12:27 PM, Felipe Balbi wrote: >> > On Thu, Feb 26, 2015 at 12:25:16PM -0600, Felipe Balbi wrote: >> >> FSDEV is set for both HIGH and FULL speed

Re: [PATCH v2 09/15] usb: musb: dsps: remove babble check from dsps irq handler

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 01:34:03PM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 12:25 PM, Felipe Balbi wrote: > > musb->int_usb already contains the correct > > information for musb-core to handle babble. > > > > In fact, this very check was just causing a > > nonsensical babble in

Re: [PATCH v2 03/15] usb: musb: core: fix highspeed check

2015-02-26 Thread Felipe Balbi
On Thu, Feb 26, 2015 at 01:30:21PM -0600, Bin Liu wrote: > Felipe, > > On Thu, Feb 26, 2015 at 12:27 PM, Felipe Balbi wrote: > > On Thu, Feb 26, 2015 at 12:25:16PM -0600, Felipe Balbi wrote: > >> FSDEV is set for both HIGH and FULL speeds, > >> the correct HIGHSPEED check is done through > >> pow

Re: [PATCH 24/29] usb: gadget: printer: factor out f_printer

2015-02-26 Thread Felipe Balbi
On Mon, Feb 23, 2015 at 04:02:13PM +0100, Andrzej Pietrasiewicz wrote: > The legacy printer gadget now contains both a reusable printer function > and legacy gadget proper implementations interwoven, but logically > separate. This patch factors out a reusable f_printer. > > Signed-off-by: Andrzej

  1   2   >