diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2011-05-19 08:46:53 +0200 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2011-06-14 12:36:28 +0200 |
commit | dcbd0b5c0ef825c02b443e11f501599d801f396a (patch) | |
tree | d1cf50b7009589efa7fb683cd67c282563ce8c85 /hw/usb-ehci.c | |
parent | 26d53979db57939969efc7c698c2240a89f50648 (diff) | |
download | qemu-dcbd0b5c0ef825c02b443e11f501599d801f396a.zip qemu-dcbd0b5c0ef825c02b443e11f501599d801f396a.tar.gz qemu-dcbd0b5c0ef825c02b443e11f501599d801f396a.tar.bz2 |
usb-ehci: trace port state
Trace usb port operations (attach, detach, reset),
drop a few obsolete DPRINTF's.
No change in behavior.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/usb-ehci.c')
-rw-r--r-- | hw/usb-ehci.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/hw/usb-ehci.c b/hw/usb-ehci.c index 40a447b..85e5ed9 100644 --- a/hw/usb-ehci.c +++ b/hw/usb-ehci.c @@ -604,8 +604,7 @@ static void ehci_attach(USBPort *port) EHCIState *s = port->opaque; uint32_t *portsc = &s->portsc[port->index]; - DPRINTF("ehci_attach invoked for index %d, portsc 0x%x, desc %s\n", - port->index, *portsc, port->dev->product_desc); + trace_usb_ehci_port_attach(port->index, port->dev->product_desc); *portsc |= PORTSC_CONNECT; *portsc |= PORTSC_CSC; @@ -625,8 +624,7 @@ static void ehci_detach(USBPort *port) EHCIState *s = port->opaque; uint32_t *portsc = &s->portsc[port->index]; - DPRINTF("ehci_attach invoked for index %d, portsc 0x%x\n", - port->index, *portsc); + trace_usb_ehci_port_detach(port->index); *portsc &= ~PORTSC_CONNECT; *portsc |= PORTSC_CSC; @@ -733,11 +731,11 @@ static void handle_port_status_write(EHCIState *s, int port, uint32_t val) *portsc &= ~rwc; if ((val & PORTSC_PRESET) && !(*portsc & PORTSC_PRESET)) { - DPRINTF("port_status_write: USBTRAN Port %d reset begin\n", port); + trace_usb_ehci_port_reset(port, 1); } if (!(val & PORTSC_PRESET) &&(*portsc & PORTSC_PRESET)) { - DPRINTF("port_status_write: USBTRAN Port %d reset done\n", port); + trace_usb_ehci_port_reset(port, 0); usb_attach(&s->ports[port], dev); // TODO how to handle reset of ports with no device |