[PATCH 3/4] usb: chipidea: add support for USB OTG controller on LSI Zevio SoCs

2014-03-10 Thread Peter Chen
From: Daniel Tang The USB controller in TI-NSPIRE calculators (LSI Zevio SoC) are based off either Freescale's USB OTG controller or the USB controller found in the IMX233, both of which are Chipidea compatible. This patch adds a device tree binding for the controller. Signed-off-by: Peter Chen

[PATCH 2/4] usb: chipidea: imx: Use dev_name() for ci_hdrc name to distinguish USBs

2014-03-10 Thread Peter Chen
From: Alexander Shiyan Use dev_name() for ci_hdrc name to distinguish USBs Signed-off-by: Peter Chen Signed-off-by: Alexander Shiyan --- drivers/usb/chipidea/ci_hdrc_imx.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/usb/chipidea/ci_hdrc_imx.c b/drivers/u

[PATCH 4/4] devicetree: bindings: document lsi,zevio-usb

2014-03-10 Thread Peter Chen
From: Daniel Tang Add documentation for zevio-usb Signed-off-by: Peter Chen Signed-off-by: Daniel Tang --- .../devicetree/bindings/usb/ci-hdrc-zevio.txt | 17 + 1 files changed, 17 insertions(+), 0 deletions(-) create mode 100644 Documentation/devicetree/bindings/usb/c

[PATCH 1/4] usb: chipidea: udc: refine isr_tr_complete_handler

2014-03-10 Thread Peter Chen
Matthieu CASTET and Michael Grzeschik mentioned isr_tr_complete_handler is a bit messy at below: http://marc.info/?l=linux-usb&m=139047775001152&w=2 This commit creates a new function isr_setup_packet_handler to handle setup packet, it makes isr_tr_complete_handler easy to read. This is no functi

[PATCH 0/4] USB Chipidea Patches for v3.15

2014-03-10 Thread Peter Chen
Hi Greg, This is the chipidea patchset for 3.15 merge windows, it adds a new SoC support, and refines the interrupt complete handler, etc, thanks. Alexander Shiyan (1): usb: chipidea: imx: Use dev_name() for ci_hdrc name to distinguish USBs Daniel Tang (2): usb: chipidea: add support for

Re: [PATCH] xhci: extend quirk for Renesas cards

2014-03-10 Thread Igor Gnatenko
On Mon, 2014-03-10 at 15:06 +0200, Mathias Nyman wrote: > On 03/09/2014 04:20 PM, Igor Gnatenko wrote: > > After suspend another Renesas PCI-X USB 3.0 card doesn't work. > > 03:00.0 USB controller [0c03]: Renesas Technology Corp. uPD720202 USB 3.0 > > Host Controller [1912:0015] (rev 02) (prog-if

Re: [PATCH v3] u_ether: move hardware transmit to RX workqueue

2014-03-10 Thread Felipe Balbi
On Sat, Mar 08, 2014 at 09:47:38AM -0800, Greg Kroah-Hartman wrote: > On Sun, Mar 09, 2014 at 01:27:48AM +0800, clanlab.proj wrote: > > Hi Greg, Dave and Felipe, > > > > On Sun, Mar 9, 2014 at 12:45 AM, Greg Kroah-Hartman > > wrote: > > > On Sat, Mar 08, 2014 at 03:39:48PM +0800, clanlab.proj wro

Re: usbnet: driver_info->stop required to stop USB interrupts?

2014-03-10 Thread Julius Werner
I think usbnet_stop() raced with the dev->bh tasklet, which by itself might not be a problem (usbnet_stop() later kills the tasklet itself, so it should expect that it can be running before that). The issue is that it calls usbnet_terminate_urbs() before that, which temporarily installs a waitqueue

Re: [PATCH net-next v2] r8152: add skb_cow_head

2014-03-10 Thread David Miller
From: Hayes Wang Date: Tue, 11 Mar 2014 10:20:32 +0800 > Call skb_cow_head() before editing the tx packet header. The header > would be reallocated if it is shared. > > Signed-off-by: Hayes Wang Applied, thanks. -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the bod

[PATCH net-next v2] r8152: add skb_cow_head

2014-03-10 Thread Hayes Wang
Call skb_cow_head() before editing the tx packet header. The header would be reallocated if it is shared. Signed-off-by: Hayes Wang --- drivers/net/usb/r8152.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c inde

Re: MAX3421E: device giving NAKs forever?

2014-03-10 Thread Felipe Balbi
Hi, (please avoid top-posting) On Mon, Mar 10, 2014 at 02:15:36PM -0600, David Mosberger wrote: > I was thinking of the Salea Logic ($150). > Are you aware of any limitations for this one that would get in the way? for full-speed USB it should work, I guess. Never

Re: usbnet: driver_info->stop required to stop USB interrupts?

2014-03-10 Thread Grant Grundler
On Mon, Mar 10, 2014 at 11:33 AM, Grant Grundler wrote: > I've trying to unravel a page fault panic I've run into a few times > while testing load/unload of asix driver with ChromeOS 3.8.11 based > kernel. I'm running into this crash on both ARM and X86. Correction - I can only confirm I've seen

