Re: How should we handle isochronous underruns?

2013-07-18 Thread Clemens Ladisch
Ming Lei wrote: > On Fri, Jul 19, 2013 at 5:20 AM, Alan Stern wrote: >> On Thu, 18 Jul 2013, Clemens Ladisch wrote: >>> In any case, there must be _some_ mechanism to explicitly restart >>> a stream. I do not really care if this is some URB flag or some >>> function call. >> >> I prefer a functio

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Kishon Vijay Abraham I
Hi, On Friday 19 July 2013 11:59 AM, Greg KH wrote: > On Fri, Jul 19, 2013 at 11:25:44AM +0530, Kishon Vijay Abraham I wrote: >> Hi, >> >> On Friday 19 July 2013 11:13 AM, Greg KH wrote: >>> On Fri, Jul 19, 2013 at 11:07:10AM +0530, Kishon Vijay Abraham I wrote: + ret = dev_set_name(

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Greg KH
On Fri, Jul 19, 2013 at 11:25:44AM +0530, Kishon Vijay Abraham I wrote: > Hi, > > On Friday 19 July 2013 11:13 AM, Greg KH wrote: > > On Fri, Jul 19, 2013 at 11:07:10AM +0530, Kishon Vijay Abraham I wrote: > >> + ret = dev_set_name(&phy->dev, "%s.%d", dev_name(dev), id); > > > > Y

Re: [PATCH] staging: dwc2: fix thinko in dwc2_hc_set_even_odd_frame()

2013-07-18 Thread Stephen Warren
On 07/17/2013 02:07 PM, Paul Zimmerman wrote: ... > With the two additional patches I sent out yesterday and today, the > driver is working really well for me on the Pi with your mainline- > based kernel. I was able to run an overnight test copying data to/from > a thumb drive (not to the root fs d

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Kishon Vijay Abraham I
Hi, On Friday 19 July 2013 11:13 AM, Greg KH wrote: > On Fri, Jul 19, 2013 at 11:07:10AM +0530, Kishon Vijay Abraham I wrote: >> +ret = dev_set_name(&phy->dev, "%s.%d", dev_name(dev), id); > > Your naming is odd, no "phy" anywhere in it? You rely on the sender to > never s

Re: [PATCH] staging: dwc2: add driver parameter to set AHB config register value

2013-07-18 Thread Stephen Warren
On 07/16/2013 01:22 PM, Paul Zimmerman wrote: > The dwc2 driver sets the value of the DWC2 GAHBCFG register to 0x6, > which is GAHBCFG_HBSTLEN_INCR4. But different platforms may require > different values. In particular, the Broadcom 2835 SOC used in the > Raspberry Pi needs a value of 0x10, otherw

Re: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread Stephen Warren
On 07/17/2013 01:35 PM, Paul Zimmerman wrote: > The transfer scheduler in the dwc2 driver is pretty basic, not to > mention buggy. It works fairly well with just a couple of devices > plugged in, but if you add, say, multiple devices with periodic > endpoints, the scheduler breaks down and can't ev

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Greg KH
On Fri, Jul 19, 2013 at 11:07:10AM +0530, Kishon Vijay Abraham I wrote: > +ret = dev_set_name(&phy->dev, "%s.%d", dev_name(dev), id); > >>> > >>> Your naming is odd, no "phy" anywhere in it? You rely on the sender to > >>> never send a duplicate name.id pair? Why not create your own

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Kishon Vijay Abraham I
Hi, On Thursday 18 July 2013 09:19 PM, Greg KH wrote: > On Thu, Jul 18, 2013 at 02:29:52PM +0530, Kishon Vijay Abraham I wrote: >> Hi, >> >> On Thursday 18 July 2013 12:50 PM, Greg KH wrote: >>> On Thu, Jul 18, 2013 at 12:16:10PM +0530, Kishon Vijay Abraham I wrote: +struct phy_provider *__of

Re: [PATCH 1/2] usb: class: move "checking 'actual'" code block into "checking 'buffer[1]'" code block

2013-07-18 Thread Chen Gang F T
On 07/19/2013 12:43 PM, Ming Lei wrote: > Hi Chen Gang, > > On Fri, Jul 19, 2013 at 12:21 PM, Chen Gang wrote: >> Hello Maintainers: >> >> Please help check this patch when you have time. > > Looks your patch is correct, and I think Greg will handle > your patch when usb-next tree is open. > T

Re: [PATCH 1/2] usb: class: move "checking 'actual'" code block into "checking 'buffer[1]'" code block

2013-07-18 Thread Ming Lei
Hi Chen Gang, On Fri, Jul 19, 2013 at 12:21 PM, Chen Gang wrote: > Hello Maintainers: > > Please help check this patch when you have time. Looks your patch is correct, and I think Greg will handle your patch when usb-next tree is open. Thanks, -- Ming Lei -- To unsubscribe from this list: send

Re: [PATCH 1/2] usb: class: move "checking 'actual'" code block into "checking 'buffer[1]'" code block

2013-07-18 Thread Chen Gang
Hello Maintainers: Please help check this patch when you have time. Thanks. On 07/11/2013 09:08 AM, Chen Gang wrote: > Hello Maintainers: > > Please help check this patch when you have time, thanks. > > BTW: this uninitialized variable warning may not be found by gcc > compiler (which a gcc bu

Re: [PATCH] [RFC] EHCI: add to memory barrier to updating hw_next

2013-07-18 Thread Ming Lei
On Thu, Jul 18, 2013 at 10:08 PM, Alan Stern wrote: > On Thu, 18 Jul 2013, Ming Lei wrote: > >> > I guess that HC could have a use-after-free problem like following >> > situation. >> > >> > 1. A qtd which is not at the queue head should be removed in >> > qh_completions(). >> > 2. The last->hw_

Re: [PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Greg KH
On Fri, Jul 19, 2013 at 10:20:07AM +0800, Chen Wang wrote: > Thanks, I resent my patch today after reading the doc, it does help. The > email still use the same subject, not sure if this will submerge my > latest submission, do I need to use a new subject, though I have not > thought of a better ne

Re: [PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Chen Wang
Thanks, I resent my patch today after reading the doc, it does help. The email still use the same subject, not sure if this will submerge my latest submission, do I need to use a new subject, though I have not thought of a better new one. Anyway, appreciated all of your great help! On Thu, 2013-07

[PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Chen Wang
From: Chen Wang Updated skel_read() in usb-skeleton.c. When there is no data in the buffer, we would allow retry for both blocking and nonblocking cases. Original logic give retry only for blocking case. Actually we can also allow retry for nonblocking case. This will reuse the existing retry

Re: How should we handle isochronous underruns?

2013-07-18 Thread Ming Lei
On Fri, Jul 19, 2013 at 5:20 AM, Alan Stern wrote: > On Thu, 18 Jul 2013, Clemens Ladisch wrote: > >> In any case, there must be _some_ mechanism to explicitly restart >> a stream. I do not really care if this is some URB flag or some >> function call. > > I prefer a function call over the flag.

Re: [PATCH] usb: Add Device Tree support to XHCI Platform driver

2013-07-18 Thread Xenia Ragiadakou
On 07/19/2013 02:12 AM, Sarah Sharp wrote: On Thu, Jul 18, 2013 at 06:35:13PM -0400, Al Cooper wrote: Add Device Tree match table. Setup dma_mask and coherent_dma_mask if they're not already set. Signed-off-by: Al Cooper --- drivers/usb/host/xhci-plat.c | 18 ++ 1 files ch

Re: [PATCH] device-core: Ensure drvdata = NULL when no driver is bound

2013-07-18 Thread Luis R. Rodriguez
On Tue, May 22, 2012 at 3:09 PM, Hans de Goede wrote: > 1) drvdata is for a driver to store a pointer to driver specific data > 2) If no driver is bound, there is no driver specific data associated with >the device > 3) Thus logically drvdata should be NULL if no driver is bound. > > But many

[PATCH] backports: backport drvdata = NULL core driver fixes

2013-07-18 Thread Luis R. Rodriguez
From: "Luis R. Rodriguez" The Linux kernel had tons of code which at times cleared the drvdata upon probe failure or release. There are however a bunch of drivers that didn't clear this. Commit 0998d063 implmented clearing this upon device_release_driver() and dealt with probe failure on driver_

[RFC 2/2] xhci: Report USB 2.1 link status for L1

2013-07-18 Thread Sarah Sharp
USB 2.1 devices can go into a lower power link state, L1. When they are active, they are in the L0 state. The L1 transition can be purely driven by software, or some USB host controllers (including some xHCI 1.0 hosts) allow the host hardware to track idleness and automatically place a port into

[RFC 0/2] xhci: Show USB 2.0 Link PM status

2013-07-18 Thread Sarah Sharp
Greetings! Alex has been working on some lsusb patches to show the USB 2.0 link status on xHCI hosts. In order to see whether an xHCI rootport is in the lower power link state L1, there needs to be some xHCI driver changes to show the USB 2.0 link status. Please review. Thanks, Sarah Sharp The

Re: [PATCH 1/2] Revert "Revert "HID: Fix logitech-dj: missing Unifying device issue""

2013-07-18 Thread Peter Hurley
On 07/18/2013 06:09 PM, Sarah Sharp wrote: On Thu, Jul 18, 2013 at 04:28:01PM -0400, Peter Hurley wrote: [ +cc Sarah Sharp, linux-usb ] On 07/18/2013 09:21 AM, Nestor Lopez Casado wrote: This reverts commit 8af6c08830b1ae114d1a8b548b1f8b056e068887. This patch re-adds the workaround introduced

[RFC 1/2] xhci: Refactor port status into a new function.

2013-07-18 Thread Sarah Sharp
The hub control function is *way* too long. Refactor it into a new function, and document the side effects of calling that function. Signed-off-by: Sarah Sharp --- drivers/usb/host/xhci-hub.c | 210 --- 1 files changed, 119 insertions(+), 91 deletions(-)

Re: [PATCH] usb: xhci: add the suspend/resume functionality

2013-07-18 Thread Sarah Sharp
Hi Felipe, My bad, this patch got dropped. I've refreshed it against Greg's usb-next branch. Do you still want me to push this? Again, my apologies for dropping this. Sarah Sharp On Tue, Feb 12, 2013 at 11:07:30PM +0200, Felipe Balbi wrote: > Hi, > > On Tue, Feb 12, 2013 at 12:47:23PM -0800,

Re: [PATCH] usb: Add Device Tree support to XHCI Platform driver

2013-07-18 Thread Sarah Sharp
On Thu, Jul 18, 2013 at 06:35:13PM -0400, Al Cooper wrote: > Add Device Tree match table. Setup dma_mask and coherent_dma_mask > if they're not already set. > > Signed-off-by: Al Cooper > --- > drivers/usb/host/xhci-plat.c | 18 ++ > 1 files changed, 18 insertions(+), 0 deletio

Re: [PATCH] usb: Add Device Tree support to XHCI Platform driver

2013-07-18 Thread Sergei Shtylyov
Hello. On 07/19/2013 02:35 AM, Al Cooper wrote: Add Device Tree match table. Setup dma_mask and coherent_dma_mask if they're not already set. Signed-off-by: Al Cooper [...] @@ -186,11 +198,17 @@ static int xhci_plat_remove(struct platform_device *dev) return 0; } +static const

Re: xhci driver problem

2013-07-18 Thread Sarah Sharp
On Thu, Jul 18, 2013 at 01:49:04PM -0700, Gene Kopan wrote: > Hi Sarah, thanks for helping. I answer your questions below. > > On 07/18/2013 12:55 PM, Sarah Sharp wrote: > >On Thu, Jul 18, 2013 at 11:03:32AM -0700, Gene Kopan wrote: > >>Hello Sarah, > >> > >> I am having an xhci_hcd problem on

[PATCH] usb: Add Device Tree support to XHCI Platform driver

2013-07-18 Thread Al Cooper
Add Device Tree match table. Setup dma_mask and coherent_dma_mask if they're not already set. Signed-off-by: Al Cooper --- drivers/usb/host/xhci-plat.c | 18 ++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-

Re: [PATCH] mmc: Allow sdhci platform drivers to set quirks2 from platform data

2013-07-18 Thread Sergei Shtylyov
Hello. On 07/19/2013 02:31 AM, Al Cooper wrote: Signed-off-by: Al Cooper --- drivers/mmc/host/sdhci-pltfm.c |4 +++- drivers/mmc/host/sdhci-pltfm.h |1 + 2 files changed, 4 insertions(+), 1 deletions(-) Hm, what this patch has to do with linux-usb? WBR, Sergei -- To unsubscr

[PATCH] mmc: Allow sdhci platform drivers to set quirks2 from platform data

2013-07-18 Thread Al Cooper
Signed-off-by: Al Cooper --- drivers/mmc/host/sdhci-pltfm.c |4 +++- drivers/mmc/host/sdhci-pltfm.h |1 + 2 files changed, 4 insertions(+), 1 deletions(-) diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c index 3145a78..e605509 100644 --- a/drivers/mmc/host/sdh

Re: [PATCH 1/2] Revert "Revert "HID: Fix logitech-dj: missing Unifying device issue""

2013-07-18 Thread Peter Hurley
[ +cc Sarah Sharp, linux-usb ] On 07/18/2013 09:21 AM, Nestor Lopez Casado wrote: This reverts commit 8af6c08830b1ae114d1a8b548b1f8b056e068887. This patch re-adds the workaround introduced by 596264082f10dd4 which was reverted by 8af6c08830b1ae114. The original patch 596264 was needed to overc

Re: [PATCH 1/2] Revert "Revert "HID: Fix logitech-dj: missing Unifying device issue""

2013-07-18 Thread Sarah Sharp
On Thu, Jul 18, 2013 at 04:28:01PM -0400, Peter Hurley wrote: > [ +cc Sarah Sharp, linux-usb ] > > On 07/18/2013 09:21 AM, Nestor Lopez Casado wrote: > >This reverts commit 8af6c08830b1ae114d1a8b548b1f8b056e068887. > > > >This patch re-adds the workaround introduced by 596264082f10dd4 > >which was

RE: [PATCH 0/3] staging: dwc2: Add some dma-related defensive programming

2013-07-18 Thread Paul Zimmerman
> From: Matthijs Kooijman [mailto:matth...@stdin.nl] > Sent: Wednesday, July 17, 2013 9:17 AM > > Here's a resend of three patches I sent a while ago as part of a bigger > series. These were the unimportant patches to be included later, so here > they are again. > > Gr. > > Matthijs > > Matthij

RE: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread Paul Zimmerman
> From: Matthijs Kooijman [mailto:matth...@stdin.nl] > Sent: Thursday, July 18, 2013 10:19 AM > > This seems related to a patch I made last year for the dwc_otg driver. > On RT3052, we only have 4 host channels, so it was easy to run out of > them using a 3G stick and a hub. The 3G sticks hog up 2

Re: How should we handle isochronous underruns?

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Clemens Ladisch wrote: > In any case, there must be _some_ mechanism to explicitly restart > a stream. I do not really care if this is some URB flag or some > function call. I prefer a function call over the flag. The function call can easily be issued just once, but the co

Re: [PATCH V3 5/6] USB: OHCI: make ohci-at91 a separate driver

2013-07-18 Thread Alan Stern
On Tue, 25 Jun 2013, Manjunath Goudar wrote: > Separate the TI OHCI Atmel host controller driver from ohci-hcd > host code so that it can be built as a separate driver module. > This work is part of enabling multi-platform kernels on ARM; > it would be nice to have in 3.11. This looks okay excep

Re: [PATCH V3 6/6] USB: OHCI: make ohci-s3c2410 a separate driver

2013-07-18 Thread Alan Stern
On Tue, 25 Jun 2013, Manjunath Goudar wrote: > Separate the Samsung OHCI S3C host controller driver from ohci-hcd > host code so that it can be built as a separate driver module. > This work is part of enabling multi-platform kernels on ARM; > it would be nice to have in 3.11. This patch look

Re: xhci driver problem

2013-07-18 Thread Sarah Sharp
On Thu, Jul 18, 2013 at 11:03:32AM -0700, Gene Kopan wrote: > > Hello Sarah, > > I am having an xhci_hcd problem on my ASUS U47A laptop (running > linux Mint 14) failing to mount an ASUS Xtion PRO Live RGBD camera: > > Jun 5 14:39:44 whiz7u kernel: [15698.052800] xhci_hcd :00:14.0: > >N

Re: How should we handle isochronous underruns?

2013-07-18 Thread Clemens Ladisch
Alan Stern wrote: > On Thu, 18 Jul 2013, Ming Lei wrote: >> On Thu, Jul 18, 2013 at 3:24 AM, Alan Stern >> wrote: >>> On Thu, 4 Jul 2013, Alan Stern wrote: On Thu, 4 Jul 2013, Ming Lei wrote: >>> I had some more ideas about this. Instead of requiring drivers to set >>> URB_ISO_ASAP on just

Re: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread gre...@linuxfoundation.org
On Thu, Jul 18, 2013 at 11:34:47AM -0600, Stephen Warren wrote: > On 07/18/2013 10:45 AM, Paul Zimmerman wrote: > >> From: linux-usb-ow...@vger.kernel.org > >> [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Gordon Hollingworth > >> Sent: Wednesday, July 17, 2013 11:00 PM > >> > >> I'd sugge

Re: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread Stephen Warren
On 07/18/2013 10:45 AM, Paul Zimmerman wrote: >> From: linux-usb-ow...@vger.kernel.org >> [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Gordon Hollingworth >> Sent: Wednesday, July 17, 2013 11:00 PM >> >> I'd suggest just adding a Raspberry Pi Foundation copyright. >> >> Is that OK or do y

Re: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread gre...@linuxfoundation.org
On Thu, Jul 18, 2013 at 04:45:55PM +, Paul Zimmerman wrote: > > From: linux-usb-ow...@vger.kernel.org > > [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Gordon Hollingworth > > Sent: Wednesday, July 17, 2013 11:00 PM > > > > I'd suggest just adding a Raspberry Pi Foundation copyright.

Re: question about bus_suspend and bus_resume

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Thomas Pugliese wrote: > Calling pm_runtime_get_noresume() instead of pm_runtime_disable() does the > trick. The root hub enumerates correctly and no longer thrashes > attempting bus_suspend/bus_resume. Good. > Moving forward, if I wanted to implement proper support for b

Re: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread Matthijs Kooijman
Hi Paul, > The transfer scheduler in the dwc2 driver is pretty basic, not to > mention buggy. It works fairly well with just a couple of devices > plugged in, but if you add, say, multiple devices with periodic > endpoints, the scheduler breaks down and can't even enumerate all > the devices. Thi

RE: [PATCH] staging: dwc2: add microframe scheduler from downstream Pi kernel

2013-07-18 Thread Paul Zimmerman
> From: linux-usb-ow...@vger.kernel.org > [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Gordon Hollingworth > Sent: Wednesday, July 17, 2013 11:00 PM > > I'd suggest just adding a Raspberry Pi Foundation copyright. > > Is that OK or do you need names for SOB? Ah yes, thanks for remindin

Re: Help r/e gadgetfs bulk xfer problem on Overo gumstix

2013-07-18 Thread Breton M. Saunders
Alan, Thanks for your advice, I believe I had a stupid coding error. Things are working now. Cheers, -Brett On 18/07/13 15:13, Alan Stern wrote: On Thu, 18 Jul 2013, Breton M. Saunders wrote: All, I'm running into problems with the gadgetfs usb.c bulk transport example, and

Re: question about bus_suspend and bus_resume

2013-07-18 Thread Thomas Pugliese
On Wed, 17 Jul 2013, Alan Stern wrote: > On Wed, 17 Jul 2013, Thomas Pugliese wrote: > > > On Wed, 17 Jul 2013, Alan Stern wrote: > > > > > On Wed, 17 Jul 2013, Thomas Pugliese wrote: > > > > > > > Hi, > > > > What is the expected behavior if a host controller does not implement > > > > bus_

Re: [PATCH V3 2/6] USB: OHCI: make ohci-omap a separate driver

2013-07-18 Thread Alan Stern
On Tue, 25 Jun 2013, Manjunath Goudar wrote: > Separate the TI OHCI OMAP1/2 host controller driver from ohci-hcd > host code so that it can be built as a separate driver module. > This work is part of enabling multi-platform kernels on ARM; > it would be nice to have in 3.11. I'm sorry it too

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Greg KH
On Thu, Jul 18, 2013 at 02:29:52PM +0530, Kishon Vijay Abraham I wrote: > Hi, > > On Thursday 18 July 2013 12:50 PM, Greg KH wrote: > > On Thu, Jul 18, 2013 at 12:16:10PM +0530, Kishon Vijay Abraham I wrote: > >> +struct phy_provider *__of_phy_provider_register(struct device *dev, > >> + struct m

Re: [PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Greg KH
On Thu, Jul 18, 2013 at 10:34:33PM +0800, Chen Wang wrote: > Opps, I find my email address is still wrong. Let me correct it and post > again. The mailing list does not accept html messages, and I can't accept a patch in html format. Please read the file, Documentation/email_clients.txt for some

RE: [PATCH 08/21] usb/gadget: f_mass_storage: split fsg_common initialization into a number of functions

2013-07-18 Thread Andrzej Pietrasiewicz
On Wednesday, July 17, 2013 5:44 PM Alan Stern wrote: > On Wed, 17 Jul 2013, Andrzej Pietrasiewicz wrote: > > > Hello Alan, > > Hello. > > > > > @@ -179,7 +179,7 @@ EXPORT_SYMBOL(fsg_ss_function); void > > > > fsg_lun_close(struct fsg_lun *curlun) { > > > > if (curlun->filp) { > > > >

[PATCH] usbserial: append Petatel NP10T device to GSM modems list

2013-07-18 Thread Dan Bolsun
This patch was tested on 3.10.1 kernel. Same models of Petatel NP10T modems have different device IDs. Unfortunately they have no additional revision information on a board which may treat them as different devices. Currently I've seen only two NP10T devices with various IDs. Possibly Petatel NP10

[PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Chen Wang
-- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: Help r/e gadgetfs bulk xfer problem on Overo gumstix

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Breton M. Saunders wrote: > All, > >I'm running into problems with the gadgetfs usb.c bulk transport > example, and am looking for some advice as to how to approach this problem. > >I am using the source code found at > http://www.linux-usb.org/gadget/usb.c, which

Help r/e gadgetfs bulk xfer problem on Overo gumstix

2013-07-18 Thread Breton M. Saunders
All, I'm running into problems with the gadgetfs usb.c bulk transport example, and am looking for some advice as to how to approach this problem. I am using the source code found at http://www.linux-usb.org/gadget/usb.c, which I compile for an overo gumstix board. Basically, I use a

Re: [PATCH] [RFC] EHCI: add to memory barrier to updating hw_next

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Ming Lei wrote: > > I guess that HC could have a use-after-free problem like following > > situation. > > > > 1. A qtd which is not at the queue head should be removed in > > qh_completions(). > > 2. The last->hw_next become be pointing at the next qtd but the hw_next > > v

Re: [PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Chen Wang
Please ignore this blank email, sorry for my wrong send. On Thu, Jul 18, 2013 at 10:04 PM, Chen Wang wrote: > -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info

Re: How should we handle isochronous underruns?

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Ming Lei wrote: > On Thu, Jul 18, 2013 at 3:24 AM, Alan Stern wrote: > > On Thu, 4 Jul 2013, Alan Stern wrote: > > > >> On Thu, 4 Jul 2013, Ming Lei wrote: > >> > >> > >> If so, your coming change may break ABI because as you described > >> > >> that "the flag should be set i

[PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread Chen Wang
-- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH] usb: gadget: udc-core: move sysfs_notify() to a workqueue

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Felipe Balbi wrote: > usb_gadget_set_state() will call sysfs_notify() > which might sleep. Some users might want to call > usb_gadget_set_state() from the very IRQ handler > which actually changes the gadget state. > > Instead of having every UDC driver add their own > workqu

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Alan Stern
On Thu, 18 Jul 2013, Felipe Balbi wrote: > > > yes. Only the UDC driver knows when the controller is moving among those > > > states. > > > > Not quite. Only the gadget driver knows when the transition between > > ADDRESS and CONFIGURED occurs. This should be added to composite.c. > > that's

RE: [PATCH]USB: usb-skeleton: add retry for nonblocking read

2013-07-18 Thread WangChen
Sorry, I find some tabs are still missed even I sent out as plain txt by outlook. Please ignore this again, I will try to resolve this before submit it. > From: unicorn_w...@outlook.com > To: linux-usb@vger.kernel.org > CC: oneu...@suse.de; gre...@linuxfoun

[PATCH]USB: usb-skeleton: add retry for nonblocking read

2013-07-18 Thread WangChen
From: Chen Wang unicorn_w...@outlook.com Updated skel_read() in usb-skeleton.c. When there is no data in the buffer, we would allow retry for both blocking and nonblocking cases. Original logic gives retry only for blocking case. Actually we can also allow retry for nonblocking case. This will

RE: [PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread WangChen
Sorry, please ignore this email, I find some tabs are lost after my paste and copy, sorry for this. I will send another email. > From: unicorn_w...@outlook.com > To: linux-usb@vger.kernel.org > CC: oneu...@suse.de; gre...@linuxfoundation.org > Subject: [PAT

[PATCH]USB: usb-skeleton.c: add retry for nonblocking read

2013-07-18 Thread WangChen
From: Chen Wang unicorn_w...@outlook.com Updated skel_read() in usb-skeleton.c. When there is no data in the buffer, we would allow retry for both blocking and nonblocking cases. Original logic give retry only for blocking case. Actually we can also allow retry for nonblocking case. This will r

Re: [PATCH] ARM: omap2: fix musb usage for n8x0

2013-07-18 Thread Stefan Roese
On 07/18/2013 02:02 PM, Daniel Mack wrote: > On 18.07.2013 11:40, Stefan Roese wrote: >> On 07/18/2013 11:18 AM, Kishon Vijay Abraham I wrote: I'm testing musb as OTG on beagleboard (old one, not Beagle-xm). And using the latest kernel.org version with this patch applied I see the fo

Re: [PATCH] ARM: omap2: fix musb usage for n8x0

2013-07-18 Thread Daniel Mack
On 18.07.2013 11:40, Stefan Roese wrote: > On 07/18/2013 11:18 AM, Kishon Vijay Abraham I wrote: >>> I'm testing musb as OTG on beagleboard (old one, not Beagle-xm). And >>> using the latest kernel.org version with this patch applied I see the >>> following messages while booting (repeatedly): >>>

Re: [RFC] ux500 dma & short transfers on MUSB

2013-07-18 Thread Sebastian Andrzej Siewior
On 07/11/2013 07:14 PM, Sebastian Andrzej Siewior wrote: Dan, Vinod, do you guys have an idea how the dma driver could inform its user how much of the requested data got really transferred? This requirement seems unique to USB where this happens and is not an error. Below an reply to Greg where I

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Felipe Balbi
On Thu, Jul 18, 2013 at 06:54:38PM +0800, Rong Wang wrote: > Hi Felipe, > > Here's the patch. If you are OK with it, I'll send it to the list formally. > Thanks. > > - > > usb: gadget: udc-core: make

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Rong Wang
Hi Felipe, Here's the patch. If you are OK with it, I'll send it to the list formally. Thanks. - usb: gadget: udc-core: make udc state attribute name consistent The name of udc state attribute file u

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Felipe Balbi
On Thu, Jul 18, 2013 at 05:28:19PM +0800, Rong Wang wrote: > Hi Felipe, > > Thanks, I'll test the patch. > > But sysfs_notify(&gadget->dev.kobj, NULL, "status"), status or state ? > I notice that DEVICE_ATTR(state, S_IRUGO, usb_gadget_state_show, NULL) good eyes, please send a patch which I'll q

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Felipe Balbi
Hi, On Thu, Jul 18, 2013 at 11:40:41AM +0300, Felipe Balbi wrote: > > >> >> > The question is since we default GADGET, so the g_mass_storage.ko is > > >> >> > installed early but connecting to a host PC > > >> >> > is randomly, But the udev has no idea when a host PC connects our > > >> >> > devi

[PATCH] usb: gadget: udc-core: move sysfs_notify() to a workqueue

2013-07-18 Thread Felipe Balbi
usb_gadget_set_state() will call sysfs_notify() which might sleep. Some users might want to call usb_gadget_set_state() from the very IRQ handler which actually changes the gadget state. Instead of having every UDC driver add their own workqueue for such a simple notification, we're adding it gene

Re: [PATCH] [RFC] EHCI: add to memory barrier to updating hw_next

2013-07-18 Thread Ming Lei
On Thu, Jul 18, 2013 at 9:30 AM, Gioh Kim wrote: > Thanks for your reply. > >> -Original Message- >> From: Ming Lei [mailto:tom.leim...@gmail.com] >> Sent: Wednesday, July 17, 2013 5:52 PM >> To: 김기오 >> Cc: Alan Stern; linux-usb@vger.kernel.org; linux-ker...@vger.kernel.org; >> Mark Salter

[PATCH] musb: don't reset endpoint data toggle on blackfin

2013-07-18 Thread Scott Jiang
Reset endpoint data toggle would lead to failure for musb RTL version 1.9 on blackfin. Signed-off-by: Scott Jiang --- drivers/usb/musb/musb_host.c |7 +-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c index a969

Re: [PATCH] ARM: omap2: fix musb usage for n8x0

2013-07-18 Thread Stefan Roese
On 07/18/2013 11:18 AM, Kishon Vijay Abraham I wrote: >> I'm testing musb as OTG on beagleboard (old one, not Beagle-xm). And >> using the latest kernel.org version with this patch applied I see the >> following messages while booting (repeatedly): >> >> [4.998168] usb usb1: bus auto-suspend, w

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Rong Wang
Hi Felipe, Thanks, I'll test the patch. But sysfs_notify(&gadget->dev.kobj, NULL, "status"), status or state ? I notice that DEVICE_ATTR(state, S_IRUGO, usb_gadget_state_show, NULL) On Thu, Jul 18, 2013 at 4:40 PM, Felipe Balbi wrote: > Hi, > > On Thu, Jul 18, 2013 at 04:33:43PM +0800, Rong Wan

Re: [PATCH] ARM: omap2: fix musb usage for n8x0

2013-07-18 Thread Kishon Vijay Abraham I
Hi, On Thursday 18 July 2013 02:44 PM, Stefan Roese wrote: > On 07/16/2013 08:52 PM, Daniel Mack wrote: >> Commit b7e2e75a8c ("usb: gadget: drop unused USB_GADGET_MUSB_HDRC") >> dropped a config symbol that was unused by the musb core, but it turns >> out that board support code had references to

Re: [PATCH] ARM: omap2: fix musb usage for n8x0

2013-07-18 Thread Stefan Roese
On 07/16/2013 08:52 PM, Daniel Mack wrote: > Commit b7e2e75a8c ("usb: gadget: drop unused USB_GADGET_MUSB_HDRC") > dropped a config symbol that was unused by the musb core, but it turns > out that board support code had references to it. > > As the core now has a fall-back to host-only mode if sup

Re: [PATCH 02/15] usb: phy: omap-usb2: use the new generic PHY framework

2013-07-18 Thread Kishon Vijay Abraham I
On Thursday 18 July 2013 12:51 PM, Greg KH wrote: > On Thu, Jul 18, 2013 at 12:16:11PM +0530, Kishon Vijay Abraham I wrote: >> Used the generic PHY framework API to create the PHY. Now the power off and >> power on are done in omap_usb_power_off and omap_usb_power_on respectively. >> >> However usi

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Kishon Vijay Abraham I
Hi, On Thursday 18 July 2013 12:50 PM, Greg KH wrote: > On Thu, Jul 18, 2013 at 12:16:10PM +0530, Kishon Vijay Abraham I wrote: >> +struct phy_provider *__of_phy_provider_register(struct device *dev, >> +struct module *owner, struct phy * (*of_xlate)(struct device *dev, >> +struct of_phand

[PATCH 4/6] ARM: dts: omap5-uevm: Use reset-gpio driver for hsusb2_reset

2013-07-18 Thread Roger Quadros
We no longer need to model a RESET line as a regulator since we have the reset-gpio driver available. Signed-off-by: Roger Quadros --- arch/arm/boot/dts/omap5-uevm.dts | 17 - 1 files changed, 8 insertions(+), 9 deletions(-) diff --git a/arch/arm/boot/dts/omap5-uevm.dts b/arch

[PATCH 2/6] ARM: dts: omap3-beagle: Use reset-gpio driver for hsusb2_reset

2013-07-18 Thread Roger Quadros
We no longer need to model a RESET line as a regulator since we have the reset-gpio driver available. Signed-off-by: Roger Quadros --- arch/arm/boot/dts/omap3-beagle.dts | 17 - 1 files changed, 8 insertions(+), 9 deletions(-) diff --git a/arch/arm/boot/dts/omap3-beagle.dts b

[PATCH 1/6] usb: phy-nop: Use RESET Controller for managing the reset line

2013-07-18 Thread Roger Quadros
Till now we were modelling the RESET line as a voltage regulator and using the regulator framework to manage it. [1] introduces a GPIO based reset controller driver. We use that to manage the PHY reset line, at least for DT boots. For legacy boots, will still need to use the regulator framework fo

[PATCH 3/6] ARM: dts: omap4-panda: Use reset-gpio driver for hsusb1_reset

2013-07-18 Thread Roger Quadros
We no longer need to model a RESET line as a regulator since we have the reset-gpio driver available. Signed-off-by: Roger Quadros --- arch/arm/boot/dts/omap4-panda-common.dtsi | 22 -- 1 files changed, 8 insertions(+), 14 deletions(-) diff --git a/arch/arm/boot/dts/omap4-

[PATCH 6/6] ARM: dts: omap3-beagle: Make USB host pin naming consistent

2013-07-18 Thread Roger Quadros
Use a common naming scheme "mode0name.modename flags" for the USB host pins to be consistent. Signed-off-by: Roger Quadros --- arch/arm/boot/dts/omap3-beagle.dts | 24 1 files changed, 12 insertions(+), 12 deletions(-) diff --git a/arch/arm/boot/dts/omap3-beagle.dts

[PATCH 0/6] USB: phy: phy-nop: Use RESET controller for managing the reset line

2013-07-18 Thread Roger Quadros
Hi, Till now we were modelling the RESET line as a voltage regulator and using the regulator framework to manage it. [1] introduces a GPIO based reset controller driver. We use that to manage the PHY reset line, at least for DT boots. For legacy boots, will still need to use the regulator framewo

[PATCH 5/6] ARM: dts: omap3-beagle-xm: Add USB Host support

2013-07-18 Thread Roger Quadros
Provide RESET controller and Power regulator for the USB PHY, the USB Host port mode and the PHY device. Provide pin multiplexer information for USB host pins. We also relocate omap3_pmx_core pin definations so that they are close to omap3_pmx_wkup pin definations. Signed-off-by: Roger Quadros -

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Felipe Balbi
Hi, On Thu, Jul 18, 2013 at 04:33:43PM +0800, Rong Wang wrote: > On Wed, Jul 17, 2013 at 9:27 PM, Felipe Balbi wrote: > > On Wed, Jul 17, 2013 at 09:04:54PM +0800, Rong Wang wrote: > >> Hi Felipe, > >> > >> On Wed, Jul 17, 2013 at 3:57 PM, Felipe Balbi wrote: > >> > Hi, > >> > > >> > On Mon, Jul

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Rong Wang
On Wed, Jul 17, 2013 at 9:27 PM, Felipe Balbi wrote: > On Wed, Jul 17, 2013 at 09:04:54PM +0800, Rong Wang wrote: >> Hi Felipe, >> >> On Wed, Jul 17, 2013 at 3:57 PM, Felipe Balbi wrote: >> > Hi, >> > >> > On Mon, Jul 15, 2013 at 11:31:17PM -0700, Greg KH wrote: >> >> > The question is since we d

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Rong Wang
Hi Peter, On Wed, Jul 17, 2013 at 10:36 AM, Peter Chen wrote: > On Mon, Jul 15, 2013 at 11:31:17PM -0700, Greg KH wrote: >> On Tue, Jul 16, 2013 at 11:49:07AM +0800, Rong Wang wrote: >> > Hi Greg, >> > >> > The USB on our platform can change roles between HOST and GADGET, but >> > it is not capa

Re: [PATCH] usb: udc: add gadget state kobject uevent

2013-07-18 Thread Felipe Balbi
Hi, On Wed, Jul 17, 2013 at 11:37:35AM -0400, Alan Stern wrote: > On Wed, 17 Jul 2013, Felipe Balbi wrote: > > > On Wed, Jul 17, 2013 at 09:04:54PM +0800, Rong Wang wrote: > > > Hi Felipe, > > > > > > On Wed, Jul 17, 2013 at 3:57 PM, Felipe Balbi wrote: > > > > Hi, > > > > > > > > On Mon, Jul 1

[PATCH v4 4/5] USB: gadget: atmel_usba: prepare clk before calling enable

2013-07-18 Thread Boris BREZILLON
Replace clk_enable/disable with clk_prepare_enable/disable_unprepare to avoid common clk framework warnings. Signed-off-by: Boris BREZILLON --- drivers/usb/gadget/atmel_usba_udc.c | 28 +--- 1 file changed, 21 insertions(+), 7 deletions(-) diff --git a/drivers/usb/gadg

Re: [PATCH 02/15] usb: phy: omap-usb2: use the new generic PHY framework

2013-07-18 Thread Greg KH
On Thu, Jul 18, 2013 at 12:16:11PM +0530, Kishon Vijay Abraham I wrote: > Used the generic PHY framework API to create the PHY. Now the power off and > power on are done in omap_usb_power_off and omap_usb_power_on respectively. > > However using the old USB PHY library cannot be completely removed

Re: [PATCH 01/15] drivers: phy: add generic PHY framework

2013-07-18 Thread Greg KH
On Thu, Jul 18, 2013 at 12:16:10PM +0530, Kishon Vijay Abraham I wrote: > +struct phy_provider *__of_phy_provider_register(struct device *dev, > + struct module *owner, struct phy * (*of_xlate)(struct device *dev, > + struct of_phandle_args *args)); > +struct phy_provider *__devm_of_phy_pro

Re: [PATCH 05/15] ARM: dts: omap: update usb_otg_hs data

2013-07-18 Thread Tony Lindgren
* Kishon Vijay Abraham I [130717 23:53]: > Updated the usb_otg_hs dt data to include the *phy* and *phy-names* > binding in order for the driver to use the new generic PHY framework. > Also updated the Documentation to include the binding information. > The PHY binding information can be found at

Re: [PATCH 04/15] ARM: OMAP: USB: Add phy binding information

2013-07-18 Thread Tony Lindgren
* Kishon Vijay Abraham I [130717 23:53]: > In order for controllers to get PHY in case of non dt boot, the phy > binding information (phy device name) should be added in the platform > data of the controller. > > Signed-off-by: Kishon Vijay Abraham I > Reviewed-by: Sylwester Nawrocki > Acked-by