Re: [PATCH 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread kbuild test robot
Hi Mian, [auto build test WARNING on balbi-usb/next -- if it's inappropriate base, please suggest rules for selecting the more suitable base] config: x86_64-randconfig-x013-201541 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=x86_64

Re: [PATCH 12/14] usb: dwc2: host: avoid usage of dma_alloc_coherent with irqs disabled

2015-10-12 Thread kbuild test robot
Hi Gregory, [auto build test ERROR on balbi-usb/next -- if it's inappropriate base, please suggest rules for selecting the more suitable base] config: i386-randconfig-r0-201541 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=i386 All

Re: [PATCH 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread Herrero, Gregory
On Mon, Oct 12, 2015 at 03:06:32PM +0800, kbuild test robot wrote: > Hi Mian, > > [auto build test WARNING on balbi-usb/next -- if it's inappropriate base, > please suggest rules for selecting the more suitable base] > > config: i386-randconfig-x002-201541 (attached as .config) > reproduce: >

Re: [PATCH 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread kbuild test robot
Hi Mian, [auto build test WARNING on balbi-usb/next -- if it's inappropriate base, please suggest rules for selecting the more suitable base] config: tile-allyesconfig (attached as .config) reproduce: wget

[PATCH 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread Gregory Herrero
From: Mian Yousaf Kaukab Masks for HCDMA.CTD and HCDMA.DMAAddr are incorrect. As we always start from first descriptor, no need to mask the address anyway. Signed-off-by: Mian Yousaf Kaukab Signed-off-by: Gregory Herrero

[PATCH 00/14] usb: dwc2: descriptor dma mode bug fixes

2015-10-12 Thread Gregory Herrero
Hi, This patchset contains bug fixes for host descriptor dma mode. Descriptor dma mode can't be used as the default mode since controller does not support split transfers in this mode. So we add a new configuration parameter which allows descriptor dma mode to be enabled for full-speed devices

[PATCH 11/14] usb: dwc2: host: enable descriptor dma for fs devices

2015-10-12 Thread Gregory Herrero
From: Mian Yousaf Kaukab As descriptor dma mode does not support split transfers, it can't be enabled for high speed devices. Add a core parameter to enable it for full speed devices. Ensure frame list and descriptor list are correctly freed during disconnect.

[PATCH 08/14] usb: dwc2: host: always increment available host channel during release

2015-10-12 Thread Gregory Herrero
When releasing a channel, increment hsotg->available_host_channels even in case a periodic channel is released. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/dwc2/hcd_ddma.c

[PATCH 14/14] usb: dwc2: host: use kmem cache to allocate descriptors

2015-10-12 Thread Gregory Herrero
Kmem caches help to get correct boundary for descriptor buffers which need to be 512 bytes aligned for dwc2 controller. Two kmem caches are needed for generic descriptors and for hs isochronous descriptors which doesn't have same size. Signed-off-by: Gregory Herrero

[PATCH 01/14] usb: dwc2: host: ensure filling of isoc desc is correctly done

2015-10-12 Thread Gregory Herrero
Increment qtd->isoc_frame_index_last before testing it, else below check will never be true and IOC (Interrupt On Complete) bit for last frame will never be set in descriptor status. /* Set IOC for each descriptor corresponding to last frame of URB */ if (qtd->isoc_frame_index_last ==

[PATCH 12/14] usb: dwc2: host: avoid usage of dma_alloc_coherent with irqs disabled

2015-10-12 Thread Gregory Herrero
Use Streaming DMA mappings to handle cache coherency of frame list and descriptor list. Cache are always flushed before controller access it or before cpu access it. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/core.c | 9 drivers/usb/dwc2/core.h

[PATCH 03/14] usb: dwc2: host: rework isochronous halt path

2015-10-12 Thread Gregory Herrero
When a channel is halted because of urb dequeue during transfer completion, no other qtds must be scheduled until halt is done. Moreover, all in progress qtds must be given back. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 22

[PATCH 02/14] usb: dwc2: host: set active bit in isochronous descriptors

2015-10-12 Thread Gregory Herrero
Active bit must be enabled in all scheduled descriptors. Else transfer never start. Remove previous code which was not correctly configuring descriptors. Active bit was set before calling dwc2_fill_host_isoc_dma_desc() which is erasing dma_desc->status. Signed-off-by: Gregory Herrero

Re: [PATCH 12/14] usb: dwc2: host: avoid usage of dma_alloc_coherent with irqs disabled

2015-10-12 Thread Herrero, Gregory
On Mon, Oct 12, 2015 at 03:09:40PM +0800, kbuild test robot wrote: > Hi Gregory, > > [auto build test ERROR on balbi-usb/next -- if it's inappropriate base, > please suggest rules for selecting the more suitable base] > > config: i386-randconfig-r0-201541 (attached as .config) > reproduce: >

[PATCH 04/14] usb: dwc2: host: fix use of qtd after free in desc dma mode

2015-10-12 Thread Gregory Herrero
When completing non isoc xfer, dwc2_complete_non_isoc_xfer_ddma() is relying on qtd->n_desc to process the corresponding number of descriptors. During the processing of these descriptors, qtd could be unlinked and freed if xfer is done and urb is no more in progress. In this case,

[PATCH 05/14] usb: dwc2: host: spinlock release channel

2015-10-12 Thread Gregory Herrero
Prevent dwc2 driver from accessing channel while it frees it. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/dwc2/hcd_ddma.c b/drivers/usb/dwc2/hcd_ddma.c index 4801e69..a76a58c 100644

[PATCH 07/14] usb: dwc2: host: program descriptor for next frame

2015-10-12 Thread Gregory Herrero
Isochronous descriptor is currently programmed for the frame after the last descriptor was programmed. If the last descriptor frame underrun, then current descriptor must take this into account and must be programmed on the current frame + 1. This overrun usually happens when system is loaded and

[PATCH 06/14] usb: dwc2: host: add function to compare frame index

2015-10-12 Thread Gregory Herrero
This function allow comparing frame index used for descriptor list which has 64 entries. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd.h | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/usb/dwc2/hcd.h b/drivers/usb/dwc2/hcd.h index

[PATCH 09/14] usb: dwc2: host: process all completed urbs

2015-10-12 Thread Gregory Herrero
Process all completed urbs, if more urbs are complete by the time driver processes completion interrupt. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 38 -- 1 file changed, 36 insertions(+), 2 deletions(-) diff

[PATCH 10/14] usb: dwc2: host: free status_buf on hcd de-init

2015-10-12 Thread Gregory Herrero
status_buf needs to be freed in dwc2_hcd_remove(). Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd.c | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index af4e4a2..41c00e9

Re: [PATCH 2/3] xhci: handle no ping response error properly

2015-10-12 Thread Mathias Nyman
On 10.10.2015 00:45, Paul Zimmerman wrote: Sorry, resending as plain text. On Fri, Oct 9, 2015, Mathias Nyman wrote: + handling_skipped_tds = ep->skip && + (trb_comp_code != COMP_MISSED_INT || ^^ I think this should be &&, shouldn't it? + trb_comp_code != COMP_PING_ERR); Oh, yes,

Re: [PATCH 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread kbuild test robot
Hi Mian, [auto build test WARNING on balbi-usb/next -- if it's inappropriate base, please suggest rules for selecting the more suitable base] config: i386-randconfig-x002-201541 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=i386 All

Re: 4758dcd19a7d9ba9610b38fecb93f65f56f86346 - usb: xhci: Add support for URB_ZERO_PACKET to bulk/sg transfers; into stable?

2015-10-12 Thread Oliver Neukum
On Fri, 2015-10-09 at 11:28 +0300, Mathias Nyman wrote: > On 08.10.2015 17:40, Oliver Neukum wrote: > > Hi, > > > > it looks to me like > > > > commit 4758dcd19a7d9ba9610b38fecb93f65f56f86346 > > Author: Reyad Attiyat > > Date: Thu Aug 6 19:23:58 2015 +0300 > > > >

[PATCH] usb: dwc2: fix duplicate argument warning

2015-10-12 Thread Mian Yousaf Kaukab
Fix a duplicate argument warning reported by 0-DAY kernel test infrastructure in the following patch: 77dbf71 usb: dwc2: host: add disconnect interrupt to host only interrupts Signed-off-by: Mian Yousaf Kaukab --- drivers/usb/dwc2/core.c | 3 +-- 1 file changed, 1

Re: [PATCH v3 1/4] usb: gadget: f_midi: free usb request when done

2015-10-12 Thread Felipe Tonello
Hi Balbi, On Sun, Oct 11, 2015 at 8:08 PM, Clemens Ladisch wrote: > Felipe Balbi wrote: >> Clemens Ladisch writes: >>> Felipe Tonello wrote: req->actual == req->length means that there is no data left to enqueue, >>> >>> This condition is not checked

Re: [PATCH v3 1/4] usb: gadget: f_midi: free usb request when done

2015-10-12 Thread Felipe Tonello
Hi Clemens On Fri, Oct 9, 2015 at 10:23 AM, Clemens Ladisch wrote: > Felipe Tonello wrote: >> req->actual == req->length means that there is no data left to enqueue, > > This condition is not checked in the patch. > >> so free the request. >> >> Signed-off-by: Felipe F.

Re: [PATCH v3 1/4] usb: gadget: f_midi: free usb request when done

2015-10-12 Thread Clemens Ladisch
Felipe Tonello wrote: > On Fri, Oct 9, 2015 at 10:23 AM, Clemens Ladisch wrote: >> Felipe Tonello wrote: >>> } else if (ep == midi->in_ep) { >>> - /* Our transmit completed. See if there's more to go. >>> - *

[PATCH v2 1/3] xhci: don't finish a TD if we get a short transfer event mid TD

2015-10-12 Thread Mathias Nyman
If the difference is big enough between the bytes asked and received in a bulk transfer we can get a short transfer event pointing to a TRB in the middle of the TD. We don't want to handle the TD yet as we will anyway receive a new event for the last TRB in the TD. Hold off from finishing the TD

[PATCH v1 14/14] usb: dwc2: host: use kmem cache to allocate descriptors

2015-10-12 Thread Gregory Herrero
Kmem caches help to get correct boundary for descriptor buffers which need to be 512 bytes aligned for dwc2 controller. Two kmem caches are needed for generic descriptors and for hs isochronous descriptors which doesn't have same size. Signed-off-by: Gregory Herrero

[PATCH v1 08/14] usb: dwc2: host: always increment available host channel during release

2015-10-12 Thread Gregory Herrero
When releasing a channel, increment hsotg->available_host_channels even in case a periodic channel is released. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/dwc2/hcd_ddma.c

[PATCH v1 10/14] usb: dwc2: host: free status_buf on hcd de-init

2015-10-12 Thread Gregory Herrero
status_buf needs to be freed in dwc2_hcd_remove(). Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd.c | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index af4e4a2..41c00e9

[PATCH v1 09/14] usb: dwc2: host: process all completed urbs

2015-10-12 Thread Gregory Herrero
Process all completed urbs, if more urbs are complete by the time driver processes completion interrupt. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 38 -- 1 file changed, 36 insertions(+), 2 deletions(-) diff

[PATCH v1 13/14] usb: dwc2: host: fix descriptor list address masking

2015-10-12 Thread Gregory Herrero
From: Mian Yousaf Kaukab Masks for HCDMA.CTD and HCDMA.DMAAddr are incorrect. As we always start from first descriptor, no need to mask the address anyway. Signed-off-by: Mian Yousaf Kaukab Signed-off-by: Gregory Herrero

[PATCH v1 07/14] usb: dwc2: host: program descriptor for next frame

2015-10-12 Thread Gregory Herrero
Isochronous descriptor is currently programmed for the frame after the last descriptor was programmed. If the last descriptor frame underrun, then current descriptor must take this into account and must be programmed on the current frame + 1. This overrun usually happens when system is loaded and

[PATCH v1 11/14] usb: dwc2: host: enable descriptor dma for fs devices

2015-10-12 Thread Gregory Herrero
From: Mian Yousaf Kaukab As descriptor dma mode does not support split transfers, it can't be enabled for high speed devices. Add a core parameter to enable it for full speed devices. Ensure frame list and descriptor list are correctly freed during disconnect.

musb: communication issue with more than 12 FTDI ports

2015-10-12 Thread Yegor Yefremov
We have a problem, when using more than 12 FTDI ports. Kernels tried: 3.18.1, 4.2.3 and 4.3-rc5. SoC am335x 600MHz Below the USB topology: # lsusb -t /: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=musb-hdrc/1p, 480M /: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=musb-hdrc/1p, 480M |__

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

2015-10-12 Thread Mathias Nyman
Hi Greg These xhci fixes for usb-linus makes sure xhci can handles a couple corner case transfer situations correctly, both triggered in real life. One was the host asking for a lot of data and device returning very little. Second one about host failing to wake up device in time for a isoc

[PATCH v2 3/3] Add spurious wakeup quirk for LynxPoint-LP controllers

2015-10-12 Thread Mathias Nyman
From: Laura Abbott We received several reports of systems rebooting and powering on after an attempted shutdown. Testing showed that setting XHCI_SPURIOUS_WAKEUP quirk in addition to the XHCI_SPURIOUS_REBOOT quirk allowed the system to shutdown as expected for

[PATCH v1 04/14] usb: dwc2: host: fix use of qtd after free in desc dma mode

2015-10-12 Thread Gregory Herrero
When completing non isoc xfer, dwc2_complete_non_isoc_xfer_ddma() is relying on qtd->n_desc to process the corresponding number of descriptors. During the processing of these descriptors, qtd could be unlinked and freed if xfer is done and urb is no more in progress. In this case,

[PATCH v1 02/14] usb: dwc2: host: set active bit in isochronous descriptors

2015-10-12 Thread Gregory Herrero
Active bit must be enabled in all scheduled descriptors. Else transfer never start. Remove previous code which was not correctly configuring descriptors. Active bit was set before calling dwc2_fill_host_isoc_dma_desc() which is erasing dma_desc->status. Signed-off-by: Gregory Herrero

[PATCH v1 05/14] usb: dwc2: host: spinlock release channel

2015-10-12 Thread Gregory Herrero
Prevent dwc2 driver from accessing channel while it frees it. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/usb/dwc2/hcd_ddma.c b/drivers/usb/dwc2/hcd_ddma.c index 4801e69..a76a58c 100644

[PATCH v1 06/14] usb: dwc2: host: add function to compare frame index

2015-10-12 Thread Gregory Herrero
This function allow comparing frame index used for descriptor list which has 64 entries. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd.h | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/usb/dwc2/hcd.h b/drivers/usb/dwc2/hcd.h index

[PATCH v1 01/14] usb: dwc2: host: ensure filling of isoc desc is correctly done

2015-10-12 Thread Gregory Herrero
Increment qtd->isoc_frame_index_last before testing it, else below check will never be true and IOC (Interrupt On Complete) bit for last frame will never be set in descriptor status. /* Set IOC for each descriptor corresponding to last frame of URB */ if (qtd->isoc_frame_index_last ==

[PATCH v1 00/14] usb: dwc2: descriptor dma mode bug fixes

2015-10-12 Thread Gregory Herrero
Hi, This patchset contains bug fixes for host descriptor dma mode. Descriptor dma mode can't be used as the default mode since controller does not support split transfers in this mode. So we add a new configuration parameter which allows descriptor dma mode to be enabled for full-speed devices

[PATCH v1 03/14] usb: dwc2: host: rework isochronous halt path

2015-10-12 Thread Gregory Herrero
When a channel is halted because of urb dequeue during transfer completion, no other qtds must be scheduled until halt is done. Moreover, all in progress qtds must be given back. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/hcd_ddma.c | 22

[PATCH v1 12/14] usb: dwc2: host: avoid usage of dma_alloc_coherent with irqs disabled

2015-10-12 Thread Gregory Herrero
Use Streaming DMA mappings to handle cache coherency of frame list and descriptor list. Cache are always flushed before controller access it or before cpu access it. Signed-off-by: Gregory Herrero --- drivers/usb/dwc2/core.c | 3 ++ drivers/usb/dwc2/core.h |

Re: musb: communication issue with more than 12 FTDI ports

2015-10-12 Thread Yegor Yefremov
On Mon, Oct 12, 2015 at 11:34 AM, Yegor Yefremov wrote: > We have a problem, when using more than 12 FTDI ports. Kernels tried: > 3.18.1, 4.2.3 and 4.3-rc5. SoC am335x 600MHz > > Below the USB topology: > > # lsusb -t > /: Bus 02.Port 1: Dev 1, Class=root_hub,

Re: [PATCH] usb: musb: core: add common method of getting vbus status

2015-10-12 Thread Sergei Shtylyov
Hello. On 10/12/2015 05:14 PM, Roman Alyautdin wrote: Fix musb_platform_get_vbus_status return value in case of platform implementation is not defined, bringing expected behaviour of musb_platform_get wrapper. Add musb_vbus_show default method to determine VBUS status in case platform method

Re: [PATCH v3 1/4] usb: gadget: f_midi: free usb request when done

2015-10-12 Thread Felipe Tonello
Hi Clemens On Mon, Oct 12, 2015 at 11:16 AM, Clemens Ladisch wrote: > Felipe Tonello wrote: >> On Fri, Oct 9, 2015 at 10:23 AM, Clemens Ladisch wrote: >>> Felipe Tonello wrote: } else if (ep == midi->in_ep) { -

Re: [PATCH v3 1/4] usb: gadget: f_midi: free usb request when done

2015-10-12 Thread Clemens Ladisch
Felipe Tonello wrote: > On Mon, Oct 12, 2015 at 11:16 AM, Clemens Ladisch wrote: >> Felipe Tonello wrote: >>> I believe that is the best way to implement. Create multiple requests >>> until the ALSA substreams buffer are empty and free the request on >>> completion. >> >> I

RE: musb: communication issue with more than 12 FTDI ports

2015-10-12 Thread Konstantin Shkolnyy
Some host controllers just can't support so many pipes opened at once. Check what the SoC spec says about that. -Original Message- From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Yegor Yefremov Sent: Monday, October 12, 2015 05:35 To:

Re: [PATCH 18/23] spear13xx_pcie_gadget: use per-attribute show and store methods

2015-10-12 Thread Felipe Balbi
Christoph Hellwig writes: > On Fri, Oct 09, 2015 at 04:05:17PM -0500, Felipe Balbi wrote: >> Pratyush Anand writes: >> >> > On Sat, Oct 3, 2015 at 7:02 PM, Christoph Hellwig wrote: >> >> Signed-off-by: Christoph Hellwig >> > >>

Re: [PATCH] usb: musb: core: add common method of getting vbus status

2015-10-12 Thread Roman Alyautdin
On 12/10/15 16:59, Roman Alyautdin wrote: Fix musb_platform_get_vbus_status return value in case of platform implementation is not defined, bringing expected behaviour of musb_platform_get wrapper. Add musb_vbus_show default method to determine VBUS status in case platform method is not defined.

[PATCH] usb: musb: core: add common method of getting vbus status

2015-10-12 Thread Roman Alyautdin
Fix musb_platform_get_vbus_status return value in case of platform implementation is not defined, bringing expected behaviour of musb_platform_get wrapper. Add musb_vbus_show default method to determine VBUS status in case platform method is not defined. Signed-off-by: Roman Alyautdin

[PATCH] usb: musb: core: add common method of getting vbus status

2015-10-12 Thread Roman Alyautdin
Fix musb_platform_get_vbus_status return value in case of platform implementation is not defined, bringing expected behaviour of musb_platform_get wrapper. Add musb_vbus_show default method to determine VBUS status in case platform method is not defined. Signed-off-by: Roman Alyautdin

Re: [PATCH v4 1/5] gadget: Introduce the notifier functions

2015-10-12 Thread Mark Brown
On Fri, Oct 09, 2015 at 04:17:27PM -0500, Felipe Balbi wrote: > Mark, when can we try to have a discussion about how to get this > upstream ? It seems like designing everything in the mailing list will > just take forever. Any ideas ? Can we take this off-list? I'm in the UK, Baolin is in China

Re: [PATCH] ohci-pci: use USB_DT_*

2015-10-12 Thread Sergei Shtylyov
Hello. On 10/11/2015 12:43 AM, Sergei Shtylyov wrote: Toshiba Portege 4000 quirk entry can be written shorter using the PCI_DEVICE_SUB() macro. Signed-off-by: Sergei Shtylyov Oops, wrong subject. I'll resend. :-< MBR, Sergei -- To unsubscribe from

Re: [PATCH 14/20] target: Remove the write_pending_status() callback function

2015-10-12 Thread Felipe Balbi
Hi, Bart Van Assche writes: > Due to the previous patch the write_pending_status() callback > function is no longer called. Hence remove it. > > Signed-off-by: Bart Van Assche > Cc: Christoph Hellwig > Cc: Hannes Reinecke

Re: [PATCH 07/20] usb/gadget: Remove set-but-not-used variables

2015-10-12 Thread Felipe Balbi
Hi, Bart Van Assche writes: > Avoid that building with W=1 triggers compiler warnings about > set-but-not-used variables. > > Signed-off-by: Bart Van Assche > Cc: Felipe Balbi > Cc: Christoph Hellwig > Cc:

[PATCH] ohci-pci: use PCI_DEVICE_SUB()

2015-10-12 Thread Sergei Shtylyov
Toshiba Portege 4000 quirk entry can be written shorter using the PCI_DEVICE_SUB() macro. Signed-off-by: Sergei Shtylyov --- The patch is against the 'usb-next' branch of Greg KH's 'usb.git' repo. drivers/usb/host/ohci-pci.c |6 ++ 1 file changed,

Re: Crash in usb_f_mass_storage

2015-10-12 Thread Felipe Balbi
Hi, Paul Jones writes: > On 10 Oct 2015, at 16:32, Paul Jones wrote: > >> I came across the following kernel message on the latest 4.3-rc4 whilst >> performance testing on a USB3380 device connected to a Mac (10.9.5): >> >> [ 51.613838] WARNING: CPU:

[PATCH] Revert "usb: dwc3: gadget: remove unnecessary _irqsave()"

2015-10-12 Thread Felipe Balbi
This reverts commit 70f3a9caa11665e9f9aace581d85d8483716a4c8. That commit was causing a lockdep splat with g_ether and that was interfering with proper functionality. Signed-off-by: Felipe Balbi --- drivers/usb/dwc3/gadget.c | 5 +++-- 1 file changed, 3 insertions(+), 2

Re: [PATCH] Revert "usb: dwc3: gadget: drop unnecessary loop when cleaning up TRBs"

2015-10-12 Thread Felipe Balbi
Hi, Felipe Balbi writes: > On Wed, Sep 02, 2015 at 05:09:39PM +0900, Masakazu Mokuno wrote: >> Hi, >> >> On Mon, 31 Aug 2015 11:54:13 -0500 >> Felipe Balbi wrote: >> >> > On Mon, Aug 31, 2015 at 07:48:28PM +0300, ville.syrj...@linux.intel.com >> > wrote: >> > >

[PATCH 3/9] usb/host/fotg210: Remove useless else statement

2015-10-12 Thread Peter Senna Tschudin
This patch remove an else statement after a return to make the code easier to understand. Signed-off-by: Peter Senna Tschudin --- drivers/usb/host/fotg210-hcd.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/usb/host/fotg210-hcd.c

[PATCH 2/9] usb/host/fotg210: remove KERN_WARNING from pr_warn

2015-10-12 Thread Peter Senna Tschudin
This patch remove KERN_WARNING from a call to pr_warn(). Signed-off-by: Peter Senna Tschudin --- drivers/usb/host/fotg210-hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/host/fotg210-hcd.c b/drivers/usb/host/fotg210-hcd.c index

[PATCH 1/9] usb/host/fotg210: Fix coding style issues

2015-10-12 Thread Peter Senna Tschudin
This patch fix coding style issues reported by checkpatch that do not change semantics of the code. Signed-off-by: Peter Senna Tschudin --- This patch introduces one checkpatch warning for line over 80 characters, but my personal feeling is that it looks better and easier

[PATCH 7/9] usb/host/fotg210: convert macro to inline function

2015-10-12 Thread Peter Senna Tschudin
This patch convert the macro speed_char in an inline function. The goal of this patch is to make the code easier to read. Signed-off-by: Peter Senna Tschudin --- drivers/usb/host/fotg210-hcd.c | 27 --- 1 file changed, 16 insertions(+), 11

[PATCH 4/9] usb/host/fotg210: Remove NULL checks dma_pool_destroy

2015-10-12 Thread Peter Senna Tschudin
This patch remove NULL checks before calls to dma_pool_destroy() as the function now can handle NULL pointers. Signed-off-by: Peter Senna Tschudin --- drivers/usb/host/fotg210-hcd.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git

[PATCH 0/9] usb/host/fotg210: code style and warning fixes

2015-10-12 Thread Peter Senna Tschudin
This patch series fix warnings reported by checkpatch on the FOTG210 EHCI-like driver. Peter Senna Tschudin (9): usb/host/fotg210: Fix coding style issues usb/host/fotg210: remove KERN_WARNING from pr_warn usb/host/fotg210: Remove useless else statement usb/host/fotg210: Remove NULL

[PATCH 9/9] usb/host/fotg210: Add function scan_frame_queue()

2015-10-12 Thread Peter Senna Tschudin
checkpatch complains about too many leading tabs because the if statement starts after 6 tabs: scan_iosoc() -> for() -> while() -> switch() -> if() -> for() -> if() There is also a goto statement going backwards in case of failure. This patch creates a new inline function named

Re: [PATCH 3/9] usb/host/fotg210: Remove useless else statement

2015-10-12 Thread Joe Perches
On Mon, 2015-10-12 at 23:22 +0200, Peter Senna Tschudin wrote: > This patch remove an else statement after a return to make the code > easier to understand. [] > diff --git a/drivers/usb/host/fotg210-hcd.c b/drivers/usb/host/fotg210-hcd.c [] > @@ -1402,10 +1402,9 @@ static int

Re: [PATCH] usb: dwc2: fix duplicate argument warning

2015-10-12 Thread John Youn
On 10/12/2015 2:24 AM, Mian Yousaf Kaukab wrote: > Fix a duplicate argument warning reported by 0-DAY kernel test > infrastructure in the following patch: > 77dbf71 usb: dwc2: host: add disconnect interrupt to host only interrupts > > Signed-off-by: Mian Yousaf Kaukab >

Re: [PATCH v2] HID: hiddev: change hiddev_connect() to return bool

2015-10-12 Thread Krzysztof Kozlowski
2015-10-09 22:00 GMT+09:00 Luis de Bethencourt : > Since hid_connect() only cares about hiddev_connect() succeeding or > failing, there is no need for this function to return an int and it can > return a bool instead. It can return bool but it would not be in line with

[PATCH 8/9] usb/host/fotg210: Add function: output_buf_tds_dir()

2015-10-12 Thread Peter Senna Tschudin
checkpatch complains about too many leading tabs because the switch statement starts after 6 tabs. fill_periodic_buffer() -> for() -> do -> switch() -> if() -> list_for_each_entry() and finally the last switch(). This patch moves the list_for_each_entry() and the last switch() to a new function

[PATCH 6/9] usb/host/fotg210: replace msleep by usleep_range

2015-10-12 Thread Peter Senna Tschudin
msleep under 20ms can result in sleeping up to 20ms, which may not be intended. Replace msleep(5) by usleep_range(5000, 1). The range of 5 ms is to reduce the chances of creating an interrupt while reducing the maximum wait time in 50%. Signed-off-by: Peter Senna Tschudin

[PATCH 5/9] usb/host/fotg210: change kmalloc by kmalloc_array

2015-10-12 Thread Peter Senna Tschudin
This patch replaces: kmalloc(DBG_SCHED_LIMIT * sizeof(*seen), GFP_ATOMIC) by: kmalloc_array(DBG_SCHED_LIMIT, sizeof(*seen), GFP_ATOMIC) as kmalloc_array() should be used for allocating arrays. Signed-off-by: Peter Senna Tschudin --- drivers/usb/host/fotg210-hcd.c | 2