Re: [PATCH net-next] r8152: add skb_cow_head

2014-03-10 Thread David Miller
From: Hayes Wang Date: Mon, 10 Mar 2014 14:22:31 +0800 > Call skb_cow_head() before editing the tx packet header. The header > would be reallocated if it is shared. > > Signed-off-by: Hayes Wang > --- > drivers/net/usb/r8152.c | 13 +++-- > 1 file changed, 11 insertions(+), 2 deletions

Re: MAX3421E: device giving NAKs forever?

2014-03-10 Thread David Mosberger
[Resend in plain text mode...] Thanks for taking a look! I thought that there might be an bug in re-transmitting the OUT requests that are being NAK'd indefinitely, but a different flash drive works much longer and with that drive, I see many OUT requests that get NAK'd a couple of times, but eve

Re: [PATCH] usb: gadget: f_fs: add missing spinlock and mutex unlock

2014-03-10 Thread Felipe Balbi
On Mon, Mar 10, 2014 at 02:05:47PM +0100, Michal Nazarewicz wrote: > On Mon, Mar 10 2014, Robert Baldyga wrote: > > This patch adds missing spin_unlock and mutex_unlock calls in > > error handling code. > > > > Signed-off-by: Robert Baldyga > > Acked-by: Michal Nazarewicz Greg, here's another

Re: MAX3421E: device giving NAKs forever?

2014-03-10 Thread Felipe Balbi
Hi, On Mon, Mar 10, 2014 at 01:48:33PM -0600, David Mosberger wrote: > Thanks for taking a look! > > I thought that there might be an bug in re-transmitting the OUT requests > that are being NAK'd indefinitely, but a different flash drive works much > longer and with that drive, I see many OUT re

Re: [PATCH 0/4] fix coccicenelle issues

2014-03-10 Thread Felipe Balbi
On Mon, Mar 10, 2014 at 11:55:18AM -0700, Greg KH wrote: > On Mon, Mar 10, 2014 at 01:30:52PM -0500, Felipe Balbi wrote: > > Hi, > > > > I plan on sending these 4 patches after v3.15-rc1 is tagged. > > Just send them to me now for 3.15-rc1, or I can just take these from the > patches themselves t

Re: [PATCH] rebind: Add rebind mechanism for runtime-resume

2014-03-10 Thread Alan Stern
On Mon, 10 Mar 2014, Poulain, Loic wrote: > Despite the needs_rebind flag, the interface rebind was never > done for the PM runtime resume. This patch fixes this issue > by triggering the rebind in usb runtime resume. > > The rebind procedure needs to be called with the device lock. > However, de

Re: [PATCH] rebind: Add rebind mechanism for runtime-resume

2014-03-10 Thread Greg KH
On Mon, Mar 10, 2014 at 05:27:17PM +, Poulain, Loic wrote: > Despite the needs_rebind flag, the interface rebind was never > done for the PM runtime resume. This patch fixes this issue > by triggering the rebind in usb runtime resume. > > The rebind procedure needs to be called with the device

Re: [PATCH 0/4] fix coccicenelle issues

2014-03-10 Thread Greg KH
On Mon, Mar 10, 2014 at 01:30:52PM -0500, Felipe Balbi wrote: > Hi, > > I plan on sending these 4 patches after v3.15-rc1 is tagged. Just send them to me now for 3.15-rc1, or I can just take these from the patches themselves to make it easier for you... greg k-h -- To unsubscribe from this list:

Re: [PATCH RFC] usb: gadget: Add xilinx axi usb2 device support

2014-03-10 Thread Felipe Balbi
Hi, On Mon, Mar 10, 2014 at 07:06:19PM +0530, sundeep subbaraya wrote: > On Fri, Feb 21, 2014 at 9:09 PM, Felipe Balbi wrote: > > Hi, > > > > On Fri, Feb 21, 2014 at 11:27:07AM +, Subbaraya Sundeep Bhatta wrote: > >> > From the looks of it, I doubt this was actually tested, you need a lot > >

Re: [PATCH v5 00/14] usb: phy: msm: Fixes, cleanups and DT support

2014-03-10 Thread Felipe Balbi
Hi, On Sat, Mar 08, 2014 at 06:46:52PM +0200, Ivan T. Ivanov wrote: > Hi, > > On 03/08/2014 02:15 AM, Felipe Balbi wrote: > > On Wed, Mar 05, 2014 at 05:54:03PM -0800, Tim Bird wrote: > >> Ivan, > >> > >> I'm still unsuccessful at getting this patch set to work on my kernel. > >> See regs in dmes

usbnet: driver_info->stop required to stop USB interrupts?

2014-03-10 Thread Grant Grundler
I've trying to unravel a page fault panic I've run into a few times while testing load/unload of asix driver with ChromeOS 3.8.11 based kernel. I'm running into this crash on both ARM and X86. Panic output below is from Exynos 5422 system. Test script attached. My _guess_ is usbnet_stop() is raci

[PATCH 1/4] usb: gadget: lpc32xx_udc: fix wrong clk_put() sequence

