Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread victor yeo
Hi, >> > you should an interrupt handler to handle interrupts from your device. >> > Also, there are way too many mistakes on your driver, run checkpatch.pl, >> > compile it with sparse, don't hardcode addresses, don't reimplement a >> > bunch of infrastructure the kernel already gives you and ch

Re: USB subsystem stops working

2013-01-24 Thread Ming Lei
On Thu, Jan 24, 2013 at 2:19 PM, Peter Chen wrote: > > My puzzle is after calling usb_autopm_get_interface_no_resume() at kick_khubd > the dev->power.usage_count is 1, when the hub's suspend will be called? usb_autopm_put_interface() will decrease the counter and trigger auto-suspend, then hub_su

Re: [PATCH v9 00/20] OMAP USB Host cleanup

2013-01-24 Thread Roger Quadros
On 01/23/2013 05:26 PM, Alan Stern wrote: > On Wed, 23 Jan 2013, Roger Quadros wrote: > >> Hi Samuel, >> >> I think this series is in a pretty good shape to pull now :). I've added >> Reviewed-by and Acked-by tags. You can please pull from below. >> >> NOTE: the first patch is a stable fix so Greg

Re: [PATCH v9 20/20] mdf: omap-usb-host: get rid of build warning

2013-01-24 Thread Roger Quadros
On 01/24/2013 01:36 AM, Mike Turquette wrote: > Quoting Roger Quadros (2013-01-23 02:38:12) >> Fixes the below build warning when driver is built-in. >> >> drivers/mfd/omap-usb-host.c:750:12: warning: >> ‘usbhs_omap_remove’ defined but not used [-Wunused-function] >> >> Signed-off-by: Roger Quadros

[PATCH 1/8] usb: gadget: adm5536udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/amd5536udc.c | 59 ++--- drivers/usb/gadget/amd5536udc.h | 2 ++ 2 files changed, 16 insertions(+),

[PATCH 2/8] usb: gadget: fusb300_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fusb300_udc.c | 65 +++- drivers/usb/gadget/fusb300_udc.h | 2 ++ 2 files changed, 20 insertions(+),

[PATCH 3/8] usb: gadget: goku_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/goku_udc.c | 70 +-- drivers/usb/gadget/goku_udc.h | 1 + 2 files changed, 15 insertions(+), 56

[PATCH 4/8] usb: gadget: fsl_udc_core: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fsl_udc_core.c | 58 --- 1 file changed, 11 insertions(+), 47 deletions(-) diff --git a/drivers/usb/

[PATCH 5/8] usb: gadget: m66592-udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/m66592-udc.c | 70 +++-- drivers/usb/gadget/m66592-udc.h | 1 + 2 files changed, 20 insertions(+), 5

[PATCH 7/8] usb: gadget: pch_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/pch_udc.c | 67 +--- 1 file changed, 14 insertions(+), 53 deletions(-) diff --git a/drivers/usb/

[PATCH 8/8] usb: gadget: completely remove ->start/->stop

2013-01-24 Thread Felipe Balbi
Those have been deprecated for a long time and previous patches just converted all remaining users of those. Since there are no in-tree users and we don't want any new users for them, let's obliterate every piece of code related to those calls. Signed-off-by: Felipe Balbi --- drivers/usb/gadget

[PATCH 6/8] usb: gadget: omap_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/omap_udc.c | 49 +++ 1 file changed, 12 insertions(+), 37 deletions(-) diff --git a/drivers/usb/

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread Felipe Balbi
Hi, On Thu, Jan 24, 2013 at 04:25:24PM +0800, victor yeo wrote: > Hi, > > >> > you should an interrupt handler to handle interrupts from your device. > >> > Also, there are way too many mistakes on your driver, run checkpatch.pl, > >> > compile it with sparse, don't hardcode addresses, don't reim

[PATCH v10 20/20] mfd: omap-usb-host: get rid of build warning

2013-01-24 Thread Roger Quadros
Fixes the below build warning when driver is built-in. drivers/mfd/omap-usb-host.c:750:12: warning: ‘usbhs_omap_remove’ defined but not used [-Wunused-function] Signed-off-by: Roger Quadros Reviewed-by: Felipe Balbi --- drivers/mfd/omap-usb-host.c |2 +- 1 files changed, 1 insertions(+), 1

