mirror of https://gitee.com/openkylin/qemu.git
usb-host: trace emulated requests
Add tracepoint to track completion of emulated control requests. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
65bb3a5c11
commit
e382e751ef
|
@ -1035,13 +1035,19 @@ static int usb_host_handle_control(USBDevice *dev, USBPacket *p,
|
|||
|
||||
switch (request) {
|
||||
case DeviceOutRequest | USB_REQ_SET_ADDRESS:
|
||||
return usb_host_set_address(s, value);
|
||||
ret = usb_host_set_address(s, value);
|
||||
trace_usb_host_req_emulated(s->bus_num, s->addr, ret);
|
||||
return ret;
|
||||
|
||||
case DeviceOutRequest | USB_REQ_SET_CONFIGURATION:
|
||||
return usb_host_set_config(s, value & 0xff);
|
||||
ret = usb_host_set_config(s, value & 0xff);
|
||||
trace_usb_host_req_emulated(s->bus_num, s->addr, ret);
|
||||
return ret;
|
||||
|
||||
case InterfaceOutRequest | USB_REQ_SET_INTERFACE:
|
||||
return usb_host_set_interface(s, index, value);
|
||||
ret = usb_host_set_interface(s, index, value);
|
||||
trace_usb_host_req_emulated(s->bus_num, s->addr, ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* The rest are asynchronous */
|
||||
|
|
|
@ -315,6 +315,7 @@ usb_host_release_interfaces(int bus, int addr) "dev %d:%d"
|
|||
usb_host_req_control(int bus, int addr, int req, int value, int index) "dev %d:%d, req 0x%x, value %d, index %d"
|
||||
usb_host_req_data(int bus, int addr, int in, int ep, int size) "dev %d:%d, in %d, ep %d, size %d"
|
||||
usb_host_req_complete(int bus, int addr, int status) "dev %d:%d, status %d"
|
||||
usb_host_req_emulated(int bus, int addr, int status) "dev %d:%d, status %d"
|
||||
usb_host_urb_submit(int bus, int addr, void *aurb, int length, int more) "dev %d:%d, aurb %p, length %d, more %d"
|
||||
usb_host_urb_complete(int bus, int addr, void *aurb, int status, int length, int more) "dev %d:%d, aurb %p, status %d, length %d, more %d"
|
||||
usb_host_ep_set_halt(int bus, int addr, int ep) "dev %d:%d, ep %d"
|
||||
|
|
Loading…
Reference in New Issue