2014-03-10 Thread Felipe Balbi
This patch fixes the following Coccinelle error: drivers/usb/gadget/lpc32xx_udc.c:3313:1-7: ERROR: \ missing clk_put; clk_get on line 3139 and \ execution via conditional on line 3146 Signed-off-by: Felipe Balbi --- drivers/usb/gadget/lpc32xx_udc.c | 4 ++-- 1 file changed, 2 in

[PATCH 3/4] usb: gadget: inode: switch over to memdup_user()

2014-03-10 Thread Felipe Balbi
This patch fixes the following Coccinelle warning: drivers/usb/gadget/inode.c:442:8-15: WARNING \ opportunity for memdup_user Signed-off-by: Felipe Balbi --- drivers/usb/gadget/inode.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/usb/gadget/inode.

[PATCH 4/4] usb: gadget: composite: switch over to ERR_CAST()

2014-03-10 Thread Felipe Balbi
This patch fixes the following Coccinelle warning: drivers/usb/gadget/composite.c:1142:9-16: WARNING: \ ERR_CAST can be used with uc Signed-off-by: Felipe Balbi --- drivers/usb/gadget/composite.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/comp

[PATCH 0/4] fix coccicenelle issues

2014-03-10 Thread Felipe Balbi
Hi, I plan on sending these 4 patches after v3.15-rc1 is tagged. Felipe Balbi (4): usb: gadget: lpc32xx_udc: fix wrong clk_put() sequence usb: gadget: f_subset: switch over to PTR_RET usb: gadget: inode: switch over to memdup_user() usb: gadget: composite: switch over to ERR_CAST() driv

[PATCH 2/4] usb: gadget: f_subset: switch over to PTR_RET

2014-03-10 Thread Felipe Balbi
this patch fixes the following Coccinelle warning: drivers/usb/gadget/f_subset.c:279:8-14: WARNING: \ PTR_RET can be used Signed-off-by: Felipe Balbi --- drivers/usb/gadget/f_subset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/f_subset.c b/dri

[PATCH] rebind: Add rebind mechanism for runtime-resume

2014-03-10 Thread Poulain, Loic
Despite the needs_rebind flag, the interface rebind was never done for the PM runtime resume. This patch fixes this issue by triggering the rebind in usb runtime resume. The rebind procedure needs to be called with the device lock. However, depending the call path (remote wakeup, local resume), th

Re: [PATCH 1/2] usbcore: rename struct dev_state to struct usb_dev_state

2014-03-10 Thread Greg KH
On Mon, Mar 10, 2014 at 10:36:40AM +0200, Valentina Manea wrote: > Since it is needed outside usbcore and exposed in include/linux/usb.h, > it conflicts with enum dev_state in rt2x00 wireless driver. > > Mark it as usb specific to avoid conflicts in the future. > > Signed-off-by: Valentina Manea

Re: [PATCH 1/9] usb: chipidea: usbmisc: Add USB Host support for i.MX25/i.MX35 CPUs

2014-03-10 Thread Fabio Estevam
Hi Denis, On Mon, Mar 10, 2014 at 8:16 AM, Fabio Estevam wrote: > Denis, > > Could you please resend 4/9 by changing the clocks nodes in the OTG > and Host1 ports as shown above? Thinking more about it, it would be better to send the USB clock change as a separate patch. I can submit the dts c

Re: [PATCH v9 4/9] mfd: omap-usb-host: Use clock names as per function for reference clocks

2014-03-10 Thread Lee Jones
> Use a meaningful name for the reference clocks so that it indicates the > function. > > Update the OMAP4+ USB Host node as well to be in sync with the changes. > > CC: Benoît Cousson > CC: Lee Jones > CC: Samuel Ortiz > Signed-off-by: Roger Quadros > --- > arch/arm/boot/dts/omap4.dtsi |

Re: [PATCH v9 3/9] mfd: omap-usb-host: Use proper clock name instead of alias

2014-03-10 Thread Lee Jones
> Use the proper clock name 'usbhost_120m_fck' instead of the > alias 'ehci_logic_fck' > > Get rid of the 'ehci_logic_fck' alias from the OMAP3 hwmod data > as well. > > CC: Paul Walmsley > CC: Lee Jones > CC: Samuel Ortiz > Signed-off-by: Roger Quadros > --- > arch/arm/mach-omap2/omap_hwmod

Re: [PATCH v9 2/9] mfd: omap-usb-host: Always fail on clk_get() error

2014-03-10 Thread Lee Jones
> Be more strict and always fail on clk_get() error. > > CC: Lee Jones > CC: Samuel Ortiz > Signed-off-by: Roger Quadros > --- > drivers/mfd/omap-usb-host.c | 62 > + > 1 file changed, 40 insertions(+), 22 deletions(-) I like to principle of the pa

Re: [PATCH v9 1/9] mfd: omap-usb-host: Get clocks based on hardware revision

2014-03-10 Thread Lee Jones
> Not all revisions have all the clocks so get the necessary clocks > based on hardware revision. > > This should avoid un-necessary clk_get failure messages that were > observed earlier. > > Also remove the dummy USB host clocks from the OMAP3 clock data. > These are no longer expected by the dr

