summaryrefslogtreecommitdiff
path: root/tinyusb/class
diff options
context:
space:
mode:
authorhathach <[email protected]>2018-03-08 11:42:28 +0700
committerhathach <[email protected]>2018-03-08 11:42:28 +0700
commit817f23e5e0f976814dfa0b5ccfa1f9f5cd1c3885 (patch)
tree80ed4682ad3770c22c4677aae19cc004a8091256 /tinyusb/class
parentd28e7e3966bd4ac471b667c73d2cb1451808e641 (diff)
enhance
- add ASSERT_ - rename edpt_equal -
Diffstat (limited to 'tinyusb/class')
-rw-r--r--tinyusb/class/hid/hid_device.c2
-rw-r--r--tinyusb/class/msc/msc_device.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/tinyusb/class/hid/hid_device.c b/tinyusb/class/hid/hid_device.c
index 00fd2660e..5ce98f80a 100644
--- a/tinyusb/class/hid/hid_device.c
+++ b/tinyusb/class/hid/hid_device.c
@@ -308,7 +308,7 @@ tusb_error_t hidd_xfer_cb(endpoint_handle_t edpt_hdl, tusb_event_t event, uint32
for(uint8_t i=0; i<HIDD_NUMBER_OF_SUBCLASS; i++)
{
hidd_interface_t * const p_interface = hidd_class_driver[i].p_interface;
- if ( (p_interface != NULL) && endpointhandle_is_equal(edpt_hdl, p_interface->ept_handle) )
+ if ( (p_interface != NULL) && edpt_equal(edpt_hdl, p_interface->ept_handle) )
{
hidd_class_driver[i].xfer_cb(edpt_hdl.coreid, event, xferred_bytes);
}
diff --git a/tinyusb/class/msc/msc_device.c b/tinyusb/class/msc/msc_device.c
index ac5953662..381bbf07f 100644
--- a/tinyusb/class/msc/msc_device.c
+++ b/tinyusb/class/msc/msc_device.c
@@ -150,14 +150,14 @@ tusb_error_t mscd_xfer_cb(endpoint_handle_t edpt_hdl, tusb_event_t event, uint32
msc_cmd_block_wrapper_t * const p_cbw = &p_msc->cbw;
msc_cmd_status_wrapper_t * const p_csw = &p_msc->csw;
- VERIFY(endpointhandle_is_equal(edpt_hdl, p_msc->edpt_out) || endpointhandle_is_equal(edpt_hdl, p_msc->edpt_in), TUSB_ERROR_INVALID_PARA);
+ VERIFY(edpt_equal(edpt_hdl, p_msc->edpt_out) || edpt_equal(edpt_hdl, p_msc->edpt_in), TUSB_ERROR_INVALID_PARA);
//------------- new CBW received -------------//
if ( !is_waiting_read10_write10 )
{
-// if ( endpointhandle_is_equal(p_msc->edpt_in, edpt_hdl) ) return TUSB_ERROR_NONE; // bulk in interrupt for dcd to clean up
+// if ( edpt_equal(p_msc->edpt_in, edpt_hdl) ) return TUSB_ERROR_NONE; // bulk in interrupt for dcd to clean up
- ASSERT( endpointhandle_is_equal(p_msc->edpt_out, edpt_hdl) &&
+ ASSERT( edpt_equal(p_msc->edpt_out, edpt_hdl) &&
xferred_bytes == sizeof(msc_cmd_block_wrapper_t) &&
event == TUSB_EVENT_XFER_COMPLETE &&
p_cbw->signature == MSC_CBW_SIGNATURE, TUSB_ERROR_INVALID_PARA );