diff options
| author | hathach <[email protected]> | 2013-07-01 16:14:46 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2013-07-01 16:14:46 +0700 |
| commit | d8bd749c75fe0a65507b624eba0b5a472225e0c7 (patch) | |
| tree | a218785f9514b7bfda856295da0bdda7ae73ffb6 /tinyusb/host/usbh.c | |
| parent | 3f0d740776ec94ef49da69c94b70eeb1bd81af76 (diff) | |
change control xfer check in usbh_xfer_isr
rename
- async_list_process_isr to async_list_xfer_complete_isr
- period_list_process_isr to period_list_xfer_complete_isr
extract function void qhd_xfer_complete_isr(ehci_qhd_t * p_qhd, tusb_transfer_type_t xfer_type)
Diffstat (limited to 'tinyusb/host/usbh.c')
| -rw-r--r-- | tinyusb/host/usbh.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tinyusb/host/usbh.c b/tinyusb/host/usbh.c index e4c20883b..f5689b07c 100644 --- a/tinyusb/host/usbh.c +++ b/tinyusb/host/usbh.c @@ -239,7 +239,7 @@ tusb_interface_status_t usbh_pipe_status_get(pipe_handle_t pipe_hdl) void usbh_xfer_isr(pipe_handle_t pipe_hdl, uint8_t class_code, tusb_event_t event) { uint8_t class_index = std_class_code_to_index(class_code); - if (class_index == 0) // Control transfer + if (TUSB_XFER_CONTROL == pipe_hdl.xfer_type) { usbh_devices[ pipe_hdl.dev_addr ].control.pipe_status = (event == TUSB_EVENT_XFER_COMPLETE) ? TUSB_INTERFACE_STATUS_COMPLETE : TUSB_INTERFACE_STATUS_ERROR; osal_semaphore_post( usbh_devices[ pipe_hdl.dev_addr ].control.sem_hdl ); @@ -488,7 +488,7 @@ tusb_error_t enumeration_body_subtask(void) static uint8_t class_index; // has to be static as it is used to call class's open_subtask class_index = std_class_code_to_index( ((tusb_descriptor_interface_t*) p_desc)->bInterfaceClass ); - SUBTASK_ASSERT( class_index != 0); // class_index == 0 means corrupted data, abort enumeration + SUBTASK_ASSERT( class_index != 0 ); // class_index == 0 means corrupted data, abort enumeration if (usbh_class_drivers[class_index].open_subtask) // supported class { |
