refractor remove tusbh_msc_is_failed
increase usbh enum task from 150 to 200 due to stack overflow when mounting msc device added task for msc host freeRTOS with stack = 300 (still cannot execute copy command)
This commit is contained in:
9
vendor/fatfs/diskio.c
vendored
9
vendor/fatfs/diskio.c
vendored
@@ -59,16 +59,13 @@ static DSTATUS disk_state[TUSB_CFG_HOST_DEVICE_MAX];
|
||||
//--------------------------------------------------------------------+
|
||||
static DRESULT wait_for_io_complete(uint8_t usb_addr)
|
||||
{
|
||||
#if TUSB_CFG_OS == TUSB_OS_NONE
|
||||
// TODO with RTOS, this should use semaphore instead of blocking
|
||||
while ( tusbh_msc_is_busy(usb_addr) )
|
||||
{
|
||||
// timeout here
|
||||
// TODO should have timeout here
|
||||
}
|
||||
return tusbh_msc_is_failed(usb_addr) ? RES_ERROR : RES_OK;
|
||||
#else
|
||||
#error semaphore instead of blocking
|
||||
#endif
|
||||
|
||||
return RES_OK;
|
||||
}
|
||||
|
||||
void diskio_init(void)
|
||||
|
||||
Reference in New Issue
Block a user