add usbd_control_xfer_substak
seperate control xfer Data and Status phase
This commit is contained in:
@@ -106,13 +106,13 @@
|
||||
#define VERIFY_STS_HDLR_2ARGS(sts, _handler) \
|
||||
do { \
|
||||
uint32_t _status = (uint32_t)(sts); \
|
||||
if ( 0 != _status ) { _VERIFY_MESS(_status) _handler; return _status; }\
|
||||
if ( 0 != _status ) { tusb_hal_dbg_breakpoint(); _VERIFY_MESS(_status) _handler; return _status; }\
|
||||
} while(0)
|
||||
|
||||
#define VERIFY_STS_HDLR_3ARGS(sts, _handler, _error) \
|
||||
do { \
|
||||
uint32_t _status = (uint32_t)(sts); \
|
||||
if ( 0 != _status ) { _VERIFY_MESS(_status) _handler; return _error; }\
|
||||
if ( 0 != _status ) { tusb_hal_dbg_breakpoint(); _VERIFY_MESS(_status) _handler; return _error; }\
|
||||
} while(0)
|
||||
|
||||
#define VERIFY_STATUS_HDLR(...) GET_4TH_ARG(__VA_ARGS__, VERIFY_STS_HDLR_3ARGS, VERIFY_STS_HDLR_2ARGS)(__VA_ARGS__)
|
||||
|
Reference in New Issue
Block a user