when there are no entries, the return path calls OS_Mutex_unlock instead of OS_Unlock() used in the success return path.
/* This function can be called from any context, and it needs mutual
exclusion with itself.*/
OS_Lock();
/* Get a transfer descriptor for the specified endpoint
** and direction
*/
if (!usb_dev_ptr->xd_entries)
{
OS_Mutex_unlock(usb_dev_ptr->mutex);
return USBERR_DEVICE_BUSY;
}
已解决! 转到解答。
Hi Chris,
It is a known issue, the correct code should be:
if (!usb_dev_ptr->xd_entries)
{
OS_Unlock();
return USBERR_DEVICE_BUSY;
}
The fixed code will be released at this December.
Thank you.
Wish it helps.
best regards
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Chris,
It is a known issue, the correct code should be:
if (!usb_dev_ptr->xd_entries)
{
OS_Unlock();
return USBERR_DEVICE_BUSY;
}
The fixed code will be released at this December.
Thank you.
Wish it helps.
best regards
Ma Hui
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
It wasn't known to me. Is there a public list?
This is the type of bug that can cause a significant amount of wasted debug time. Please impress on the appropriate team that the errta needs be kept up to date.