aboutsummaryrefslogtreecommitdiff
path: root/hw/usb/hcd-xhci.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2012-10-26 11:49:06 +0200
committerGerd Hoffmann <kraxel@redhat.com>2012-11-01 13:10:09 +0100
commit4f47f0f82eccbda44bac929df94fa244bf3452bd (patch)
tree070940d1dae07a1ce66eec25fa96ecf274563384 /hw/usb/hcd-xhci.c
parentb62b08282d9539a109b02e217d0cc7f7dcdb87ac (diff)
xhci: add port trace points
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/usb/hcd-xhci.c')
-rw-r--r--hw/usb/hcd-xhci.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
index 84d1b26bbb..325963882d 100644
--- a/hw/usb/hcd-xhci.c
+++ b/hw/usb/hcd-xhci.c
@@ -2391,12 +2391,14 @@ static void xhci_port_update(XHCIPort *port, int is_detach)
}
}
set_field(&port->portsc, pls, PORTSC_PLS);
+ trace_usb_xhci_port_link(port->portnr, pls);
xhci_port_notify(port, PORTSC_CSC);
}
static void xhci_port_reset(XHCIPort *port)
{
- DPRINTF("xhci: port %d reset\n", port);
+ trace_usb_xhci_port_reset(port->portnr);
+
if (!xhci_port_have_device(port)) {
return;
}
@@ -2408,6 +2410,7 @@ static void xhci_port_reset(XHCIPort *port)
case USB_SPEED_FULL:
case USB_SPEED_HIGH:
set_field(&port->portsc, PLS_U0, PORTSC_PLS);
+ trace_usb_xhci_port_link(port->portnr, PLS_U0);
port->portsc |= PORTSC_PED;
break;
}
@@ -2574,6 +2577,7 @@ static void xhci_port_write(void *ptr, hwaddr reg,
/* overwrite PLS only when LWS=1 */
uint32_t pls = get_field(val, PORTSC_PLS);
set_field(&portsc, pls, PORTSC_PLS);
+ trace_usb_xhci_port_link(port->portnr, pls);
}
/* read/write bits */
portsc &= ~(PORTSC_PP|PORTSC_WCE|PORTSC_WDE|PORTSC_WOE);