Re: wifi driver or USB might leads suspend/resume failure on thinkpad X1 carbon

2014-03-10 Thread Emmanuel Grumbach
On Mon, Mar 10, 2014 at 3:20 PM, Shuduo Sang wrote: > On Mon, Mar 10, 2014 at 6:50 PM, Emmanuel Grumbach > wrote: >> Hi, >> >> On Mon, Mar 10, 2014 at 7:05 AM, Shuduo Sang >> wrote: >>> Hi, >>> >>> Sorry for cross posting. I'm suffering an issue my Thinkpad X1 Carbo

Re: [PATCH RFC] usb: gadget: Add xilinx axi usb2 device support

2014-03-10 Thread sundeep subbaraya
On Fri, Feb 21, 2014 at 9:09 PM, Felipe Balbi wrote: > Hi, > > On Fri, Feb 21, 2014 at 11:27:07AM +, Subbaraya Sundeep Bhatta wrote: >> > From the looks of it, I doubt this was actually tested, you need a lot >> > of work on this driver. >> Tested on both ARM and Microblaze architectures with

Re: [PATCH v2 1/8] ARM: dts: dra7: Initialize USB_DPLL

2014-03-10 Thread Roger Quadros
On 03/10/2014 03:28 PM, Tero Kristo wrote: > On 03/10/2014 02:49 PM, Roger Quadros wrote: >> USB_DPLL must be initialized and locked at boot so that >> USB modules can work. >> >> Program USB_DLL_M2 output to half rate as well. >> >> Patch depends on >> https://www.mail-archive.com/linux-omap@vger.

Re: [PATCH v2 1/8] ARM: dts: dra7: Initialize USB_DPLL

2014-03-10 Thread Tero Kristo
On 03/10/2014 02:49 PM, Roger Quadros wrote: USB_DPLL must be initialized and locked at boot so that USB modules can work. Program USB_DLL_M2 output to half rate as well. Patch depends on https://www.mail-archive.com/linux-omap@vger.kernel.org/msg101300.html CC: Mike Turquette CC: Tero Kristo

Re: wifi driver or USB might leads suspend/resume failure on thinkpad X1 carbon

2014-03-10 Thread Shuduo Sang
On Mon, Mar 10, 2014 at 6:50 PM, Emmanuel Grumbach wrote: > Hi, > > On Mon, Mar 10, 2014 at 7:05 AM, Shuduo Sang wrote: >> Hi, >> >> Sorry for cross posting. I'm suffering an issue my Thinkpad X1 Carbon >> can't resume after suspend recently. I tried many ways includin

Re: [PATCH] usb: gadget: f_fs: add missing spinlock and mutex unlock

2014-03-10 Thread Michal Nazarewicz
On Mon, Mar 10 2014, Robert Baldyga wrote: > This patch adds missing spin_unlock and mutex_unlock calls in > error handling code. > > Signed-off-by: Robert Baldyga Acked-by: Michal Nazarewicz > --- > drivers/usb/gadget/f_fs.c |8 ++-- > 1 file changed, 6 insertions(+), 2 deletions(-)

Re: [PATCH] xhci: extend quirk for Renesas cards

2014-03-10 Thread Mathias Nyman
On 03/09/2014 04:20 PM, Igor Gnatenko wrote: After suspend another Renesas PCI-X USB 3.0 card doesn't work. 03:00.0 USB controller [0c03]: Renesas Technology Corp. uPD720202 USB 3.0 Host Controller [1912:0015] (rev 02) (prog-if 30 [XHCI]) Reported-and-tested-by: Anatoly K. Reference: http://re

[PATCHv4 3/4] usb: s3c-hsotg: Move s3c-hsotg data structures

2014-03-10 Thread Dinh Nguyen
From: Dinh Nguyen This patch moves the data structures that are in the s3c-hsotg source into core.h. This is a necessary step towards unifying the s3c-hsotg and dwc2 into a single DRD. Signed-off-by: Dinh Nguyen Tested-by: Jingoo Han Cc: Greg Kroah-Hartman Cc: Paul Zimmerman Cc: Felipe Balbi

[PATCHv4 1/4] usb: dwc2: Add defines to support the s3c-hsotg driver

2014-03-10 Thread Dinh Nguyen
From: Dinh Nguyen In preparation of combining the dwc2/s3c-hsotg driver in a single DRD driver, the defines in dwc2/hw.h needs to get updated so that the s3c-hsotg driver can use them. Signed-off-by: Dinh Nguyen Tested-by: Jingoo Han Cc: Greg Kroah-Hartman Cc: Paul Zimmerman Cc: Felipe Balbi

[PATCHv4 2/4] usb: s3c-hsotg: Move s3c-hsotg into dwc2 folder

2014-03-10 Thread Dinh Nguyen
From: Dinh Nguyen Moves the s3c-hsotg driver into the dwc2 folder and use the dwc2 defines in hw.h. Renamed the s3c-hsotg.c to gadget.c. Signed-off-by: Dinh Nguyen Tested-by: Jingoo Han Cc: Greg Kroah-Hartman Cc: Paul Zimmerman Cc: Felipe Balbi Cc: Ben Dooks Cc: Matt Porter Cc: Kukjin Kim

