[PATCH] usb: gadget: fix NULL pointer dereference

2014-01-16 Thread Andrzej Pietrasiewicz
Fix possible NULL pointer dereference introduced in 219580e64f035bb9018dbb08d340f90b0ac50f8c usb: f_fs: check quirk to pad epout buf size when not aligned to maxpacketsize after 3.13-rc1. In cases we do wait with: wait_event_interruptible(epfile-wait, (ep = epfile-ep)); for endpoint to be

Re: [PATCH 1/2] usb: chipidea: usbmisc: Add support for i.MX27/i.MX31 CPUs

2014-01-16 Thread Uwe Kleine-König
in addition to the cs-gpio the ISP1504 (done) I see there are several new chipidea patches in next-20140116 compared to next-20140110 what I am using. Is there explicit support for a cs-gpios property? If so, it's not obvious. b) Implement UPLI viewport (IORESOURCE_MEM) and logic to set the external power

RE: xhci ASMedia lockups - a theory and a patch

2014-01-16 Thread David Laight
From: David Laight From: David Laight From: Alan Stern On Wed, 15 Jan 2014, David Laight wrote: I have a theory, I'll try to write a non-invasive patch. ... Doesn't this mean you shouldn't change the ownership of a LINK TRB until after you change the ownership of the TRB it

Re: [linux-sunxi] Re: [PATCH] ARM: sunxi: Add driver for sunxi usb phy

2014-01-16 Thread Hans de Goede
Hi, On 01/16/2014 08:07 AM, Chen-Yu Tsai wrote: Hi Hans, On Wed, Jan 15, 2014 at 11:48 PM, Hans de Goede hdego...@redhat.com wrote: Hi, On 01/15/2014 04:00 PM, Kishon Vijay Abraham I wrote: On Wednesday 15 January 2014 04:28 AM, Hans de Goede wrote: [...] +static int

RE: [PATCH 06/10] usb: chipidea: OTG fsm timers initialization.

2014-01-16 Thread b47...@freescale.com
-Original Message- From: Michael Grzeschik [mailto:m...@pengutronix.de] Sent: Friday, January 10, 2014 9:48 PM To: Li Jun-B47624 Cc: ba...@ti.com; Chen Peter-B29397; linux-usb@vger.kernel.org Subject: Re: [PATCH 06/10] usb: chipidea: OTG fsm timers initialization. Hi Li Jun, On Wed, Jan

Re: [Stlinux-devel] FW: [PATCH (linux-stm) 1/2] usb: dwc3: fix kernel compilation in gadget mode

2014-01-16 Thread Carmelo Amoroso
Dear Felipe, I'm one of the maintainer of the STLinux kernel @ST. Let me clarify the inconvenience occurred about this patches. We are back-porting some patches from upstream for DWC3 driver into our 3.4.58 based kernel as our chipsets use this host controller. The way we do it, is exactly

Re: [PATCH v3 00/10] Just the essential port power control fixes for 3.14

2014-01-16 Thread Alan Stern
On Wed, 15 Jan 2014, Dan Williams wrote: When the usb_device stays bound we do attempt recovery, fail, and properly trigger a disconnect of the device as expected. Question for Alan: I'm thinking we need a hub_port_logical_disconnect() when the usb_device becomes unbound. Otherwise the

Re: [PATCH] net: sk == 0xffffffff fix - not for commit

2014-01-16 Thread Eric Dumazet
On Thu, 2014-01-16 at 16:21 +0100, Andrzej Pietrasiewicz wrote: W dniu 10.12.2013 15:25, Eric Dumazet pisze: On Tue, 2013-12-10 at 07:55 +0100, Andrzej Pietrasiewicz wrote: W dniu 09.12.2013 16:31, Eric Dumazet pisze: On Mon, 2013-12-09 at 12:47 +0100, Andrzej Pietrasiewicz wrote: NOT FOR

Re: xhci-hcd (millions of) Too many fragments error on LUKS-encrypted device

2014-01-16 Thread Johannes Stezenbach
Hi Sascha, On Wed, Jan 15, 2014 at 08:27:58PM +0800, Sascha Weaver wrote: 2014/1/15 David Laight david.lai...@aculab.com: Edit drivers/usb/host/xhci.h and change the definition of TRBS_PER_SEGMENT from 64 to 256. Thanks David! I re-compiled my kernel after changing 64 to 256 and it

Re: [PATCH v3 03/10] usb: find internal hub tier mismatch via acpi

2014-01-16 Thread Sarah Sharp
On Wed, Jan 15, 2014 at 10:39:56AM -0500, Alan Stern wrote: On Tue, 14 Jan 2014, Sarah Sharp wrote: It's always possible for xhci-hcd to prevent the USB-2 root hub from being suspended by calling pm_runtime_get_noresume. The corresponding _put can be done after the USB-3 root hub

