fastboot: Add support for alternate interface
Problem: Within a configuration, an interface can have "alternate settings". In this alternate interfaces can be a valid fastboot interface. We currently only look at the default interface which leads to not detecting device properly. Solution: When inspecting a device, also look at the alternative interface. Details: bNumInterfaces field from USB configuration descriptor tells about number of interfaces not about number of interface descriptors within that configuration. It is important to parse all interface descriptors within configuration's wTotalLength, because one interface may have multiple alternate settings. If we found matching fastboot interface which is alternate setting, then we have to switch interface to that setting to be able to use it. Bug: 370465224 Change-Id: I5551c71919e0046f943750a56ce6a89579008461
Loading
Please register or sign in to comment