summaryrefslogtreecommitdiff
path: root/src/host
diff options
context:
space:
mode:
authorhathach <[email protected]>2023-08-27 23:45:34 +0700
committerhathach <[email protected]>2023-08-27 23:45:34 +0700
commit502b1bdda62f0f207d9a51daf134574e455f3aa2 (patch)
treef93c491346f05d14c841035e511186bae531a13b /src/host
parentcd7464a8847db5efa14f568bdf8746d898fc7eb4 (diff)
more update to transaction
Diffstat (limited to 'src/host')
-rw-r--r--src/host/hcd.h4
-rw-r--r--src/host/usbh.c1
2 files changed, 3 insertions, 2 deletions
diff --git a/src/host/hcd.h b/src/host/hcd.h
index 1f01a1a2f..e25b20ea3 100644
--- a/src/host/hcd.h
+++ b/src/host/hcd.h
@@ -39,7 +39,7 @@
// Configuration
//--------------------------------------------------------------------+
-// Max number of endpoints per device
+// Max number of endpoints pair per device
// TODO optimize memory usage
#ifndef CFG_TUH_ENDPOINT_MAX
#define CFG_TUH_ENDPOINT_MAX 16
@@ -167,7 +167,7 @@ void hcd_device_close(uint8_t rhport, uint8_t dev_addr);
//--------------------------------------------------------------------+
// Open an endpoint
-bool hcd_edpt_open(uint8_t rhport, uint8_t dev_addr, tusb_desc_endpoint_t const * ep_desc);
+bool hcd_edpt_open(uint8_t rhport, uint8_t daddr, tusb_desc_endpoint_t const * ep_desc);
// Submit a transfer, when complete hcd_event_xfer_complete() must be invoked
bool hcd_edpt_xfer(uint8_t rhport, uint8_t daddr, uint8_t ep_addr, uint8_t * buffer, uint16_t buflen);
diff --git a/src/host/usbh.c b/src/host/usbh.c
index 7a09f5b6e..12a7f5839 100644
--- a/src/host/usbh.c
+++ b/src/host/usbh.c
@@ -919,6 +919,7 @@ TU_ATTR_FAST_FUNC void hcd_event_handler(hcd_event_t const* event, bool in_isr)
switch (event->event_id)
{
// case HCD_EVENT_DEVICE_REMOVE:
+// // FIXME device remove from a hub need an HCD API for hcd to free up endpoint
// // mark device as removing to prevent further xfer before the event is processed in usbh task
// break;