Re: [PATCH v3 06/10] usb: gate clearing FEAT_C_ENABLE to usb2 hubs

2014-01-16 Thread Sarah Sharp
On Tue, Jan 07, 2014 at 12:30:00PM -0800, Dan Williams wrote: The port pm_runtime implementation unconditionally clears FEAT_C_ENABLE after clearing PORT_POWER, but the bit is reserved on usb3 hub ports. It also takes steps to re-disable the port if it fails to reconnect which again is

Re: [PATCH 06/10] usb: chipidea: OTG fsm timers initialization.

2014-01-16 Thread David Cohen
Hi Li Jun, Hi Li Jun, On Wed, Jan 08, 2014 at 05:06:21PM +0800, Li Jun wrote: This patch adds OTG fsm timers initialization, which use controller's 1ms interrupt as time out counter, also adds some local timers which are not in otg_fsm_timer list. Signed-off-by: Li Jun

Re: EHCI host broken -- interrupts disabled

2014-01-16 Thread Bjorn Helgaas
[+cc linux-pci] On Tue, Jan 14, 2014 at 11:47 AM, Alan Stern st...@rowland.harvard.edu wrote: On Tue, 14 Jan 2014, Sarah Sharp wrote: Hi Alan, I'm not a good person to ask about this. Maybe Bjorn can help. All this info is second- or third-hand, so please excuse the extremely vague bug

Re: [BUG] FL1009: xHCI host not responding to stop endpoint command.

2014-01-16 Thread Sarah Sharp
On Wed, Jan 15, 2014 at 08:04:45PM +0100, Arnaud Ebalard wrote: Hi David, David Laight david.lai...@aculab.com writes: I tried current 3.13.0-rc8 w/ 35773dac5f86 reverted and the result is the same: That patch only affects an error code and stops the fs code retrying for ever.

Re: [PATCH v3 06/10] usb: gate clearing FEAT_C_ENABLE to usb2 hubs

2014-01-16 Thread Dan Williams
On Thu, Jan 16, 2014 at 8:35 AM, Sarah Sharp sarah.a.sh...@linux.intel.com wrote: On Tue, Jan 07, 2014 at 12:30:00PM -0800, Dan Williams wrote: The port pm_runtime implementation unconditionally clears FEAT_C_ENABLE after clearing PORT_POWER, but the bit is reserved on usb3 hub ports. It also

Re: XHCI issues: WD MyBook 1230 - reset SuperSpeed USB device

2014-01-16 Thread Peter Palúch
Alan, I am attaching the usbmon trace after the drive has been plugged into the USB-2 port. Record of the drive in stall should occur around the file offset 87808 (decimal). The log was done on the 3.12.7 kernel without CONFIG_PM. Should I do a usbmon trace on my regular kernel with

Re: [PATCH] xhci: make warnings greppable

2014-01-16 Thread Sarah Sharp
On Fri, Jan 10, 2014 at 01:36:17AM +0300, Sergei Shtylyov wrote: Hello. On 01/08/2014 07:13 PM, oli...@neukum.org wrote: From: Oliver Neukum oneu...@suse.de This changes debug messages and warnings in xhci-ring.c to be on a single line so grep can find them. grep must have precedence

Re: [PATCH 3.12 033/118] usb: xhci: Link TRB must not occur within a USB payload burst [NEW HARDWARE]

2014-01-16 Thread Sarah Sharp
On Tue, Jan 14, 2014 at 01:27:25PM -0800, walt wrote: On 01/14/2014 09:20 AM, Sarah Sharp wrote: On Mon, Jan 13, 2014 at 03:39:07PM -0800, walt wrote: Sarah, I just fixed my xhci bug for US$19.99 :) #lspci | tail -1 04:00.0 USB controller: NEC Corporation uPD720200 USB 3.0 Host

Re: XHCI issues: WD MyBook 1230 - reset SuperSpeed USB device

2014-01-16 Thread Alan Stern
It's now clear that this is _not_ an XHCI issue, contrary to what $SUBJECT says. On Thu, 16 Jan 2014, Peter Palúch wrote: Alan, I am attaching the usbmon trace after the drive has been plugged into the USB-2 port. Record of the drive in stall should occur around the file offset 87808

Re: [PATCH v3 03/10] usb: find internal hub tier mismatch via acpi

2014-01-16 Thread Alan Stern
On Thu, 16 Jan 2014, Sarah Sharp wrote: What do you think about the rest of the patchset? I regret that I haven't taken the time to look through it yet. :-( I'll do my best to go through it soon. No worries! I'm most interested in your comments about the changes to khubd, so if

Re: [PATCH] net: sk == 0xffffffff fix - not for commit