[PATCHv4 4/4] usb: dwc2: Edit the Kconfig and Makefile to build dwc2_gadget driver

2014-03-10 Thread Dinh Nguyen
From: Dinh Nguyen Modify the dwc2 Kconfig and Makefile so that it will build the dwc2_gadget driver when peripheral only mode is selected. The dwc_platform.ko and dwc2.ko will get built then dynamic linked modules are selected for Host mode. For peripheral mode only dwc2_gadget.ko will get built.

[PATCH v2 1/8] ARM: dts: dra7: Initialize USB_DPLL

2014-03-10 Thread Roger Quadros
USB_DPLL must be initialized and locked at boot so that USB modules can work. Program USB_DLL_M2 output to half rate as well. Patch depends on https://www.mail-archive.com/linux-omap@vger.kernel.org/msg101300.html CC: Mike Turquette CC: Tero Kristo Signed-off-by: Roger Quadros --- arch/arm/b

Re: musb for davinci

2014-03-10 Thread Alexander Holler
Am 10.03.2014 08:21, schrieb Christian Riesch: Hi Alexander, --On March 09, 2014 20:58 +0100 Alexander Holler wrote: Hello, may I ask what's the deal with drivers/usb/musb/davinci.c and why it depends on BROKEN? I've just enabled it here and it compiles and seems to work. I noticed the sa

Re: [PATCH 1/9] usb: chipidea: usbmisc: Add USB Host support for i.MX25/i.MX35 CPUs

2014-03-10 Thread Fabio Estevam
Hi Eric, On Mon, Mar 10, 2014 at 2:55 AM, Eric Bénard wrote: > Hi Fabio, >> (Not sure why it says full-speed device. When I connect the same >> device to a PC it says high-speed) >> > because i.MX25 and i.MX35 only have a full speed phy on the host port. This makes sense, thanks. -- To unsubscr

Re: [PATCH 1/9] usb: chipidea: usbmisc: Add USB Host support for i.MX25/i.MX35 CPUs

2014-03-10 Thread Fabio Estevam
Hi Alexander, On Mon, Mar 10, 2014 at 1:58 AM, Alexander Shiyan wrote: > Fabio, start with to make work USB port on your board in the bootloader. > Then with the previous driver (ehci-mxc). > Most likely problem is a wrong (or missing) clock. > As I mentioned earlier, DTS has incorrect clock nod

Re: [PATCH 1/6] libusbg: Add remove binding functionality.

