Vladimir Trukhin wrote:

By the way, I've added some custom output logs into pxa2xx_udc.c and file_storage.c.
And I found that exactly at this place (sending response to READ FORMAT CAPACITIES) function read_fifo() from pxa2xx_udc.c is never called. Maybe that is the source of my problem?!



As far as I got, read_fifo() function is called either in handle_ep() or in pxa2xx_ep_queue() calls.


During the time shown in the logs from the previous letter most sending operations are done by handle_ep() call which, in turn, is called from interrupt service routine pxa2xx_udc_irq(). So, for most sending operations interrupts occur. But not for the case with sending response to READ FORMAT CAPACITIES.

Here is a part of the new log:

-----------------------------------------------------------
udc: pxa2xx_udc: pxa2xx_ep_queue: insert into queue (time: 7806.73297 s):
g_file_storage gadget: get_next_command: after start_transfer (time: 7806.73328 s):
g_file_storage gadget: get_next_command: wait for next packet (time: 7806.73359 s):
g_file_storage gadget: get_next_command: wakeup (time: 7806.73393 s):
g_file_storage gadget: get_next_command: wait for next packet (time: 7806.73421 s):


udc: pxa2xx_udc: pxa2xx_udc_irq: not RST (time: 7806.78041 s): <------ !!!!!!!

udc: pxa2xx_udc: pxa2xx_udc_irq: handle_ep[ep2] (time: 7806.78068 s):
udc: pxa2xx_udc: read_fifo: length = 0 (time: 7806.78097 s):
udc: read ep2out-bulk c3, 31 bytes/S req c03f1460 31/64
udc: pxa2xx_udc: read_fifo: before done (time: 7806.78154 s):
udc: pxa2xx_udc: done: length = 31 (time: 7806.78180 s):
udc: pxa2xx_udc: done: status = 0 (time: 7806.78205 s):
g_file_storage gadget: bulk_out_complete: (time: 7806.78229 s):
g_file_storage gadget: bulk-out, length 31 (time: 7806.78257 s):
0: 55 53 42 43 10 5e 60 81 fc 00 00 00 80 00 0a 23
10: 00 00 00 00 00 00 00 fc 00 00 00 00 00 00 00
udc: pxa2xx_udc: pxa2xx_udc_irq: not RST (time: 7806.78373 s):
g_file_storage gadget: get_next_command: wakeup (time: 7806.78406 s):
g_file_storage gadget: get_next_command: before received_cbw (time: 7806.78435 s):
g_file_storage gadget: get_next_command: received_cbw: rc = 0 (time: 7806.78468 s):
g_file_storage gadget: SCSI command: READ FORMAT CAPACITIES; Dc=10, Di=252; Hc=10, Hi=252
g_file_storage gadget: bulk-in, length 0 (time: 7806.78544 s):
udc: pxa2xx_udc: write_fifo: before done (time: 7806.78577 s):
udc: pxa2xx_udc: done: length = 0 (time: 7806.78603 s):
udc: pxa2xx_udc: done: status = 0 (time: 7806.78628 s):
g_file_storage gadget: bulk-in set halt
udc: ep1in-bulk halt
g_file_storage gadget: sending command-failure status
g_file_storage gadget: sense data: SK x06, ASC x29, ASCQ x00; info x0
g_file_storage gadget: bulk-in, length 13 (time: 7806.79747 s):
0: 55 53 42 53 10 5e 60 81 fc 00 00 00 01
udc: pxa2xx_udc: write_fifo: before done (time: 7806.79817 s):
udc: pxa2xx_udc: done: length = 13 (time: 7806.79844 s):
udc: pxa2xx_udc: done: status = 0 (time: 7806.79868 s):
g_file_storage gadget: set_bulk_out_req_length: length = 31 (time: 7806.79895 s):
g_file_storage gadget: set_bulk_out_req_length: length = 64 (time: 7806.79928 s):
g_file_storage gadget: get_next_command: set_bulk_out_req_length (time: 7806.79962 s):
g_file_storage gadget: bulk-out, length 64 (time: 7806.79996 s):
0: 55 53 42 43 10 5e 60 81 fc 00 00 00 80 00 0a 23
10: 00 00 00 00 00 00 00 fc 00 00 00 00 00 00 00 74
20: 30 33 30 33 00 62 79 74 65 73 2f 53 20 72 65 71
30: 20 63 33 63 63 61 34 36 30 20 33 31 2f 36 34 0a
udc: pxa2xx_udc: pxa2xx_ep_queue: insert into queue (time: 7806.80195 s):
g_file_storage gadget: get_next_command: after start_transfer (time: 7806.80226 s):
g_file_storage gadget: get_next_command: wait for next packet (time: 7806.80257 s):
g_file_storage gadget: get_next_command: wakeup (time: 7806.80291 s):
g_file_storage gadget: get_next_command: wait for next packet (time: 7806.80320 s):


<------------- No Interrupts!!!

*****************************
delay
*****************************

udc: pxa2xx_udc: pxa2xx_udc_irq: reset (time: 7825.359321 s):
udc: USB reset start
udc: pxa2xx_udc: nuke: before done (time: 7825.359399 s):
udc: pxa2xx_udc: done: length = 0 (time: 7825.359426 s):
udc: pxa2xx_udc: done: status = -108 (time: 7825.359453 s):
g_file_storage gadget: bulk_out_complete: (time: 7825.359483 s):
g_file_storage gadget: bulk-out, length 0 (time: 7825.359520 s):
g_file_storage gadget: bulk_out_complete --> -108, 0/31
-----------------------------------------------------------



Does somebody have an idea why interrupts may not happen?

Vlad Trukhin




------------------------------------------------------- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to