Re: [PATCH 5/7] usb: gadget: fsl_udc: postpone freeing current dTD

2012-10-20 Thread Christoph Fritz
On Fri, 2012-10-19 at 13:44 +0300, Felipe Balbi wrote: I thought about this too but wasn't able to use chipidea with MXC_EHCI_INTERNAL_PHY as it's called in fsl_udc. that's a matter of writing the PHY driver, right ;-) It has nothing to do with chipidea, actually :-) Okay, I'll do. But

[PATCH 0/7] update USB gadget driver fsl-usb2-udc

2012-10-19 Thread Christoph Fritz
This series updates USB gadget driver fsl-usb2-udc. Christoph Fritz (7): usb: gadget: fsl_udc: simplify driver init usb: gadget: fsl_udc: protect fsl_pullup() with spin_lock usb: gadget: fsl_udc: convert to new ulc style usb: gadget: fsl_udc: drop ARCH dependency usb: gadget: fsl_udc

[PATCH 1/7] usb: gadget: fsl_udc: simplify driver init

2012-10-19 Thread Christoph Fritz
To initialize this driver use 'module_platform_driver' instead of '__init' and '__exit'. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com --- drivers/usb/gadget/fsl_udc_core.c | 37 +++-- 1 files changed, 11 insertions(+), 26 deletions(-) diff --git

[PATCH 2/7] usb: gadget: fsl_udc: protect fsl_pullup() with spin_lock

2012-10-19 Thread Christoph Fritz
(or GPIO) that detects a VBUS power session starting. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com --- drivers/usb/gadget/fsl_udc_core.c |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/drivers/usb/gadget/fsl_udc_core.c b/drivers/usb/gadget/fsl_udc_core.c index

[PATCH 3/7] usb: gadget: fsl_udc: convert to new ulc style

2012-10-19 Thread Christoph Fritz
Convert to new UDC style registration and remove global 'udc_controller' pointer. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com --- drivers/usb/gadget/fsl_udc_core.c | 289 + 1 files changed, 131 insertions(+), 158 deletions(-) diff --git a/drivers

[PATCH 4/7] usb: gadget: fsl_udc: drop ARCH dependency

2012-10-19 Thread Christoph Fritz
Drop the big-/little-endian helpers and make use of generic writel()/readl() routines. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com --- drivers/usb/gadget/fsl_udc_core.c | 331 + 1 files changed, 118 insertions(+), 213 deletions(-) diff --git

[PATCH 5/7] usb: gadget: fsl_udc: postpone freeing current dTD

2012-10-19 Thread Christoph Fritz
: http://cache.freescale.com/files/dsp/doc/errata/IMX23CE.pdf All (?) SOCs with an IP from chipidea suffer from this problem. mv_udc_core fixes this bug by commit daec765. There still may be unfixed drivers. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com Signed-off-by: Christian Hemp c.h

[PATCH 6/7] usb: gadget: fsl_udc: purge global pointer usb_sys_regs

2012-10-19 Thread Christoph Fritz
Move global driver pointer usb_sys_regs to private struct fsl_udc. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com Reviewed-by: Teresa Gamez t.ga...@phytec.de --- drivers/usb/gadget/fsl_udc_core.c | 26 -- drivers/usb/gadget/fsl_usb2_udc.h |1 + 2 files

[PATCH 7/7] usb: gadget: fsl_udc: purge global pointer dr_regs

2012-10-19 Thread Christoph Fritz
Move global driver pointer dr_regs to private struct fsl_udc. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com --- drivers/usb/gadget/fsl_udc_core.c | 252 +++-- drivers/usb/gadget/fsl_usb2_udc.h |1 + 2 files changed, 130 insertions(+), 123 deletions

Re: [PATCH 5/7] usb: gadget: fsl_udc: postpone freeing current dTD

2012-10-19 Thread Christoph Fritz
On Fri, 2012-10-19 at 13:30 +0300, Felipe Balbi wrote: On Fri, Oct 19, 2012 at 12:24:43PM +0200, Christoph Fritz wrote: USB controller may access a wrong address for the dTD (endpoint transfer descriptor) and then hang. This happens a lot when doing tests with g_ether module and iperf

Re: [PATCH v2] usb: fsl_udc: errata - postpone freeing current dTD

2012-06-12 Thread Christoph Fritz
Hi Fabio On Sun, 2012-06-10 at 15:41 -0300, Fabio Estevam wrote: Hi Christoph, On Mon, Jun 4, 2012 at 8:37 AM, Christoph Fritz chf.fr...@googlemail.com wrote: After that, I stumbled upon this dmesg: Freescale High-Speed USB SOC Device Controller driver (Apr 20, 2007) fsl-usb2-udc

Re: [PATCH v2] usb: fsl_udc: errata - postpone freeing current dTD

2012-06-04 Thread Christoph Fritz
Hi, On Mon, 2012-05-21 at 22:04 +0300, Felipe Balbi wrote: On Mon, May 21, 2012 at 08:57:22AM +0200, Christoph Fritz wrote: USB controller may access a wrong address for the dTD (endpoint transfer descriptor) and then hang. This happens a lot when doing tests with g_ether module and iperf

Re: [PATCH v2] usb: fsl_udc: errata - postpone freeing current dTD

2012-06-04 Thread Christoph Fritz
On Mon, 2012-06-04 at 13:30 +0200, Christoph Fritz wrote: Hi, On Mon, 2012-05-21 at 22:04 +0300, Felipe Balbi wrote: On Mon, May 21, 2012 at 08:57:22AM +0200, Christoph Fritz wrote: USB controller may access a wrong address for the dTD (endpoint transfer descriptor) and then hang

[PATCH] usb: gadget: regression fix - useage of usb_ep

2012-06-04 Thread Christoph Fritz
This patch removes redundant pointer to struct usb_endpoint_descriptor which were missed in commit 79149b8: usb: gadget: Update fsl_udc_core to use usb_endpoint_descriptor inside the struct usb_ep Due to clock framework regressions, this patch is only compile tested! Signed-off-by: Christoph

RE: [PATCH] usb: fsl_udc: errata - postpone freeing current dTD

2012-05-21 Thread Christoph Fritz
Hi Chen, On Mon, 2012-05-21 at 01:05 +, Chen Peter-B29397 wrote: USB controller may access a wrong address for the dTD (endpoint transfer descriptor) and then hang. This happens a lot when doing tests with g_ether module and iperf, a tool for measuring maximum TCP and UDP

[PATCH v2] usb: fsl_udc: errata - postpone freeing current dTD

2012-05-21 Thread Christoph Fritz
: http://cache.freescale.com/files/dsp/doc/errata/IMX23CE.pdf All (?) SOCs with an IP from chipidea suffer from this problem. mv_udc_core fixes this bug by commit daec765. There still may be unfixed drivers. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com Signed-off-by: Christian Hemp c.h

[PATCH] usb: fsl_udc: errata - postpone freeing current dTD

2012-05-20 Thread Christoph Fritz
: http://cache.freescale.com/files/dsp/doc/errata/IMX23CE.pdf mv_udc_core fixes this bug by commit daec765. There still may be unfixed drivers. Signed-off-by: Christoph Fritz chf.fr...@googlemail.com Signed-off-by: Christian Hemp c.h...@phytec.de --- drivers/usb/gadget/fsl_udc_core.c | 22

Re: [RFC] [PATCH] usb: gadget: fix dtd dma confusion

2012-05-13 Thread Christoph Fritz
On Wed, May 09, 2012 at 02:02:22AM +0200, Christoph Fritz wrote: Hi to All, after a while of testing and searching I can come up with a patch that fixes g_ether - iperf for fsl_udc on ARM i.MX35. The sad part is that this kind of fix is already implemented for marvell mv_udc driver

Re: [RFC] [PATCH] usb: gadget: fix dtd dma confusion

2012-05-09 Thread Christoph Fritz
Hi Neil, thanks for you help. What about the fix for mv_udc, shouldn't they have a similar limitation? How do you explain? Or maybe someone from Marvell has an answer? Yes, we encountered the same issue, and I have answered your question several hours ago. Please have a look.

[RFC] [PATCH] usb: gadget: fix dtd dma confusion

2012-05-08 Thread Christoph Fritz
On Wed, Apr 11, 2012 at 10:15:49AM -0300, Fabio Estevam wrote: On Wed, Apr 11, 2012 at 4:39 AM, Christoph Fritz chf.fr...@googlemail.com wrote: Can you approve this behaviour of g_ether/usbnet when using iperf? I am not very familiar with iperf, so I will let others comment. Hi to All

Re: [RFC] [PATCH] usb: gadget: fix dtd dma confusion

2012-05-08 Thread Christoph Fritz
Hi Peter, thanks you for your help. On Wed, May 09, 2012 at 02:11:56AM +, Chen Peter-B29397 wrote: after a while of testing and searching I can come up with a patch that fixes g_ether - iperf for fsl_udc on ARM i.MX35. The sad part is that this kind of fix is already

Re: [RFC] [PATCH] usb: gadget: fix dtd dma confusion

2012-05-08 Thread Christoph Fritz
On Wed, May 09, 2012 at 05:43:11AM +, Chen Peter-B29397 wrote: I'm hacking here an i.MX35 not an i.MX23. So I already had a look at its errata sheet http://cache.freescale.com/files/dsp/doc/errata/IMX35CE.pdf but didn't find a similar limitation as you now pointed out by errata