Re: [V5 PATCH 07/26] usb: gadget: mv_udc: make mv_udc depends on ARCH_MMP or ARCH_PXA

2013-01-24 Thread Felipe Balbi
Hi, On Thu, Jan 24, 2013 at 01:38:31AM -0500, Chao Xie wrote: > Only ARCH_PXA and ARCH_MMP will use mv_udc. > > Signed-off-by: Chao Xie NAK, you should fix your transceiver dependency. I want these gadget drivers to compile cleanly on all arches so we make proper use of linux-next. I have appli

Re: Need review for chipidea driver

2013-01-24 Thread Alexander Shishkin
On 24 January 2013 05:15, Chen Peter-B29397 wrote: > Sorry, forget to cc the list > >> >> Hi Greg, >> >> Alex has no response for chipidea driver review for long time >> (more than 1 month), below are some links about patchset. >> Does anyone else can help do it? Sorry for that. Looking into it a

Re: [PATCH v4 0/6] support other fsl SoCs with usbmisc + small fixes

2013-01-24 Thread Alexander Shishkin
Peter Chen writes: > On Tue, Nov 27, 2012 at 05:16:55PM +0100, Michael Grzeschik wrote: >> Nearly every SoC from Freescale has this non-core usb registers. This series >> adds support for more users of this driver. >> >> This series is based on Peter Chen's work. Its needed to merge his master

[PATCH] usb: dwc3: gadget: change HIRD threshold to 12

2013-01-24 Thread Felipe Balbi
First of all, that 28 value makes no sense as HIRD threshold is a 4-bit value, second of all it's causing issues for OMAP5. Using 12 because commit cbc725b3 (usb: dwc3: keep default hird threshold value as 4b1100) had the intention of setting the maximum allowed value of 0xc. Also, original code

[RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Michael Grzeschik
The current implementation of the composite framework connects the gadget function to the device-controller at kernel boottime. It's possible that the userspace application, which handles the enumeration requests of the gadget, starts with high latency when the host did already gave up to detect t

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread victor yeo
Hi, >> >> > Also, you shouldn't requeue the request yourself, gadget driver owns the >> >> > request. >> >> which request do i requeue? please kindly point that out. Thanks! >> > >> > look at your code. Look what you do after you call complete. >> >> is it this code? i will remove the redundant co

[PATCH v2] usb: host: tegra: make use of PHY pointer of HCD

2013-01-24 Thread Venu Byravarasu
As pointer to PHY structure can be stored in struct usb_hcd making use of it, to call Tegra PHY APIs. Call to usb_phy_shutdown() is moved up in tegra_ehci_remove(), so that to avoid dereferencing of hcd after its freed up. Signed-off-by: Venu Byravarasu --- First version of patch can be found at

[RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
A device sending 0 length frames as fast as it can has been observed killing the host system due to the resulting memory pressure. We handle the done queue as fast as we can, so if this queue is filling up then that is an indication that we are under too heavy pressure. Refusing further allocation

[PATCHv1 0/9] usb: chipidea: clean up debuggery

2013-01-24 Thread Alexander Shishkin
This patchset cleans up the remaining debugging bits in the driver by either conventing them to trace points or moving to debugfs, all the while getting rid of home-grown tracing facilities. Trace events are accessible through perf tool. If you don't yet have it in your testing environment, now is

[PATCH 1/9] usb: chipidea: drop redundant includes

2013-01-24 Thread Alexander Shishkin
debug.c is carrying a lot of includes that aren't needed there, drop them. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/debug.c | 17 +++-- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/drivers/usb/chipidea/debug.c b/drivers/usb/chipidea/debug.c index

[PATCH 2/9] usb: chipidea: trim include list in udc code

2013-01-24 Thread Alexander Shishkin
Some headers included in udc core code are not actually needed, remove them. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/udc.c |8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c index 2f45bba..aea09

[PATCH 4/9] usb: chipidea: convert events to tracepoints

2013-01-24 Thread Alexander Shishkin
As part of the legacy from the original driver design, we retain home-grown tracing infrastructure, complete with own ring buffer and timestamps. While it is useful for debugging certain cases, it's a lot of extra code, which these days is rather redundant. This patch replaces local tracing functi

[PATCH 3/9] usb: chipidea: trim include list in the core

2013-01-24 Thread Alexander Shishkin
Some headers included in the chipidea controller core are not needed, remove them. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/core.c |3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c index 57cae1f..77963b6 100644 --

[PATCH 5/9] usb: chipidea: replace interrupt accounting with tracepoints

2013-01-24 Thread Alexander Shishkin
The driver also has interrupt counters and another ring buffer for keeping track of the order in which they arrive. This patch converts these counters to trace points. Userspace tools such as perf can provide information on both order and stats of the interrupts. Signed-off-by: Alexander Shishkin

[PATCH 7/9] usb: chipidea: move role to debugfs

2013-01-24 Thread Alexander Shishkin
Manual role switching function is there for debugging purposes, so has to move to debugfs. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/core.c | 39 -- drivers/usb/chipidea/debug.c | 54 ++ 2 files changed, 54

[PATCH 8/9] usb: chipidea: move debug files creation/removal to the core

2013-01-24 Thread Alexander Shishkin
Create and remove debugfs entries in hdrc probe/remove instead of start/stop of the device controller. Gadget specific will not export anything while the controller is in host mode. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/core.c |6 +- drivers/usb/chipidea/udc.c |

[PATCH 6/9] usb: chipidea: convert debug entries in sysfs to debugfs

2013-01-24 Thread Alexander Shishkin
Currently, we have a bunch of files in sysfs that display all sorts of debugging information for the device controller, so they have to move to debugfs where they belong. The "registers" interface have been removed, since it doesn't fit into the current driver design as is and it's hardly a good id

[PATCH 9/9] usb: chipidea: fix precedence bug in ci_requests_show()

2013-01-24 Thread Alexander Shishkin
From: Dan Carpenter The intent here was to have parenthesis around the (ci->hw_ep_max / 2) so that it counts like "0 1 2 0 1 2". In the current code, the mod operation happens first so it counts like "0 0 1 1 2 2". Signed-off-by: Dan Carpenter [rebased on top of debug.c changes] Signed-off-by:

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread Felipe Balbi
Hi, On Thu, Jan 24, 2013 at 06:23:08PM +0800, victor yeo wrote: > Hi, > > >> >> > Also, you shouldn't requeue the request yourself, gadget driver owns > >> >> > the > >> >> > request. > >> >> which request do i requeue? please kindly point that out. Thanks! > >> > > >> > look at your code. Look

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Oliver Neukum
On Thursday 24 January 2013 11:25:52 Bjørn Mork wrote: > The MBIM firmware for the Sierra Wireless MC7710 is a nice source > of "interesting" device issues. One of the uglier ones is that > it under certain conditions will start flooding us with frames > having length 0 as fast as it can. And tha

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
Bjørn Mork writes: > A device sending 0 length frames as fast as it can has been > observed killing the host system due to the resulting memory > pressure. We handle the done queue as fast as we can, so > if this queue is filling up then that is an indication that we > are under too heavy pressur

Re: [V5 PATCH 24/26] usb: gadget: mv_udc: add device tree support

2013-01-24 Thread Mark Rutland
Hello, On Thu, Jan 24, 2013 at 06:38:48AM +, Chao Xie wrote: > In original driver, we have callbacks in platform data, and some > dynamically allocations variables in platform data. > Now, these blocks are removed, the device tree support is easier > now. Please could you also add a binding d

Re: [patch v2] usb: gadget: precedence bug in show_requests()

2013-01-24 Thread Alexander Shishkin
Dan Carpenter writes: > The intent here was to have parenthesis around the (ci->hw_ep_max / 2) > so that it counts like "0 1 2 0 1 2". In the current code, the mod > operation happens first so it counts like "0 0 1 1 2 2". > > Signed-off-by: Dan Carpenter Thanks, I added this one on top of my

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
Oliver Neukum writes: > On Thursday 24 January 2013 11:25:52 Bjørn Mork wrote: >> The MBIM firmware for the Sierra Wireless MC7710 is a nice source >> of "interesting" device issues. One of the uglier ones is that >> it under certain conditions will start flooding us with frames >> having length

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Laurent Pinchart
Hi Michael, On Thursday 24 January 2013 11:22:02 Michael Grzeschik wrote: > The current implementation of the composite framework connects the > gadget function to the device-controller at kernel boottime. > > It's possible that the userspace application, which handles the > enumeration requests

Re: [V5 PATCH 25/26] usb: otg: mv_otg: add device tree support

2013-01-24 Thread Mark Rutland
On Thu, Jan 24, 2013 at 06:38:49AM +, Chao Xie wrote: > All blocks are removed. Add the device tree support for otg. As with mv_udc, this binding should be documented. Please Cc devicetree-discuss when you have one. > > Signed-off-by: Chao Xie > --- > drivers/usb/otg/mv_otg.c | 128 ++

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Oliver Neukum
On Thursday 24 January 2013 11:52:22 Bjørn Mork wrote: > Oliver Neukum writes: > > > On Thursday 24 January 2013 11:25:52 Bjørn Mork wrote: > >> The MBIM firmware for the Sierra Wireless MC7710 is a nice source > >> of "interesting" device issues. One of the uglier ones is that > >> it under cer

Re: [V5 PATCH 26/26] usb: ehci: ehci-mv: add device tree support

2013-01-24 Thread Mark Rutland
On Thu, Jan 24, 2013 at 06:38:50AM +, Chao Xie wrote: > All blocks are removed. Add the device tree support for ehci. Similarly to the last two patches, could you please add a binding document? > Signed-off-by: Chao Xie > Acked-by: Alan Stern > --- > drivers/usb/host/ehci-mv.c | 105 +

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
Oliver Neukum writes: > On Thursday 24 January 2013 11:52:22 Bjørn Mork wrote: >> Oliver Neukum writes: >> >> > On Thursday 24 January 2013 11:25:52 Bjørn Mork wrote: >> >> The MBIM firmware for the Sierra Wireless MC7710 is a nice source >> >> of "interesting" device issues. One of the uglier

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Oliver Neukum
On Thursday 24 January 2013 12:22:54 Bjørn Mork wrote: > Oliver Neukum writes: > > > On Thursday 24 January 2013 11:52:22 Bjørn Mork wrote: > >> Oliver Neukum writes: > >> > >> > On Thursday 24 January 2013 11:25:52 Bjørn Mork wrote: > >> >> The MBIM firmware for the Sierra Wireless MC7710 is a

RE: [PATCH v1 0/6] USB: Add support for multiple PHYs of same type

2013-01-24 Thread Mohammed, Afzal
Hi Kishon, On Wed, Jan 23, 2013 at 19:56:37, ABRAHAM, KISHON VIJAY wrote: > On Wednesday 23 January 2013 07:28 PM, Mohammed, Afzal wrote: > > USB first instance of am335x works in mainline as of now. > Can you check if this series indeed breaks am335x? > > Thanks for your help. Do you have a t

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread victor yeo
Hi, >> >> is it this code? i will remove the redundant code after complete. >> >> >> >> ka_ep_p->req.complete(&ka_ep_p->ep, &req->req); >> >> if (num == 0) { >> >> ka_ep_p->req.length = 0; >> >> usb_ep_queue(&ka_ep_p->ep, &req->req, 0); >> >>

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread Felipe Balbi
Hi, On Thu, Jan 24, 2013 at 08:14:25PM +0800, victor yeo wrote: > Hi, > > >> >> is it this code? i will remove the redundant code after complete. > >> >> > >> >> ka_ep_p->req.complete(&ka_ep_p->ep, &req->req); > >> >> if (num == 0) { > >> >> ka_ep_p->req.length = 0

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Sergei Shtylyov
Hello. On 24-01-2013 14:25, Bjørn Mork wrote: A device sending 0 length frames as fast as it can has been observed killing the host system due to the resulting memory pressure. We handle the done queue as fast as we can, so if this queue is filling up then that is an indication that we are unde

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread victor yeo
Hi, >> i do not see where req->length is checked in gadget >> driver. > > It isn't _checked_; it is _set_ in set_bulk_out_req_length(). > req->actual is checked in received_cbw(). > >> g_file_storage gadget: ep0-setup, length 8: >> : 00 09 01 00 00 00 00 00 >> g_file_storage gadget: set co

Re: [PATCH 1/9] usb: chipidea: drop redundant includes

2013-01-24 Thread Sergei Shtylyov
Hello. On 24-01-2013 14:46, Alexander Shishkin wrote: debug.c is carrying a lot of includes that aren't needed there, drop them. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/debug.c | 17 +++-- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/dri

Re: [PATCH 2/9] usb: chipidea: trim include list in udc code

2013-01-24 Thread Sergei Shtylyov
On 24-01-2013 14:46, Alexander Shishkin wrote: Some headers included in udc core code are not actually needed, remove them. Signed-off-by: Alexander Shishkin --- drivers/usb/chipidea/udc.c |8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/usb/chipidea

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
Oliver Neukum writes: > On Thursday 24 January 2013 12:22:54 Bjørn Mork wrote: > >> Sorry for being daft, but how do I code the "20 among the last 30" part >> there? > > Just by agreeing that you can live with false negatives but not false > positives > > if (++counter > 30) { > counter = b

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Joe Perches
On Thu, 2013-01-24 at 16:39 +0400, Sergei Shtylyov wrote: > On 24-01-2013 14:25, Bjørn Mork wrote: > > A device sending 0 length frames as fast as it can has been > > observed killing the host system due to the resulting memory > > pressure. [] > > diff --git a/drivers/net/usb/usbnet.c b/drivers/ne

Re: [PATCH 1/9] usb: chipidea: drop redundant includes

2013-01-24 Thread Alexander Shishkin
Sergei Shtylyov writes: >But you also add some #include's, and don't document this in the changelog. Nice catch, thanks! Regards, -- Alex -- 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 htt

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Oliver Neukum
On Thursday 24 January 2013 13:47:40 Bjørn Mork wrote: > Oliver Neukum writes: > > On Thursday 24 January 2013 12:22:54 Bjørn Mork wrote: > > > >> Sorry for being daft, but how do I code the "20 among the last 30" part > >> there? > > > > Just by agreeing that you can live with false negatives but

[PATCH v2 0/2] usb: exynos: Fix compatible strings used for device

2013-01-24 Thread Vivek Gautam
Using chip specific compatible string as it should be. So fixing this for ehci-s5p, ohci-exynos and dwc3-exynos which till now used a generic 'exynos' in their compatible strings. Changes from v1: - Changing compatible string from "samsung,exynos5250-dwc3" to "samsung,exynos5250-

[PATCH v2 1/2] usb: ehci-s5p/ohci-exynos: Fix compatible strings for the device

2013-01-24 Thread Vivek Gautam
Using specific chip in compatible strings. Newer SOCs can claim device by using older string in the compatible list. Signed-off-by: Vivek Gautam Acked-by: Grant Likely Reviewed-by: Doug Anderson --- drivers/usb/host/ehci-s5p.c|2 +- drivers/usb/host/ohci-exynos.c |2 +- 2 files cha

[PATCH v2 2/2] usb: dwc3-exynos: Fix compatible strings for the device

2013-01-24 Thread Vivek Gautam
Using specific chip in compatible strings. Newer SOCs can claim device by using older string in the compatible list. Signed-off-by: Vivek Gautam Acked-by: Grant Likely Reviewed-by: Doug Anderson --- drivers/usb/dwc3/dwc3-exynos.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) dif

Re: [RFC] net: usbnet: prevent buggy devices from killing us

2013-01-24 Thread Bjørn Mork
Oliver Neukum writes: > On Thursday 24 January 2013 13:47:40 Bjørn Mork wrote: >> Oliver Neukum writes: >> > On Thursday 24 January 2013 12:22:54 Bjørn Mork wrote: >> > >> >> Sorry for being daft, but how do I code the "20 among the last 30" part >> >> there? >> > >> > Just by agreeing that you

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Michael Grzeschik
On Thu, Jan 24, 2013 at 12:02:12PM +0100, Laurent Pinchart wrote: > Hi Michael, > > On Thursday 24 January 2013 11:22:02 Michael Grzeschik wrote: > > The current implementation of the composite framework connects the > > gadget function to the device-controller at kernel boottime. > > > > It's po

Re: usb device removed from sysfs before input children devices

2013-01-24 Thread Karl Relton
On Tue, 2013-01-15 at 20:27 +, Karl Relton wrote: > > The end result (for the user) is that even when the bluetooth > > mouse/keyboard is re-added, Xorg ignores it - thinking it is some > hoax > > duplicate device. The keyboard/mouse is then non-operational. > > > > Instrumenting the code sug

Re: [PATCH v2 0/2] usb: exynos: Fix compatible strings used for device

2013-01-24 Thread Vivek Gautam
On Thu, Jan 24, 2013 at 7:15 PM, Vivek Gautam wrote: > Using chip specific compatible string as it should be. > So fixing this for ehci-s5p, ohci-exynos and dwc3-exynos > which till now used a generic 'exynos' in their compatible strings. > > Changes from v1: > - Changing compatible string

Re: [PATCH v2] usb: host: tegra: make use of PHY pointer of HCD

2013-01-24 Thread Felipe Balbi
Hi, On Thu, Jan 24, 2013 at 03:57:03PM +0530, Venu Byravarasu wrote: > As pointer to PHY structure can be stored in struct usb_hcd > making use of it, to call Tegra PHY APIs. > > Call to usb_phy_shutdown() is moved up in tegra_ehci_remove(), > so that to avoid dereferencing of hcd after its freed

Re: [RESEND PATCH v5 3/7] usb: chipidea: add otg id switch and vbus connect/disconnect detect

2013-01-24 Thread Alexander Shishkin
Peter Chen writes: > The main design flow is the same with msm otg driver, that is the id and > vbus interrupt are handled at core driver, others are handled by > individual drivers. > > - At former design, when switch usb role from device->host, it will call > udc_stop, it will remove the gadget

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Laurent Pinchart
Hi Michael, On Thursday 24 January 2013 14:54:01 Michael Grzeschik wrote: > On Thu, Jan 24, 2013 at 12:02:12PM +0100, Laurent Pinchart wrote: > > On Thursday 24 January 2013 11:22:02 Michael Grzeschik wrote: > > > The current implementation of the composite framework connects the > > > gadget func

Re: [RESEND PATCH v5 4/7] usb: chipidea: consolidate ci_role_driver's API for both roles

2013-01-24 Thread Alexander Shishkin
Peter Chen writes: > - Create init/destroy API for probe and remove > - start/stop API are only used otg id switch process > - Create the gadget at ci_hdrc_probe if the gadget is supported > at that port, the main purpose for this is to avoid gadget module > load fail at init.rc I don't think it

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Michael Grzeschik
On Thu, Jan 24, 2013 at 03:21:37PM +0100, Laurent Pinchart wrote: > Hi Michael, > > On Thursday 24 January 2013 14:54:01 Michael Grzeschik wrote: > > On Thu, Jan 24, 2013 at 12:02:12PM +0100, Laurent Pinchart wrote: > > > On Thursday 24 January 2013 11:22:02 Michael Grzeschik wrote: > > > > The cu

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Felipe Balbi
On Thu, Jan 24, 2013 at 03:35:58PM +0100, Michael Grzeschik wrote: > On Thu, Jan 24, 2013 at 03:21:37PM +0100, Laurent Pinchart wrote: > > Hi Michael, > > > > On Thursday 24 January 2013 14:54:01 Michael Grzeschik wrote: > > > On Thu, Jan 24, 2013 at 12:02:12PM +0100, Laurent Pinchart wrote: > > >

Re: [PATCH] usb: Prevent dead ports when xhci is not enabled

2013-01-24 Thread Greg KH
On Wed, Jan 23, 2013 at 10:19:49PM -0800, David Moore wrote: > From: David Moore > > When the xHCI driver is not available, actively switch the ports to EHCI > mode since some BIOSes leave them in xHCI mode where they would > otherwise appear dead. > > Signed-off-by: David Moore > --- > driver

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Laurent Pinchart
Hi Felipe, On Thursday 24 January 2013 16:42:50 Felipe Balbi wrote: > On Thu, Jan 24, 2013 at 03:35:58PM +0100, Michael Grzeschik wrote: > > On Thu, Jan 24, 2013 at 03:21:37PM +0100, Laurent Pinchart wrote: > > > On Thursday 24 January 2013 14:54:01 Michael Grzeschik wrote: > > > > On Thu, Jan 24,

Re: [PATCH 2/2 v2] drivers/usb/host/uhci-*: beautify source code

2013-01-24 Thread Alan Stern
On Thu, 24 Jan 2013, Chen Gang wrote: > get rid of the line breaks in string constants. > let comments within 80 with limitation. > delete ' \' at the end of a statement. > > Signed-off-by: Chen Gang Acked-by: Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux

Re: [PATCH 1/8] usb: gadget: adm5536udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
HI, On Thu, Jan 24, 2013 at 11:01:24AM +0200, Felipe Balbi wrote: > Mechanical change making use of the new (can we > still call it new ?) interface for registering > UDC drivers. > > Signed-off-by: Felipe Balbi I'll resend this series, my grep missed pxa folks. -- balbi signature.asc Descr

Re: [RESEND PATCH v5 3/7] usb: chipidea: add otg id switch and vbus connect/disconnect detect

2013-01-24 Thread Alexander Shishkin
Peter Chen writes: > The main design flow is the same with msm otg driver, that is the id and > vbus interrupt are handled at core driver, others are handled by > individual drivers. > > - At former design, when switch usb role from device->host, it will call > udc_stop, it will remove the gadget

[PATCH 01/11] usb: gadget: adm5536udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/amd5536udc.c | 59 ++--- drivers/usb/gadget/amd5536udc.h | 2 ++ 2 files changed, 16 insertions(+),

[PATCH 02/11] usb: gadget: fusb300_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fusb300_udc.c | 65 +++- drivers/usb/gadget/fusb300_udc.h | 2 ++ 2 files changed, 20 insertions(+),

[PATCH 03/11] usb: gadget: goku_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/goku_udc.c | 70 +-- drivers/usb/gadget/goku_udc.h | 1 + 2 files changed, 15 insertions(+), 56

[PATCH 04/11] usb: gadget: fsl_udc_core: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fsl_udc_core.c | 58 --- 1 file changed, 11 insertions(+), 47 deletions(-) diff --git a/drivers/usb/

[PATCH 05/11] usb: gadget: m66592-udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/m66592-udc.c | 70 +++-- drivers/usb/gadget/m66592-udc.h | 1 + 2 files changed, 20 insertions(+), 5

[PATCH 06/11] usb: gadget: omap_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/omap_udc.c | 49 +++ 1 file changed, 12 insertions(+), 37 deletions(-) diff --git a/drivers/usb/

[PATCH 07/11] usb: gadget: pch_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/pch_udc.c | 67 +--- 1 file changed, 14 insertions(+), 53 deletions(-) diff --git a/drivers/usb/

[PATCH 08/11] usb: gadget: pxa25x_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/pxa25x_udc.c | 62 ++--- drivers/usb/gadget/pxa25x_udc.h | 1 + 2 files changed, 15 insertions(+), 4

[PATCH 09/11] usb: gadget: pxa27x_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/pxa27x_udc.c | 58 +++-- drivers/usb/gadget/pxa27x_udc.h | 1 + 2 files changed, 16 insertions(+), 4

[PATCH 10/11] usb: gadget: s3c2410: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/s3c2410_udc.c | 65 drivers/usb/gadget/s3c2410_udc.h | 1 + 2 files changed, 13 insertions(+),

[PATCH 11/11] usb: gadget: completely remove ->start/->stop

2013-01-24 Thread Felipe Balbi
Those have been deprecated for a long time and previous patches just converted all remaining users of those. Since there are no in-tree users and we don't want any new users for them, let's obliterate every piece of code related to those calls. Signed-off-by: Felipe Balbi --- drivers/usb/gadget

[PATCH v2] usb: gadget: pxa27x_udc: convert to udc_start/udc_stop

2013-01-24 Thread Felipe Balbi
Mechanical change making use of the new (can we still call it new ?) interface for registering UDC drivers. Signed-off-by: Felipe Balbi --- Had missed a trailing gadget->disconnect() call. drivers/usb/gadget/pxa27x_udc.c | 61 ++--- drivers/usb/gadget/pxa27x

Re: [RFC PATCH] uvc_v4l2: reset connection on uvc open

2013-01-24 Thread Felipe Balbi
On Thu, Jan 24, 2013 at 04:05:16PM +0100, Laurent Pinchart wrote: > Hi Felipe, > > On Thursday 24 January 2013 16:42:50 Felipe Balbi wrote: > > On Thu, Jan 24, 2013 at 03:35:58PM +0100, Michael Grzeschik wrote: > > > On Thu, Jan 24, 2013 at 03:21:37PM +0100, Laurent Pinchart wrote: > > > > On Thur

Re: Linux USB file storage gadget with new UDC

2013-01-24 Thread Alan Stern
On Thu, 24 Jan 2013, victor yeo wrote: > In the udc driver, i can't assign a single ep0 descriptor to both > ep0_in_desc and ep0_out_desc. i think i should skip ep0_out_desc. Bear > in mind that i only define 3 endpoints in udc driver: ep0, ep1 bulk > in, ep1 bulk out. Will it cause any problem to

[RFC/PATCH 01/32] usb: gadget: udc-core: allow udc class register gadget device

2013-01-24 Thread Felipe Balbi
Currently all UDC drivers are calling device_register() before calling usb_add_gadget_udc(). In order to avoid code duplication, we can allow udc-core.c register that device. However that would become a really large patch, so to cope with the meanwhile and allow us to write bite-sized patches, we'

[RFC/PATCH 03/32] usb: musb: gadget: let udc-core manage gadget-dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can delete a little boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/musb/musb_gadget.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c index 8767874..1c4a8e8 1

[RFC/PATCH 04/32] usb: gadget: omap_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/omap_udc.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/usb/gadget/omap_udc.c b/drivers/usb/gadget/omap_udc.c index d0c87b1..234e82b 100644 ---

[RFC/PATCH 08/32] usb: gadget: bcm63xx_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/bcm63xx_udc.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/usb/gadget/bcm63xx_udc.c b/drivers/usb/gadget/bcm63xx_udc.c index 47a4993..10b0475 10064

[RFC/PATCH 06/32] usb: gadget: at91_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can remove some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/at91_udc.c | 13 ++--- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/drivers/usb/gadget/at91_udc.c b/drivers/usb/gadget/at91_udc.c index 10f45fa..177b56d 100

[RFC/PATCH 02/32] usb: dwc3: gadget: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
We don't need to register that device ourselves if we simply set gadget->register_my_device. Signed-off-by: Felipe Balbi --- drivers/usb/dwc3/gadget.c | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c inde

[RFC/PATCH 00/32] usb: refactor gadget->dev registration

2013-01-24 Thread Felipe Balbi
Hi folks, Please comment on this series as I need help testing it on all UDC controllers so we can send it for v3.10 merge window. NOTE: I will queue this series for v3.10 merge window, so make sure to test and comment. cheers Felipe Balbi (32): usb: gadget: udc-core: allow udc class register

[RFC/PATCH 05/32] usb: gadget: amd5536udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/amd5536udc.c | 9 + 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/usb/gadget/amd5536udc.c b/drivers/usb/gadget/amd5536udc.c index 3dac001..1827d4c 100644 ---

[RFC/PATCH 10/32] usb: gadget: fsl_qe_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fsl_qe_udc.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/usb/gadget/fsl_qe_udc.c b/drivers/usb/gadget/fsl_qe_udc.c index ec50f18..08c84

[RFC/PATCH 11/32] usb: gadget: fsl_udc_core: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fsl_udc_core.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/drivers/usb/gadget/fsl_udc_core.c b/drivers/usb/gadget/fsl_udc_core.c index 49642d4..b78b73

[RFC/PATCH 07/32] usb: gadget: atmel_usba_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/atmel_usba_udc.c | 13 + 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/usb/gadget/atmel_usba_udc.c b/drivers/usb/gadget/atmel_usba_udc.c index a7ae

[RFC/PATCH 12/32] usb: gadget: fusb300_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/fusb300_udc.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/usb/gadget/fusb300_udc.c b/drivers/usb/gadget/fusb300_udc.c index 8c2372f..798a

[RFC/PATCH 15/32] usb: gadget: lpc32xx_udc: let udc-core manage gadget->dev

2013-01-24 Thread Felipe Balbi
By simply setting a flag, we can drop some boilerplate code. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/lpc32xx_udc.c | 11 +-- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/drivers/usb/gadget/lpc32xx_udc.c b/drivers/usb/gadget/lpc32xx_udc.c index dd1c9b1..077e021

  1   2   3   >