| From e5c75dbff074ac8c050940aeacfe02ea15726a1a Mon Sep 17 00:00:00 2001 |
| From: Mathias Nyman <mathias.nyman@linux.intel.com> |
| Date: Fri, 8 Dec 2017 17:59:14 +0200 |
| Subject: [PATCH 0531/1795] xhci: add port status tracing for Get Port Status |
| hub requests |
| |
| Add tracing showing the port status register content each time |
| the xhci roothub receives a Get Port Status request. |
| |
| Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> |
| Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
| (cherry picked from commit 28c06e58602fe48eb03ec8d4bdd005094fb6a31f) |
| Signed-off-by: Simon Horman <horms+renesas@verge.net.au> |
| Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> |
| --- |
| drivers/usb/host/xhci-hub.c | 1 + |
| drivers/usb/host/xhci-trace.h | 5 +++++ |
| 2 files changed, 6 insertions(+) |
| |
| diff --git a/drivers/usb/host/xhci-hub.c b/drivers/usb/host/xhci-hub.c |
| index a6ac7c5200fe..cb725a2c9529 100644 |
| --- a/drivers/usb/host/xhci-hub.c |
| +++ b/drivers/usb/host/xhci-hub.c |
| @@ -1076,6 +1076,7 @@ int xhci_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue, |
| retval = -ENODEV; |
| break; |
| } |
| + trace_xhci_get_port_status(wIndex, temp); |
| status = xhci_get_port_status(hcd, bus_state, port_array, |
| wIndex, temp, flags); |
| if (status == 0xffffffff) |
| diff --git a/drivers/usb/host/xhci-trace.h b/drivers/usb/host/xhci-trace.h |
| index d09a838058ee..3d5b6bde9168 100644 |
| --- a/drivers/usb/host/xhci-trace.h |
| +++ b/drivers/usb/host/xhci-trace.h |
| @@ -520,6 +520,11 @@ DEFINE_EVENT(xhci_log_portsc, xhci_handle_port_status, |
| TP_ARGS(portnum, portsc) |
| ); |
| |
| +DEFINE_EVENT(xhci_log_portsc, xhci_get_port_status, |
| + TP_PROTO(u32 portnum, u32 portsc), |
| + TP_ARGS(portnum, portsc) |
| +); |
| + |
| DECLARE_EVENT_CLASS(xhci_dbc_log_request, |
| TP_PROTO(struct dbc_request *req), |
| TP_ARGS(req), |
| -- |
| 2.19.0 |
| |