2014-03-10 Thread Karol Lewandowski
On 03/10/2014 11:28 AM, Krzysztof Opasiak wrote: >> From: Robert Baldyga [mailto:r.bald...@samsung.com] >>> +static int usbg_remove_file(char *path, char *name) >>> +{ >>> + int ret; >>> + char buf[USBG_MAX_PATH_LENGTH]; >>> + >>> + sprintf(buf, "%s/%s", path, name); >> >> Maybe snprintf wou

Re: [PATCH 2/8] ARM: dts: dra7-clock: Add "l3init_960m_gfclk" clock gate

2014-03-10 Thread Roger Quadros
On 03/07/2014 03:59 PM, Tero Kristo wrote: > On 03/07/2014 03:09 PM, Roger Quadros wrote: >> This clock gate description was missing in older Reference manuals. >> It is present on the SoC to provide 960MHz reference clock to the >> internal USB PHYs. > > Can you provide a document reference here?

Re: [PATCH v2] phy-rcar-gen2-usb: add device tree support

2014-03-10 Thread Magnus Damm
Hi Sergei, On Sat, Mar 8, 2014 at 8:57 AM, Sergei Shtylyov wrote: > Hello. > > > On 03/07/2014 05:27 PM, Sergei Shtylyov wrote: > Add support of the device tree probing for the Renesas R-Car generation 2 SoCs documenting the device tree binding as necessary. > > Signed-off-by:

Re: wifi driver or USB might leads suspend/resume failure on thinkpad X1 carbon

2014-03-10 Thread Emmanuel Grumbach
Hi, On Mon, Mar 10, 2014 at 7:05 AM, Shuduo Sang wrote: > Hi, > > Sorry for cross posting. I'm suffering an issue my Thinkpad X1 Carbon > can't resume after suspend recently. I tried many ways including > latest vanilla kernel, latest stable 3.13 and 3.11 kernel

Re: wifi driver or USB might leads suspend/resume failure on thinkpad X1 carbon

2014-03-10 Thread Shuduo Sang
On Mon, Mar 10, 2014 at 3:27 PM, Emmanuel Grumbach wrote: > On Mon, Mar 10, 2014 at 8:49 AM, Shuduo Sang wrote: >> On Mon, Mar 10, 2014 at 2:11 PM, Emmanuel Grumbach >> wrote: >>> Hi, >>> >>> On Mon, Mar 10, 2014 at 7:05 AM, Shuduo Sang wrote: Hi, Sorry for cross posting. I'm su

Re: [PATCH 1/6] libusbg: Add remove binding functionality.

2014-03-10 Thread Robert Baldyga
On 03/10/2014 11:28 AM, Krzysztof Opasiak wrote: > Hi, > >> -Original Message- >> From: Robert Baldyga [mailto:r.bald...@samsung.com] >> Sent: Monday, March 10, 2014 10:43 AM >> To: Krzysztof Opasiak; mpor...@linaro.org; linux- >> u...@vger.kernel.org >> Cc: Andrzej Pietrasiewicz; Karol Le

RE: [PATCH 1/6] libusbg: Add remove binding functionality.

2014-03-10 Thread Krzysztof Opasiak
Hi, > -Original Message- > From: Robert Baldyga [mailto:r.bald...@samsung.com] > Sent: Monday, March 10, 2014 10:43 AM > To: Krzysztof Opasiak; mpor...@linaro.org; linux- > u...@vger.kernel.org > Cc: Andrzej Pietrasiewicz; Karol Lewandowski; Stanislaw Wadas; > ty317@samsung.org; Marek

Re: [PATCH 1/6] libusbg: Add remove binding functionality.

2014-03-10 Thread Robert Baldyga
Hi, > diff --git a/src/usbg.c b/src/usbg.c > index f655675..e82658c 100644 > --- a/src/usbg.c > +++ b/src/usbg.c > @@ -142,6 +142,7 @@ static int usbg_translate_error(int error) > break; > case EACCES: > case EROFS: > + case EPERM: > ret = USBG_ERROR_NO_

[PATCH 1/6] libusbg: Add remove binding functionality.

2014-03-10 Thread Krzysztof Opasiak
Add function which allow to remove binding between function and configuration. This functions also remove binding from internal library structures wht means that after this operation all pointers to removed binding are invalid. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10

[PATCH 0/6] libusbg: Add remove gadget/config/func/binding functionality.

2014-03-10 Thread Krzysztof Opasiak
Dear Matt, In this series of patch I have added remove gadget, config, function, binding functionality which was missing since introduction of library. I have also added remove strings functionality which allow to remove gadget and configuration strings in given language. To show how to use new p

[PATCH 4/6] libusbg: Add remove function functionality.

2014-03-10 Thread Krzysztof Opasiak
Add function which allow to remove USB function. This functions also remove function from internal library structures what means that after this operation all pointers to removed function are invalid. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10 ++ src/usbg.c

[PATCH 5/6] libusbg: Add remove gadget functionality.

2014-03-10 Thread Krzysztof Opasiak
Add function which allow to remove USB gadget. This functions also remove gadget from internal library structures what means that after this operation all pointers to removed gadget are invalid. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10 ++ src/usbg.c | 4

[PATCH 2/6] libusbg: Add remove gadget/config strings functionality.

2014-03-10 Thread Krzysztof Opasiak
Add functions which allow to remove strings in gadget and configuration. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 16 src/usbg.c | 47 +++ 2 files changed, 63 insertions(+) diff --git a/include/usbg/usbg

[PATCH 6/6] libusbg: Update examples to new API functionality.

2014-03-10 Thread Krzysztof Opasiak
Removing gadget/config/function/binding functionality has been added to API so add example of how to use it. Signed-off-by: Krzysztof Opasiak --- examples/Makefile.am |3 +- examples/gadget-vid-pid-remove.c | 113 ++ include/usbg/usbg.h

[PATCH 3/6] libusbg: Add remove configuration functionality.

2014-03-10 Thread Krzysztof Opasiak
Add function which allow to remove configuration. This functions also remove binding from internal library structures what means that after this operation all pointers to removed config are invalid. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10 + src/usbg.c |

[PATCH v2 22/23] libusbg: Add functions for getting error strings.

2014-03-10 Thread Krzysztof Opasiak
Add usbg_error_name() to get error name as a string. Add usbg_strerror() to get brief error description in English. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 16 ++ src/usbg.c | 86 +++ 2 files changed, 102 in

[PATCH v2 19/23] libusbg: Return error code instead of NULL pointer - config.

2014-03-10 Thread Krzysztof Opasiak
Change usbg_get_config_strs() and usbg_get_config_attrs() to return usbg_error instead of NULL pointer. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h |9 - src/usbg.c | 50 +- 2 files changed, 29 insertions(+), 30

[PATCH v2 18/23] libusbg: Return error code instead of NULL pointer.

2014-03-10 Thread Krzysztof Opasiak
Change usbg_get_gadget_strs() and usbg_get_gadget_attrs() to return usbg_error instead of NULL pointer. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10 -- src/usbg.c | 43 ++- 2 files changed, 26 insertions(+), 27 deleti

[PATCH v2 15/23] libusbg: Add return value to usb function related functions.

2014-03-10 Thread Krzysztof Opasiak
Each usbg_set_*() may fail so it should have a return value to notify user about reason of failure. To be consistent with rest of API usbg_create_function() should also return error code to notify user about reasons of failure instead of binary information (NULL or not). Signed-off-by: Krzysztof

[PATCH v2 20/23] libusbg: Change usbg_get_function_attrs() to return error code.

2014-03-10 Thread Krzysztof Opasiak
usbg_get_function_attrs() may fail due to many reasons so it should notify the user about exact reason of failure instead of returning only NULL pointer. Add also USBG_ERROR_NOT_SUPPORTED to usbg_set_function_attrs(). Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h |5 ++-- src/usb

[PATCH v2 17/23] libusbg: Add return value to usbg_enable/disable_gadget().

2014-03-10 Thread Krzysztof Opasiak
Enabling and disabling gadget may fail due to many reasons so those functions should notify user about it. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 10 +--- src/usbg.c | 67 ++- 2 files changed, 57 insertions(+),

[PATCH v2 16/23] libusbg: Add return value to config related functions.

2014-03-10 Thread Krzysztof Opasiak
Each usbg_set_config_*() may fail so it should have a return value to notify user about reason of failure. To be consistent with rest of API usbg_create_config() should also return error code to notify user about reasons of failure instead of binary information (NULL or not). Signed-off-by: Krzys

[PATCH v2 23/23] libusbg: Update examples to use returned error codes.

2014-03-10 Thread Krzysztof Opasiak
Examples provided with the library should use returned error codes and provide information to user. Remove todo baceuse it has been already done. Signed-off-by: Krzysztof Opasiak --- examples/gadget-acm-ecm.c | 51 +++-- examples/show-gadgets.c | 40

[PATCH v2 21/23] libusbg: Return error code instead of -1.

2014-03-10 Thread Krzysztof Opasiak
Change usbg_add_config_function() to return usbg_error instead of returning 0 or -1. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h |2 +- src/usbg.c | 14 -- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/include/usbg/usbg.h b/include/usbg/us

[PATCH v2 06/23] libusbg: Refresh function attributes while each get.

2014-03-10 Thread Krzysztof Opasiak
Function attributes may be changed by kernel or other user so they should not be cached in library structures. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 31 +++ 1 file changed, 11 insertions(+), 20 deletions(-) diff --git a/src/usbg.c b/src/usbg.c index 63b

[PATCH v2 09/23] libusbg: Add error handling to usbg_init() and related functions.

2014-03-10 Thread Krzysztof Opasiak
Assumption that all malloc() and read()/write() finish correctly is too bold. Errors should be handled and propagated to upper layers of library and returned to user. Signed-off-by: Krzysztof Opasiak --- examples/gadget-acm-ecm.c |5 +- examples/show-gadgets.c |5 +- include/usbg/usbg.

[PATCH v2 08/23] libusbg: Fix wrong binding parsing.

2014-03-10 Thread Krzysztof Opasiak
usbg_parse_bindings() function has done parsing incorrectly and in inefficent way. Changes made in this function provide better performance and fix wrong linking issue when having two instances of the same function. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 35 +

[PATCH v2 12/23] libusbg: Add parenthesis to INSERT_TAILQ_STRING_ORDER macro.

2014-03-10 Thread Krzysztof Opasiak
Surround each pointer in macro with parenthesis to avid errors related to operator precedence. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/usbg.c b/src/usbg.c index 55e44c2..b6aa80d 100644 --- a/src/us

[PATCH v2 01/23] libusbg: Remove unused variables to make compiler happy.

2014-03-10 Thread Krzysztof Opasiak
Signed-off-by: Krzysztof Opasiak --- examples/gadget-acm-ecm.c |1 - examples/show-gadgets.c |1 - src/usbg.c|2 -- 3 files changed, 4 deletions(-) diff --git a/examples/gadget-acm-ecm.c b/examples/gadget-acm-ecm.c index b3c776d..5b027b6 100644 --- a/examples/gadget

[PATCH v2 10/23] libusbg: Return usbg_error instead of -1 in usbg_*_len().

2014-03-10 Thread Krzysztof Opasiak
Functions which provides user length of some internal strings should return usbg_error instead of -1. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 12 ++-- src/usbg.c | 12 ++-- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/include/us

[PATCH v2 13/23] libusbg: Add return value to gadget creation functions.

2014-03-10 Thread Krzysztof Opasiak
Functions related to gadget creation should return error codes instead of pointer. Signed-off-by: Krzysztof Opasiak --- examples/gadget-acm-ecm.c |4 +- include/usbg/usbg.h | 21 ++-- src/usbg.c| 258 + 3 files changed, 185

[PATCH v2 05/23] libusbg: Refresh config strings while each get.

2014-03-10 Thread Krzysztof Opasiak
Config strings should not be cached in library. Removing internal strings structure allowed to add full support for multilingual strings. Signed-off-by: Krzysztof Opasiak --- examples/show-gadgets.c |2 +- include/usbg/usbg.h |3 ++- src/usbg.c | 31 ---

[PATCH v2 00/23] libusbg: Add error code propagation and attributes refreshing.

2014-03-10 Thread Krzysztof Opasiak
Dear Matt, I have prepared next series of patches. This time I have added error code propagation which you have palced at todo list. In this series I have also removed caching gadget/function/config attributes in internal structures. Those attributes may be changed by kernel when enabling gadget,

[PATCH v2 03/23] libusbg: Refresh gadget strings while each get.

2014-03-10 Thread Krzysztof Opasiak
Gadget strings should not be cached in library. Removing internal strings structure allowed to add full support for multilingual strings. Signed-off-by: Krzysztof Opasiak --- examples/show-gadgets.c |2 +- include/usbg/usbg.h |6 -- src/usbg.c | 48

[PATCH v2 11/23] libusbg: Return usbg_error instead of char* in usbg_get_*_name().

2014-03-10 Thread Krzysztof Opasiak
API should be consistent and use error codes to determine what type of error occurred instead of returning NULL only. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 24 ++--- src/usbg.c | 60 --- 2 files cha

[PATCH v2 04/23] libusbg: Refresh config attributes while each get.

2014-03-10 Thread Krzysztof Opasiak
Config attributes may be changed by kernel or other user so they should not be cached in library structures. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/usbg.c b/src/usbg.c index 4a69b9c..e11f44e 100644 --- a

[PATCH v2 07/23] libusbg: Add internal free functions for each library structure.

2014-03-10 Thread Krzysztof Opasiak
Library should have internal API for freing structures instead of copy pasting same code in different places. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 77 +++- 1 file changed, 50 insertions(+), 27 deletions(-) diff --git a/src/u

[PATCH v2 14/23] libusbg: Add return value to usbg_set_gadget_*() functions.

2014-03-10 Thread Krzysztof Opasiak
Setting each of attribute may fail due to a lot of reasons so those functions should report this failure to a user. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 33 +--- src/usbg.c | 85 +-- 2 files change

[PATCH v2 02/23] libusbg: Refresh gadget attributes while each get.

2014-03-10 Thread Krzysztof Opasiak
Gadget attributes may be changed by kernel or other user so they should not be cached in library structures. Signed-off-by: Krzysztof Opasiak --- src/usbg.c | 16 +--- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/src/usbg.c b/src/usbg.c index 91165b8..ae26434 10064

[PATCH 2/2] staging: usbip: rename struct dev_state to usb_dev_state

2014-03-10 Thread Valentina Manea
struct dev_state definition in usbcore conflicted with enum dev_state definition in rt2x00 driver so it was renamed to usb_dev_state. Update usbip for this change. Signed-off-by: Valentina Manea --- drivers/staging/usbip/stub_dev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

[PATCH 1/2] usbcore: rename struct dev_state to struct usb_dev_state

2014-03-10 Thread Valentina Manea
Since it is needed outside usbcore and exposed in include/linux/usb.h, it conflicts with enum dev_state in rt2x00 wireless driver. Mark it as usb specific to avoid conflicts in the future. Signed-off-by: Valentina Manea --- drivers/usb/core/devio.c | 112 +++-

[PATCH 0/2] Rename struct dev_state to struct usb_dev_state

2014-03-10 Thread Valentina Manea
Since it is needed outside usbcore and exposed in include/linux/usb.h, it conflicts with enum dev_state in rt2x00 wireless driver and breaks the build. Mark it as usb specific to avoid conflicts in the future and update USB/IP to use the new name. Valentina Manea (2): usbcore: rename struct dev

[PATCH] usb: gadget: f_fs: add missing spinlock and mutex unlock

2014-03-10 Thread Robert Baldyga
This patch adds missing spin_unlock and mutex_unlock calls in error handling code. Signed-off-by: Robert Baldyga --- drivers/usb/gadget/f_fs.c |8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c index b7d273a..d6bd0

RE: [PATCH 08/23] libusbg: Fix wrong binding parsing.

2014-03-10 Thread Krzysztof Opasiak
> -Original Message- > From: Sergei Shtylyov [mailto:sergei.shtyl...@cogentembedded.com] > Sent: Wednesday, March 05, 2014 7:58 PM > To: Krzysztof Opasiak; mpor...@linaro.org; linux- > u...@vger.kernel.org > Cc: Andrzej Pietrasiewicz; Karol Lewandowski; Stanislaw Wadas; > ty317@samsung.

Re: wifi driver or USB might leads suspend/resume failure on thinkpad X1 carbon

2014-03-10 Thread Emmanuel Grumbach
On Mon, Mar 10, 2014 at 8:49 AM, Shuduo Sang wrote: > On Mon, Mar 10, 2014 at 2:11 PM, Emmanuel Grumbach > wrote: >> Hi, >> >> On Mon, Mar 10, 2014 at 7:05 AM, Shuduo Sang wrote: >>> Hi, >>> >>> Sorry for cross posting. I'm suffering an issue my Thinkpad X1 Carbon >>> can't resume after suspend

Re: musb for davinci

2014-03-10 Thread Christian Riesch
Hi Alexander, --On March 09, 2014 20:58 +0100 Alexander Holler wrote: Hello, may I ask what's the deal with drivers/usb/musb/davinci.c and why it depends on BROKEN? I've just enabled it here and it compiles and seems to work. I noticed the same for drivers/usb/musb/da8xx.c which was mark