Add check to Pipe_IsEndpointBound() in the Mass Storage Host mode Class driver to ensure that multiple instances of the driver can be used on a single device with multiple Mass Storage interfaces.
This commit is contained in:
parent
f52b265090
commit
023838fe4a
2 changed files with 6 additions and 2 deletions
|
@ -113,8 +113,11 @@ static uint8_t DComp_NextInterfaceBulkDataEndpoint(void* CurrentDescriptor)
|
|||
uint8_t EndpointType = (DESCRIPTOR_CAST(CurrentDescriptor,
|
||||
USB_Descriptor_Endpoint_t).Attributes & EP_TYPE_MASK);
|
||||
|
||||
if (EndpointType == EP_TYPE_BULK)
|
||||
return DESCRIPTOR_SEARCH_Found;
|
||||
if ((EndpointType == EP_TYPE_BULK) &&
|
||||
(!(Pipe_IsEndpointBound(CurrentEndpoint->EndpointAddress))))
|
||||
{
|
||||
return DESCRIPTOR_SEARCH_Found;
|
||||
}
|
||||
}
|
||||
else if (DESCRIPTOR_TYPE(CurrentDescriptor) == DTYPE_Interface)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue