mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-27 04:13:53 -06:00
usb/ohci: Move trace point and log ep number to help debugging
Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu> Message-Id: <4e3a05a64b5029a88654eab9a873fb45ac80b1a7.1643117600.git.balaton@eik.bme.hu> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
7c204e9638
commit
6e821e5084
2 changed files with 10 additions and 10 deletions
|
@ -1033,21 +1033,21 @@ static int ohci_service_td(OHCIState *ohci, struct ohci_ed *ed)
|
||||||
ohci->async_td = 0;
|
ohci->async_td = 0;
|
||||||
ohci->async_complete = false;
|
ohci->async_complete = false;
|
||||||
} else {
|
} else {
|
||||||
if (ohci->async_td) {
|
|
||||||
/* ??? The hardware should allow one active packet per
|
|
||||||
endpoint. We only allow one active packet per controller.
|
|
||||||
This should be sufficient as long as devices respond in a
|
|
||||||
timely manner.
|
|
||||||
*/
|
|
||||||
trace_usb_ohci_td_too_many_pending();
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
dev = ohci_find_device(ohci, OHCI_BM(ed->flags, ED_FA));
|
dev = ohci_find_device(ohci, OHCI_BM(ed->flags, ED_FA));
|
||||||
if (dev == NULL) {
|
if (dev == NULL) {
|
||||||
trace_usb_ohci_td_dev_error();
|
trace_usb_ohci_td_dev_error();
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
ep = usb_ep_get(dev, pid, OHCI_BM(ed->flags, ED_EN));
|
ep = usb_ep_get(dev, pid, OHCI_BM(ed->flags, ED_EN));
|
||||||
|
if (ohci->async_td) {
|
||||||
|
/* ??? The hardware should allow one active packet per
|
||||||
|
endpoint. We only allow one active packet per controller.
|
||||||
|
This should be sufficient as long as devices respond in a
|
||||||
|
timely manner.
|
||||||
|
*/
|
||||||
|
trace_usb_ohci_td_too_many_pending(ep->nr);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
usb_packet_setup(&ohci->usb_packet, pid, ep, 0, addr, !flag_r,
|
usb_packet_setup(&ohci->usb_packet, pid, ep, 0, addr, !flag_r,
|
||||||
OHCI_BM(td.flags, TD_DI) == 0);
|
OHCI_BM(td.flags, TD_DI) == 0);
|
||||||
usb_packet_addbuf(&ohci->usb_packet, ohci->usb_buf, pktlen);
|
usb_packet_addbuf(&ohci->usb_packet, ohci->usb_buf, pktlen);
|
||||||
|
|
|
@ -51,7 +51,7 @@ usb_ohci_td_skip_async(void) ""
|
||||||
usb_ohci_td_pkt_hdr(uint32_t addr, int64_t pktlen, int64_t len, const char *s, int flag_r, uint32_t cbp, uint32_t be) " TD @ 0x%.8x %" PRId64 " of %" PRId64 " bytes %s r=%d cbp=0x%.8x be=0x%.8x"
|
usb_ohci_td_pkt_hdr(uint32_t addr, int64_t pktlen, int64_t len, const char *s, int flag_r, uint32_t cbp, uint32_t be) " TD @ 0x%.8x %" PRId64 " of %" PRId64 " bytes %s r=%d cbp=0x%.8x be=0x%.8x"
|
||||||
usb_ohci_td_pkt_short(const char *dir, const char *buf) "%s data: %s"
|
usb_ohci_td_pkt_short(const char *dir, const char *buf) "%s data: %s"
|
||||||
usb_ohci_td_pkt_full(const char *dir, const char *buf) "%s data: %s"
|
usb_ohci_td_pkt_full(const char *dir, const char *buf) "%s data: %s"
|
||||||
usb_ohci_td_too_many_pending(void) ""
|
usb_ohci_td_too_many_pending(int ep) "ep=%d"
|
||||||
usb_ohci_td_packet_status(int status) "status=%d"
|
usb_ohci_td_packet_status(int status) "status=%d"
|
||||||
usb_ohci_ed_read_error(uint32_t addr) "ED read error at 0x%x"
|
usb_ohci_ed_read_error(uint32_t addr) "ED read error at 0x%x"
|
||||||
usb_ohci_ed_pkt(uint32_t cur, int h, int c, uint32_t head, uint32_t tail, uint32_t next) "ED @ 0x%.8x h=%u c=%u\n head=0x%.8x tailp=0x%.8x next=0x%.8x"
|
usb_ohci_ed_pkt(uint32_t cur, int h, int c, uint32_t head, uint32_t tail, uint32_t next) "ED @ 0x%.8x h=%u c=%u\n head=0x%.8x tailp=0x%.8x next=0x%.8x"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue