OSDN Git Service

gadget event trace : add request pointer
authorMatthieu CASTET <matthieu.castet@parrot.com>
Fri, 1 Dec 2017 13:33:21 +0000 (14:33 +0100)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Mon, 11 Dec 2017 10:36:49 +0000 (12:36 +0200)
commitac3865557b274aa3984982c383b8cc66bbb42053
tree6529c903ca33dba01af0bfa20df07bfe5f984177
parent19e0b203bfbd3de525ff17b115acecd53ae08c87
gadget event trace : add request pointer

This allows to identify transfer request, if more than one are in queue.

This is allowed by usb_ep_queue : "Any endpoint
(except control endpoints like ep0) may have more than one transfer
request queued; they complete in FIFO order."

For example with adb gadget with function fs :

     <-transport-225   [002] d..1    47.136641: usb_ep_queue: ep1out: req ffffffc07b93ef10 length 0/24 sgs 0/0 stream 0 zsI status -115 --> 0
     ->transport-224   [000] d..1    47.153947: usb_ep_queue: ep1in: req ffffffc07c0def10 length 0/24 sgs 0/0 stream 0 zsI status -115 --> 0
              sh-452   [000] d.h2    47.153984: usb_gadget_giveback_request: ep1in: req ffffffc07c0def10 length 24/24 sgs 0/0 stream 0 zsI status 0 --> 0
              sh-452   [000] d.h.    47.154305: usb_gadget_giveback_request: ep1out: req ffffffc07b93ef10 length 24/24 sgs 0/0 stream 0 zsI status 0 --> 0
     <-transport-225   [002] d..1    47.154363: usb_ep_queue: ep1out: req ffffffc07b93ef10 length 0/21 sgs 0/0 stream 0 zsI status -115 --> 0
              sh-452   [000] d.h.    47.154378: usb_gadget_giveback_request: ep1out: req ffffffc07b93ef10 length 21/21 sgs 0/0 stream 0 zsI status 0 --> 0
     <-transport-225   [002] d..1    47.154463: usb_ep_queue: ep1out: req ffffffc07b93ef10 length 0/24 sgs 0/0 stream 0 zsI status -115 --> 0
     ->transport-224   [000] d..1    47.154583: usb_ep_queue: ep1in: req ffffffc07c0def10 length 0/24 sgs 0/0 stream 0 zsI status -115 --> 0
              sh-452   [000] d.h2    47.154600: usb_gadget_giveback_request: ep1in: req ffffffc07c0def10 length 24/24 sgs 0/0 stream 0 zsI status 0 --> 0
     ->transport-224   [000] d..1    47.164863: usb_ep_queue: ep1in: req ffffffc07c0def10 length 0/24 sgs 0/0 stream 0 zsI status -115 --> 0
     ->transport-224   [000] d.h1    47.164887: usb_gadget_giveback_request: ep1in: req ffffffc07c0def10 length 24/24 sgs 0/0 stream 0 zsI status 0 --> 0
     ->transport-224   [000] d..1    47.164907: usb_ep_queue: ep1in: req ffffffc07c0def10 length 0/122 sgs 0/0 stream 0 zsI status -115 --> 0

Signed-off-by: Matthieu CASTET <matthieu.castet@parrot.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/gadget/udc/trace.h