2014-01-16 Thread Andrew Ruder
On Mon, Dec 09, 2013 at 12:47:52PM +0100, Andrzej Pietrasiewicz wrote: With g_ether loaded the sk occasionally becomes 0x. It happens usually after transferring few hundreds of kilobytes to few tens of megabytes. If sk is 0x then dereferencing it causes kernel panic. Don't

Re: [PATCH v3 03/10] usb: find internal hub tier mismatch via acpi

2014-01-16 Thread Dan Williams
On Thu, 2014-01-16 at 16:18 -0500, Alan Stern wrote: On Thu, 16 Jan 2014, Sarah Sharp wrote: What do you think about the rest of the patchset? I regret that I haven't taken the time to look through it yet. :-( I'll do my best to go through it soon. No worries! I'm most

Re: [Stlinux-devel] FW: [PATCH (linux-stm) 1/2] usb: dwc3: fix kernel compilation in gadget mode

2014-01-16 Thread Felipe Balbi
Hi, On Thu, Jan 16, 2014 at 01:58:30PM +0100, Carmelo Amoroso wrote: I'm one of the maintainer of the STLinux kernel @ST. Let me clarify the inconvenience occurred about this patches. We are back-porting some patches from upstream for DWC3 driver into our 3.4.58 based kernel as our chipsets

[PATCH 1/2] USB: at91: fix the number of endpoint parameter

2014-01-16 Thread Bo Shen
In sama5d3 SoC, there are 16 endpoints. As the USBA_NR_ENDPOINTS is only 7. So, fix it for sama5d3 SoC using the udc-num_ep. Signed-off-by: Bo Shen voice.s...@atmel.com --- drivers/usb/gadget/atmel_usba_udc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 2/2] USB: at91: using USBA_NR_DMAS for DMA channels

2014-01-16 Thread Bo Shen
When the SoC is earlier than sama5d3 SoC, which have the same number endpoints and DMAs. However for sama5d3 SoC, it has different number for endpoints and DMAs. So, define USBA_NR_DMAs for DMA channels Signed-off-by: Bo Shen voice.s...@atmel.com --- drivers/usb/gadget/atmel_usba_udc.c | 2 +-

Re: [BUG] FL1009: xHCI host not responding to stop endpoint command.

2014-01-16 Thread Arnaud Ebalard
Hi, Sarah Sharp sarah.a.sh...@linux.intel.com writes: ... AFAICT, this is exactly what commit 35773dac5f86 does and reverting it does not help. If I am mistaken, can you point which part you want me to remove in the code to test? I am slowly starting to see a bisect session coming ;-)

Re: [PATCH v7 0/2] ohci and ehci-platform clks, phy and dt support

2014-01-16 Thread Florian Fainelli
Le mercredi 15 janvier 2014, 15:26:21 Alan Stern a écrit : On Wed, 15 Jan 2014, Hans de Goede wrote: Hi All, This version of my ohci and ehci-platform clks, phy and dt support patch-set, really fixes the 2 small bugs Alan found. All okay -- this time I can't find anything to complain

[PATCH v2 0/3] usb: gadget: f_fs: add asynchronous I/O support

2014-01-16 Thread Robert Baldyga
Hello, This is second version of patches containing improvements for FunctionFS which allows to use it with asynchronous I/O interface. It also adds poll function for ep0, to make it usable without creating additional thread, needed by blocking I/O. From last version I have made modifications

[PATCH v2 3/3] usb: gadget: f_fs: add aio support

2014-01-16 Thread Robert Baldyga
This patch adds asynchronous I/O support for FunctionFS endpoint files. It adds ffs_epfile_aio_write() and ffs_epfile_aio_read() functions responsible for preparing AIO operations. It also modifies ffs_epfile_io() function, adding aio handling code. Instead of extending list of parameters of this

[PATCH v2 2/3] usb: gadget: f_fs: add poll for endpoint 0

2014-01-16 Thread Robert Baldyga
This patch adds poll function for file representing ep0. Ability of read from or write to ep0 file is related with actual state of ffs: - When desctiptors or strings are not written yet, POLLOUT flag is set. - If there is any event to read, POLLIN flag is set. - If setup request was read, POLLIN

[PATCH v2 1/3] usb: gadget: f_fs: fix setup request handling

2014-01-16 Thread Robert Baldyga
This patch fixes __ffs_ep0_queue_wait() function, which now returns number of bytes transferred in USB request or error code in case of failure. This is needed by ffs_ep0_read() function, when read data is copied to userspace. It also cleans up code by removing usused variable ep0req_status.

Re: XHCI issues: WD MyBook 1230 - reset SuperSpeed USB device

2014-01-16 Thread Hannes Reinecke
On 01/16/2014 09:48 PM, Alan Stern wrote: It's now clear that this is _not_ an XHCI issue, contrary to what $SUBJECT says. On Thu, 16 Jan 2014, Peter Palúch wrote: Alan, I am attaching the usbmon trace after the drive has been plugged into the USB-2 port. Record of the drive in stall