EZ-Host/OTG:  On a single SIE, portA device has priority for scheduling over portB

Question: As host, EZ-Host/OTG has two bulk devices connected to a single SIE. Why doesn't EZ-Host/OTG ever send requests to the second device on port B?



The device in portA has priority for scheduling. If the portA device NAKs a bulk request, the host will immediately retry the request to that device. EZ-Host/OTG will continue sending the request to the portA device for the entire frame as long as the portA device continues to NAK it. Under this condition, the portB device will never be sent a request in that frame.
The same condition can occur for a single device with multiple bulk endpoints defined.
One way around this is at the end of the frame during EOT, change the priority of the ports (change priority in sh_schedule_trans for Linux OTG driver). However, this approach may slow throughput for some conditions. Alternatively, the BIOS could be changed to move retried requests to the end of the frame, after all other requests.