RE: [PATCH v2 00/30] usb: updates for dwc2 gadget driver
-Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Thursday, January 8, 2015 5:34 PM To: Kaukab, Yousaf; 'Paul Zimmerman'; 'linux-usb@vger.kernel.org'; 'ba...@ti.com' Cc: Herrero, Gregory; 'sergei.shtyl...@cogentembedded.com'; 'r.bald...@samsung.com' Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Yousaf, On 01/08/2015 08:27 AM, Kaukab, Yousaf wrote: Hi, -Original Message- From: Kaukab, Yousaf Sent: Wednesday, January 7, 2015 7:55 PM To: Dinh Nguyen; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: RE: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Dinh, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 5:26 PM To: Kaukab, Yousaf; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Yousaf, I've also attached a text file of the log. root@socfpga_cyclone5:~# insmod g_mass_storage.ko file=/dev/mmcblk0p1 [ 144.084933] Number of LUNs=8 [ 144.087817] Mass Storage Function, version: 2009/09/11 [ 144.092936] LUN: removable file: (no medium) [ 144.097228] Number of LUNs=1 [ 144.100217] LUN: file: /dev/mmcblk0p1 [ 144.103867] Number of LUNs=1 [ 144.106941] g_mass_storage gadget: Mass Storage Gadget, version: 2009/09/11 [ 144.113874] g_mass_storage gadget: userspace failed to provide iSerialNumber [ 144.120922] g_mass_storage gadget: g_mass_storage ready [ 144.129387] dwc2 ffb4.usb: bound driver g_mass_storage root@socfpga_cyclone5:~# root@socfpga_cyclone5:~# [ 144.353610] dwc2 ffb4.usb: new device is high-speed [ 144.527612] dwc2 ffb4.usb: new device is high-speed [ 149.595802] [ cut here ] [ 149.600420] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xcc/0x144() [ 149.609423] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 149.616582] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #14 [ 149.624202] Hardware name: Altera SOCFPGA [ 149.628222] [c00165e4] (unwind_backtrace) from [c00124f0] (show_stack+0x20/0x24) [ 149.635941] [c00124f0] (show_stack) from [c04c7374] (dump_stack+0x7c/0x98) [ 149.643147] [c04c7374] (dump_stack) from [c0023ec4] (warn_slowpath_common+0x88/0xc4) [ 149.651208] [c0023ec4] (warn_slowpath_common) from [c0023f2c] (warn_slowpath_null+0x2c/0x34) [ 149.659961] [c0023f2c] (warn_slowpath_null) from [c034ccc4] (s3c_hsotg_rx_data+0xcc/0x144) [ 149.668542] [c034ccc4] (s3c_hsotg_rx_data) from [c034f884] (s3c_hsotg_irq+0x3e0/0x708) [ 149.676777] [c034f884] (s3c_hsotg_irq) from [c0060d30] (handle_irq_event_percpu+0x68/0x204) [ 149.685442] [c0060d30] (handle_irq_event_percpu) from [c0060f20] (handle_irq_event+0x54/0x74) [ 149.694280] [c0060f20] (handle_irq_event) from [c0063e2c] (handle_fasteoi_irq+0xb8/0x190) [ 149.702771] [c0063e2c] (handle_fasteoi_irq) from [c0060548] (generic_handle_irq+0x30/0x40) [ 149.711348] [c0060548] (generic_handle_irq) from [c0060694] (__handle_domain_irq+0x64/0xc4) [ 149.720012] [c0060694] (__handle_domain_irq) from [c00086bc] (gic_handle_irq+0x30/0x6c) [ 149.728333] [c00086bc] (gic_handle_irq) from [c00130c0] (__irq_svc+0x40/0x54) [ 149.735781] Exception stack(0xc06fbf38 to 0xc06fbf80) [ 149.740811] bf20: [ 149.748953] bf40: c06fbf90 c001f600 c0702c60 c0733560 c0702498 c04cf08c c0732d73 413fc090 [ 149.757096] bf60: c0733560 c06fbf8c c06fbf90 c06fbf80 c000f934 c000f938 6013 [ 149.765243] [c00130c0] (__irq_svc) from [c000f938] (arch_cpu_idle+0x40/0x4c) [ 149.772616] [c000f938] (arch_cpu_idle) from [c0057670] (cpu_startup_entry+0x144/0x22c) [ 149.780857] [c0057670] (cpu_startup_entry) from [c04c2bc4] (rest_init+0x70/0x88) [ 149.788581] [c04c2bc4] (rest_init) from [c069bc60] (start_kernel+0x310/0x368) [ 149.796030] ---[ end trace 05bdb288fcc8864d ]--- [ 155.793924] random: nonblocking pool is initialized I don't see any debug messages. Did you enable CONFIG_USB_DWC2_DEBUG? If so, then perhaps you need to set the log level in your console (/proc/sys/kernel/printk)? What about Values of following registers GSNPSID, GHWCFG1-GHWCFG4? Is it possible for you to print them as well? Without the debug log it's difficult to conclude why you are seeing this behavior. One probable reason could be that your revision of the dwc2 core does not generate GRXSTS_PKTSTS_OUTDONE on setup packets. Rev 3.0a generates both GRXSTS_PKTSTS_OUTDONE and GRXSTS_PKTSTS_SETUPDONE on setup packets
RE: [PATCH v2 00/30] usb: updates for dwc2 gadget driver
Hi, -Original Message- From: Kaukab, Yousaf Sent: Wednesday, January 7, 2015 7:55 PM To: Dinh Nguyen; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: RE: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Dinh, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 5:26 PM To: Kaukab, Yousaf; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Yousaf, I've also attached a text file of the log. root@socfpga_cyclone5:~# insmod g_mass_storage.ko file=/dev/mmcblk0p1 [ 144.084933] Number of LUNs=8 [ 144.087817] Mass Storage Function, version: 2009/09/11 [ 144.092936] LUN: removable file: (no medium) [ 144.097228] Number of LUNs=1 [ 144.100217] LUN: file: /dev/mmcblk0p1 [ 144.103867] Number of LUNs=1 [ 144.106941] g_mass_storage gadget: Mass Storage Gadget, version: 2009/09/11 [ 144.113874] g_mass_storage gadget: userspace failed to provide iSerialNumber [ 144.120922] g_mass_storage gadget: g_mass_storage ready [ 144.129387] dwc2 ffb4.usb: bound driver g_mass_storage root@socfpga_cyclone5:~# root@socfpga_cyclone5:~# [ 144.353610] dwc2 ffb4.usb: new device is high-speed [ 144.527612] dwc2 ffb4.usb: new device is high-speed [ 149.595802] [ cut here ] [ 149.600420] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xcc/0x144() [ 149.609423] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 149.616582] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #14 [ 149.624202] Hardware name: Altera SOCFPGA [ 149.628222] [c00165e4] (unwind_backtrace) from [c00124f0] (show_stack+0x20/0x24) [ 149.635941] [c00124f0] (show_stack) from [c04c7374] (dump_stack+0x7c/0x98) [ 149.643147] [c04c7374] (dump_stack) from [c0023ec4] (warn_slowpath_common+0x88/0xc4) [ 149.651208] [c0023ec4] (warn_slowpath_common) from [c0023f2c] (warn_slowpath_null+0x2c/0x34) [ 149.659961] [c0023f2c] (warn_slowpath_null) from [c034ccc4] (s3c_hsotg_rx_data+0xcc/0x144) [ 149.668542] [c034ccc4] (s3c_hsotg_rx_data) from [c034f884] (s3c_hsotg_irq+0x3e0/0x708) [ 149.676777] [c034f884] (s3c_hsotg_irq) from [c0060d30] (handle_irq_event_percpu+0x68/0x204) [ 149.685442] [c0060d30] (handle_irq_event_percpu) from [c0060f20] (handle_irq_event+0x54/0x74) [ 149.694280] [c0060f20] (handle_irq_event) from [c0063e2c] (handle_fasteoi_irq+0xb8/0x190) [ 149.702771] [c0063e2c] (handle_fasteoi_irq) from [c0060548] (generic_handle_irq+0x30/0x40) [ 149.711348] [c0060548] (generic_handle_irq) from [c0060694] (__handle_domain_irq+0x64/0xc4) [ 149.720012] [c0060694] (__handle_domain_irq) from [c00086bc] (gic_handle_irq+0x30/0x6c) [ 149.728333] [c00086bc] (gic_handle_irq) from [c00130c0] (__irq_svc+0x40/0x54) [ 149.735781] Exception stack(0xc06fbf38 to 0xc06fbf80) [ 149.740811] bf20: [ 149.748953] bf40: c06fbf90 c001f600 c0702c60 c0733560 c0702498 c04cf08c c0732d73 413fc090 [ 149.757096] bf60: c0733560 c06fbf8c c06fbf90 c06fbf80 c000f934 c000f938 6013 [ 149.765243] [c00130c0] (__irq_svc) from [c000f938] (arch_cpu_idle+0x40/0x4c) [ 149.772616] [c000f938] (arch_cpu_idle) from [c0057670] (cpu_startup_entry+0x144/0x22c) [ 149.780857] [c0057670] (cpu_startup_entry) from [c04c2bc4] (rest_init+0x70/0x88) [ 149.788581] [c04c2bc4] (rest_init) from [c069bc60] (start_kernel+0x310/0x368) [ 149.796030] ---[ end trace 05bdb288fcc8864d ]--- [ 155.793924] random: nonblocking pool is initialized I don't see any debug messages. Did you enable CONFIG_USB_DWC2_DEBUG? If so, then perhaps you need to set the log level in your console (/proc/sys/kernel/printk)? What about Values of following registers GSNPSID, GHWCFG1-GHWCFG4? Is it possible for you to print them as well? Without the debug log it's difficult to conclude why you are seeing this behavior. One probable reason could be that your revision of the dwc2 core does not generate GRXSTS_PKTSTS_OUTDONE on setup packets. Rev 3.0a generates both GRXSTS_PKTSTS_OUTDONE and GRXSTS_PKTSTS_SETUPDONE on setup packets. If that's the case, then following patch might fix the problem: diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c index 20613db..7800384 100644 --- a/drivers/usb/dwc2/gadget.c +++ b/drivers/usb/dwc2/gadget.c @@ -1525,7 +1525,9 @@ static void s3c_hsotg_handle_rx(struct dwc2_hsotg *hsotg) SetupDone (Frame=0x%08x, DOPEPCTL=0x%08x)\n, s3c_hsotg_read_frameno(hsotg
Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver
On 01/07/2015 09:34 AM, Kaukab, Yousaf wrote: Hi, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 1:01 AM To: Paul Zimmerman; Kaukab, Yousaf; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/06/2015 05:47 PM, Dinh Nguyen wrote: On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh It looks like this patch is producing the above error. usb: dwc2: gadget: manage ep0 state in software Manage ep0 state in software to add handling of status OUT stage. Just toggling hsotg-setup in s3c_hsotg_handle_outdone leaves it in wrong state in 2-stage control transfers. Moreover, don't call s3c_hsotg_handle_outdone both from SetupDone and OutDone. Only use one of them, as for a setup packet we get both. Signed-off-by: Mian Yousaf Kaukab yousaf.kau...@intel.com Thank you for testing this patchset. I have tested g_mass_storage without dma in my setup and it is working fine. Did you also test with DMA enabled? As I don't see this problem, I need some help in figuring out what's going on. Would it be possible for you to provide me following? 1) Console output after enabling CONFIG_USB_DWC2_DEBUG 2) Function trace echo s3c_* /sys/kernel/debug/tracing/set_ftrace_filter echo function /sys/kernel/debug/tracing/current_tracer 3) Values of following registers GSNPSID, GHWCFG1-GHWCFG4 I'll try to get these out for your shortly. Dinh -- 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 v2 00/30] usb: updates for dwc2 gadget driver
Hi Yousaf, On 01/07/2015 09:47 AM, Kaukab, Yousaf wrote: -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 4:39 PM To: Kaukab, Yousaf; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/07/2015 09:34 AM, Kaukab, Yousaf wrote: Hi, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 1:01 AM To: Paul Zimmerman; Kaukab, Yousaf; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/06/2015 05:47 PM, Dinh Nguyen wrote: On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh It looks like this patch is producing the above error. usb: dwc2: gadget: manage ep0 state in software Manage ep0 state in software to add handling of status OUT stage. Just toggling hsotg-setup in s3c_hsotg_handle_outdone leaves it in wrong state in 2-stage control transfers. Moreover, don't call s3c_hsotg_handle_outdone both from SetupDone and OutDone. Only use one of them, as for a setup packet we get both. Signed-off-by: Mian Yousaf Kaukab yousaf.kau...@intel.com Thank you for testing this patchset. I have tested g_mass_storage without dma in my setup and it is working fine. Did you also test with DMA enabled? Yes, it's working as well. No issue. s3c_hsotg_rx_data() should not be called when DMA enabled. That's why I only mentioned without-dma case. As I don't see this problem, I need some help in figuring out what's going on. Would it be possible for you to provide me following? 1) Console output after enabling CONFIG_USB_DWC2_DEBUG 2) Function trace echo s3c_* /sys/kernel/debug/tracing/set_ftrace_filter echo function /sys/kernel/debug/tracing/current_tracer 3) Values of following registers GSNPSID, GHWCFG1-GHWCFG4 I'll try to get these out for your shortly. Thanks! I've also attached a text file
RE: [PATCH v2 00/30] usb: updates for dwc2 gadget driver
Hi Dinh, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 5:26 PM To: Kaukab, Yousaf; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver Hi Yousaf, I've also attached a text file of the log. root@socfpga_cyclone5:~# insmod g_mass_storage.ko file=/dev/mmcblk0p1 [ 144.084933] Number of LUNs=8 [ 144.087817] Mass Storage Function, version: 2009/09/11 [ 144.092936] LUN: removable file: (no medium) [ 144.097228] Number of LUNs=1 [ 144.100217] LUN: file: /dev/mmcblk0p1 [ 144.103867] Number of LUNs=1 [ 144.106941] g_mass_storage gadget: Mass Storage Gadget, version: 2009/09/11 [ 144.113874] g_mass_storage gadget: userspace failed to provide iSerialNumber [ 144.120922] g_mass_storage gadget: g_mass_storage ready [ 144.129387] dwc2 ffb4.usb: bound driver g_mass_storage root@socfpga_cyclone5:~# root@socfpga_cyclone5:~# [ 144.353610] dwc2 ffb4.usb: new device is high-speed [ 144.527612] dwc2 ffb4.usb: new device is high-speed [ 149.595802] [ cut here ] [ 149.600420] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xcc/0x144() [ 149.609423] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 149.616582] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #14 [ 149.624202] Hardware name: Altera SOCFPGA [ 149.628222] [c00165e4] (unwind_backtrace) from [c00124f0] (show_stack+0x20/0x24) [ 149.635941] [c00124f0] (show_stack) from [c04c7374] (dump_stack+0x7c/0x98) [ 149.643147] [c04c7374] (dump_stack) from [c0023ec4] (warn_slowpath_common+0x88/0xc4) [ 149.651208] [c0023ec4] (warn_slowpath_common) from [c0023f2c] (warn_slowpath_null+0x2c/0x34) [ 149.659961] [c0023f2c] (warn_slowpath_null) from [c034ccc4] (s3c_hsotg_rx_data+0xcc/0x144) [ 149.668542] [c034ccc4] (s3c_hsotg_rx_data) from [c034f884] (s3c_hsotg_irq+0x3e0/0x708) [ 149.676777] [c034f884] (s3c_hsotg_irq) from [c0060d30] (handle_irq_event_percpu+0x68/0x204) [ 149.685442] [c0060d30] (handle_irq_event_percpu) from [c0060f20] (handle_irq_event+0x54/0x74) [ 149.694280] [c0060f20] (handle_irq_event) from [c0063e2c] (handle_fasteoi_irq+0xb8/0x190) [ 149.702771] [c0063e2c] (handle_fasteoi_irq) from [c0060548] (generic_handle_irq+0x30/0x40) [ 149.711348] [c0060548] (generic_handle_irq) from [c0060694] (__handle_domain_irq+0x64/0xc4) [ 149.720012] [c0060694] (__handle_domain_irq) from [c00086bc] (gic_handle_irq+0x30/0x6c) [ 149.728333] [c00086bc] (gic_handle_irq) from [c00130c0] (__irq_svc+0x40/0x54) [ 149.735781] Exception stack(0xc06fbf38 to 0xc06fbf80) [ 149.740811] bf20: [ 149.748953] bf40: c06fbf90 c001f600 c0702c60 c0733560 c0702498 c04cf08c c0732d73 413fc090 [ 149.757096] bf60: c0733560 c06fbf8c c06fbf90 c06fbf80 c000f934 c000f938 6013 [ 149.765243] [c00130c0] (__irq_svc) from [c000f938] (arch_cpu_idle+0x40/0x4c) [ 149.772616] [c000f938] (arch_cpu_idle) from [c0057670] (cpu_startup_entry+0x144/0x22c) [ 149.780857] [c0057670] (cpu_startup_entry) from [c04c2bc4] (rest_init+0x70/0x88) [ 149.788581] [c04c2bc4] (rest_init) from [c069bc60] (start_kernel+0x310/0x368) [ 149.796030] ---[ end trace 05bdb288fcc8864d ]--- [ 155.793924] random: nonblocking pool is initialized I don't see any debug messages. Did you enable CONFIG_USB_DWC2_DEBUG? If so, then perhaps you need to set the log level in your console (/proc/sys/kernel/printk)? What about Values of following registers GSNPSID, GHWCFG1-GHWCFG4? Is it possible for you to print them as well? BR, Yousaf -- 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 v2 00/30] usb: updates for dwc2 gadget driver
Hi, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 1:01 AM To: Paul Zimmerman; Kaukab, Yousaf; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/06/2015 05:47 PM, Dinh Nguyen wrote: On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh It looks like this patch is producing the above error. usb: dwc2: gadget: manage ep0 state in software Manage ep0 state in software to add handling of status OUT stage. Just toggling hsotg-setup in s3c_hsotg_handle_outdone leaves it in wrong state in 2-stage control transfers. Moreover, don't call s3c_hsotg_handle_outdone both from SetupDone and OutDone. Only use one of them, as for a setup packet we get both. Signed-off-by: Mian Yousaf Kaukab yousaf.kau...@intel.com Thank you for testing this patchset. I have tested g_mass_storage without dma in my setup and it is working fine. As I don't see this problem, I need some help in figuring out what's going on. Would it be possible for you to provide me following? 1) Console output after enabling CONFIG_USB_DWC2_DEBUG 2) Function trace echo s3c_* /sys/kernel/debug/tracing/set_ftrace_filter echo function /sys/kernel/debug/tracing/current_tracer 3) Values of following registers GSNPSID, GHWCFG1-GHWCFG4 Dinh BR, Yousaf -- 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 v2 00/30] usb: updates for dwc2 gadget driver
-Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 4:39 PM To: Kaukab, Yousaf; Paul Zimmerman; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/07/2015 09:34 AM, Kaukab, Yousaf wrote: Hi, -Original Message- From: Dinh Nguyen [mailto:dingu...@opensource.altera.com] Sent: Wednesday, January 7, 2015 1:01 AM To: Paul Zimmerman; Kaukab, Yousaf; linux-usb@vger.kernel.org; ba...@ti.com Cc: Herrero, Gregory; sergei.shtyl...@cogentembedded.com; r.bald...@samsung.com Subject: Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver On 01/06/2015 05:47 PM, Dinh Nguyen wrote: On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh It looks like this patch is producing the above error. usb: dwc2: gadget: manage ep0 state in software Manage ep0 state in software to add handling of status OUT stage. Just toggling hsotg-setup in s3c_hsotg_handle_outdone leaves it in wrong state in 2-stage control transfers. Moreover, don't call s3c_hsotg_handle_outdone both from SetupDone and OutDone. Only use one of them, as for a setup packet we get both. Signed-off-by: Mian Yousaf Kaukab yousaf.kau...@intel.com Thank you for testing this patchset. I have tested g_mass_storage without dma in my setup and it is working fine. Did you also test with DMA enabled? Yes, it's working as well. No issue. s3c_hsotg_rx_data() should not be called when DMA enabled. That's why I only mentioned without-dma case. As I don't see this problem, I need some help in figuring out what's going on. Would it be possible for you to provide me following? 1) Console output after enabling CONFIG_USB_DWC2_DEBUG 2) Function trace echo s3c_* /sys/kernel/debug/tracing/set_ftrace_filter echo function /sys/kernel/debug/tracing/current_tracer 3) Values of following registers GSNPSID, GHWCFG1-GHWCFG4 I'll try to get these out for your shortly
Re: [PATCH v2 00/30] usb: updates for dwc2 gadget driver
On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh -- 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 v2 00/30] usb: updates for dwc2 gadget driver
On 01/06/2015 05:47 PM, Dinh Nguyen wrote: On 01/05/2015 01:16 PM, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. This patch series is producing this error on the SOCFPGA platform. I'll try to bisect to a specific patch. root@socfpga_cyclone5:~# [ 47.929743] dwc2 ffb4.usb: new device is low-speed [ 63.873596] dwc2 ffb4.usb: new device is low-speed [ 64.219220] dwc2 ffb4.usb: new device is low-speed [ 64.421495] dwc2 ffb4.usb: new device is low-speed [ 64.834505] dwc2 ffb4.usb: new device is high-speed [ 69.899695] [ cut here ] [ 69.904315] WARNING: CPU: 0 PID: 0 at drivers/usb/dwc2/gadget.c:1352 s3c_hsotg_rx_data+0xc0/0xd4() [ 69.913230] Modules linked in: g_mass_storage usb_f_mass_storage libcomposite [ 69.920385] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.0-rc1-00090-g4864f14 #4 [ 69.927917] Hardware name: Altera SOCFPGA [ 69.931936] [c0014d24] (unwind_backtrace) from [c001173c] (show_stack+0x10/0x14) [ 69.939654] [c001173c] (show_stack) from [c0461c74] (dump_stack+0x74/0x90) [ 69.946857] [c0461c74] (dump_stack) from [c0021138] (warn_slowpath_common+0x78/0xb4) [ 69.954916] [c0021138] (warn_slowpath_common) from [c0021190] (warn_slowpath_null+0x1c/0x24) [ 69.963669] [c0021190] (warn_slowpath_null) from [c030278c] (s3c_hsotg_rx_data+0xc0/0xd4) [ 69.972162] [c030278c] (s3c_hsotg_rx_data) from [c0304ac0] (s3c_hsotg_irq+0x454/0x520) [ 69.980394] [c0304ac0] (s3c_hsotg_irq) from [c0058c3c] (handle_irq_event_percpu+0x5c/0x1f4) [ 69.989056] [c0058c3c] (handle_irq_event_percpu) from [c0058e18] (handle_irq_event+0x44/0x64) [ 69.997892] [c0058e18] (handle_irq_event) from [c005b8d8] (handle_fasteoi_irq+0xa8/0x180) [ 70.006382] [c005b8d8] (handle_fasteoi_irq) from [c005856c] (generic_handle_irq+0x20/0x30) [ 70.014958] [c005856c] (generic_handle_irq) from [c0058668] (__handle_domain_irq+0x54/0xb4) [ 70.023619] [c0058668] (__handle_domain_irq) from [c0008638] (gic_handle_irq+0x20/0x5c) [ 70.031937] [c0008638] (gic_handle_irq) from [c0012240] (__irq_svc+0x40/0x54) [ 70.039384] Exception stack(0xc0635f60 to 0xc0635fa8) [ 70.044415] 5f60: c0635fb0 c001cee0 c066cca0 c063c498 c046908c c066c4b2 [ 70.052556] 5f80: c066cca0 0001 ef7fccc0 0100 c0635fa8 c000f0fc c000f100 [ 70.060694] 5fa0: 600f0013 [ 70.064174] [c0012240] (__irq_svc) from [c000f100] (arch_cpu_idle+0x30/0x3c) [ 70.071545] [c000f100] (arch_cpu_idle) from [c0050364] (cpu_startup_entry+0x138/0x224) [ 70.079783] [c0050364] (cpu_startup_entry) from [c05ebbb0] (start_kernel+0x304/0x35c) [ 70.087921] ---[ end trace 66b76f6dcbbda3bf ]--- [ 79.911589] dwc2 ffb4.usb: new device is low-speed Dinh It looks like this patch is producing the above error. usb: dwc2: gadget: manage ep0 state in software Manage ep0 state in software to add handling of status OUT stage. Just toggling hsotg-setup in s3c_hsotg_handle_outdone leaves it in wrong state in 2-stage control transfers. Moreover, don't call s3c_hsotg_handle_outdone both from SetupDone and OutDone. Only use one of them, as for a setup packet we get both. Signed-off-by: Mian Yousaf Kaukab yousaf.kau...@intel.com Dinh -- 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 v2 00/30] usb: updates for dwc2 gadget driver
On Mon, 5 Jan 2015, Paul Zimmerman wrote: Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. I'll try to test this by the end of this week. Dinh From: Mian Yousaf Kaukab [mailto:yousaf.kau...@intel.com] Sent: Friday, January 02, 2015 6:42 AM Hi, This patchset consists of various bug fixes and feature enhancements for the dwc2 gadget driver. All the patches are verified on dwc2 v3.0a with dedicated fifos. Main focus of testing was with dma enabled. Although basic testing without dma was also done. It is based on testing/next branch in Felipe's git with https://lkml.org/lkml/2014/12/16/135 applied on top. Thank you, Best regards, Yousaf History: v2: - Rebased to Felipe's testing/next with https://lkml.org/lkml/2014/12/16/135 applied on top. - Fixed comments from Robert Baldyga - Some cosmetic changes - Replaced usb: dwc2: gadget: process setup packet on transfer complete with usb: dwc2: gadget: don't process XferCompl on setup packet - Updated usb: dwc2: gadget: provide gadget handle to the phy so that otg_set_peripheral is called in both udc_start and udc_stop. v1: - Addressed comments from Sergei Shtylyov Gregory Herrero (13): usb: dwc2: gadget: register gadget handle to the phy usb: dwc2: gadget: write correct value in ahbcfg register usb: dwc2: gadget: don't erase gahbcfg register when enabling dma usb: dwc2: gadget: add device tree property to enable dma Documentation: dt-bindings: add dt binding info for dwc2 g-use-dma usb: dwc2: gadget: configure fifos from device tree Documentation: dt-bindings: add dt binding info for dwc2 fifo resizing usb: dwc2: gadget: don't block after fifo flush timeout usb: dwc2: gadget: add vbus_session support usb: dwc2: gadget: reset fifo_map when initializing fifos usb: dwc2: gadget: fix pullup handling usb: dwc2: gadget: add vbus_draw support usb: dwc2: gadget: force gadget initialization in dev mode Mian Yousaf Kaukab (17): usb: dwc2: gadget: mask fifo empty irq with dma usb: dwc2: gadget: don't process XferCompl on setup packet usb: dwc2: gadget: don't embed ep0 buffers usb: dwc2: gadget: fix error path in dwc2_gadget_init usb: dwc2: gadget: add bi-directional endpoint support usb: dwc2: gadget: check interrupts for all endpoints usb: dwc2: gadget: remove unused members from hsotg_req usb: dwc2: gadget: fix debug loop limits usb: dwc2: gadget: consider all tx fifos usb: dwc2: gadget: kill requests after disabling ep usb: dwc2: gadget: manage ep0 state in software usb: dwc2: gadget: fix zero length packet transfers usb: dwc2: gadget: dont warn if endpoint is not enabled usb: dwc2: gadget: rename sent_zlp to send_zlp usb: dwc2: gadget: pick smallest acceptable fifo usb: dwc2: gadget: fix fifo allocation leak usb: dwc2: gadget: report disconnection after reset Documentation/devicetree/bindings/usb/dwc2.txt | 4 + drivers/usb/dwc2/core.h| 46 +- drivers/usb/dwc2/gadget.c | 786 - drivers/usb/dwc2/hw.h | 1 + 4 files changed, 550 insertions(+), 287 deletions(-) -- 1.9.1 -- 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 BR, Dinh -- 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 v2 00/30] usb: updates for dwc2 gadget driver
Adding Dinh to CC. Robert, Dinh, I would like to have your tested-bys for this series, please. -- Paul From: Mian Yousaf Kaukab [mailto:yousaf.kau...@intel.com] Sent: Friday, January 02, 2015 6:42 AM Hi, This patchset consists of various bug fixes and feature enhancements for the dwc2 gadget driver. All the patches are verified on dwc2 v3.0a with dedicated fifos. Main focus of testing was with dma enabled. Although basic testing without dma was also done. It is based on testing/next branch in Felipe's git with https://lkml.org/lkml/2014/12/16/135 applied on top. Thank you, Best regards, Yousaf History: v2: - Rebased to Felipe's testing/next with https://lkml.org/lkml/2014/12/16/135 applied on top. - Fixed comments from Robert Baldyga - Some cosmetic changes - Replaced usb: dwc2: gadget: process setup packet on transfer complete with usb: dwc2: gadget: don't process XferCompl on setup packet - Updated usb: dwc2: gadget: provide gadget handle to the phy so that otg_set_peripheral is called in both udc_start and udc_stop. v1: - Addressed comments from Sergei Shtylyov Gregory Herrero (13): usb: dwc2: gadget: register gadget handle to the phy usb: dwc2: gadget: write correct value in ahbcfg register usb: dwc2: gadget: don't erase gahbcfg register when enabling dma usb: dwc2: gadget: add device tree property to enable dma Documentation: dt-bindings: add dt binding info for dwc2 g-use-dma usb: dwc2: gadget: configure fifos from device tree Documentation: dt-bindings: add dt binding info for dwc2 fifo resizing usb: dwc2: gadget: don't block after fifo flush timeout usb: dwc2: gadget: add vbus_session support usb: dwc2: gadget: reset fifo_map when initializing fifos usb: dwc2: gadget: fix pullup handling usb: dwc2: gadget: add vbus_draw support usb: dwc2: gadget: force gadget initialization in dev mode Mian Yousaf Kaukab (17): usb: dwc2: gadget: mask fifo empty irq with dma usb: dwc2: gadget: don't process XferCompl on setup packet usb: dwc2: gadget: don't embed ep0 buffers usb: dwc2: gadget: fix error path in dwc2_gadget_init usb: dwc2: gadget: add bi-directional endpoint support usb: dwc2: gadget: check interrupts for all endpoints usb: dwc2: gadget: remove unused members from hsotg_req usb: dwc2: gadget: fix debug loop limits usb: dwc2: gadget: consider all tx fifos usb: dwc2: gadget: kill requests after disabling ep usb: dwc2: gadget: manage ep0 state in software usb: dwc2: gadget: fix zero length packet transfers usb: dwc2: gadget: dont warn if endpoint is not enabled usb: dwc2: gadget: rename sent_zlp to send_zlp usb: dwc2: gadget: pick smallest acceptable fifo usb: dwc2: gadget: fix fifo allocation leak usb: dwc2: gadget: report disconnection after reset Documentation/devicetree/bindings/usb/dwc2.txt | 4 + drivers/usb/dwc2/core.h| 46 +- drivers/usb/dwc2/gadget.c | 786 - drivers/usb/dwc2/hw.h | 1 + 4 files changed, 550 insertions(+), 287 deletions(-) -- 1.9.1 -- 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
[PATCH v2 00/30] usb: updates for dwc2 gadget driver
Hi, This patchset consists of various bug fixes and feature enhancements for the dwc2 gadget driver. All the patches are verified on dwc2 v3.0a with dedicated fifos. Main focus of testing was with dma enabled. Although basic testing without dma was also done. It is based on testing/next branch in Felipe's git with https://lkml.org/lkml/2014/12/16/135 applied on top. Thank you, Best regards, Yousaf History: v2: - Rebased to Felipe's testing/next with https://lkml.org/lkml/2014/12/16/135 applied on top. - Fixed comments from Robert Baldyga - Some cosmetic changes - Replaced usb: dwc2: gadget: process setup packet on transfer complete with usb: dwc2: gadget: don't process XferCompl on setup packet - Updated usb: dwc2: gadget: provide gadget handle to the phy so that otg_set_peripheral is called in both udc_start and udc_stop. v1: - Addressed comments from Sergei Shtylyov Gregory Herrero (13): usb: dwc2: gadget: register gadget handle to the phy usb: dwc2: gadget: write correct value in ahbcfg register usb: dwc2: gadget: don't erase gahbcfg register when enabling dma usb: dwc2: gadget: add device tree property to enable dma Documentation: dt-bindings: add dt binding info for dwc2 g-use-dma usb: dwc2: gadget: configure fifos from device tree Documentation: dt-bindings: add dt binding info for dwc2 fifo resizing usb: dwc2: gadget: don't block after fifo flush timeout usb: dwc2: gadget: add vbus_session support usb: dwc2: gadget: reset fifo_map when initializing fifos usb: dwc2: gadget: fix pullup handling usb: dwc2: gadget: add vbus_draw support usb: dwc2: gadget: force gadget initialization in dev mode Mian Yousaf Kaukab (17): usb: dwc2: gadget: mask fifo empty irq with dma usb: dwc2: gadget: don't process XferCompl on setup packet usb: dwc2: gadget: don't embed ep0 buffers usb: dwc2: gadget: fix error path in dwc2_gadget_init usb: dwc2: gadget: add bi-directional endpoint support usb: dwc2: gadget: check interrupts for all endpoints usb: dwc2: gadget: remove unused members from hsotg_req usb: dwc2: gadget: fix debug loop limits usb: dwc2: gadget: consider all tx fifos usb: dwc2: gadget: kill requests after disabling ep usb: dwc2: gadget: manage ep0 state in software usb: dwc2: gadget: fix zero length packet transfers usb: dwc2: gadget: dont warn if endpoint is not enabled usb: dwc2: gadget: rename sent_zlp to send_zlp usb: dwc2: gadget: pick smallest acceptable fifo usb: dwc2: gadget: fix fifo allocation leak usb: dwc2: gadget: report disconnection after reset Documentation/devicetree/bindings/usb/dwc2.txt | 4 + drivers/usb/dwc2/core.h| 46 +- drivers/usb/dwc2/gadget.c | 786 - drivers/usb/dwc2/hw.h | 1 + 4 files changed, 550 insertions(+), 287 deletions(-) -- 1.9.1 -- 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