Skip to content
Snippets Groups Projects
Commit cc83b272 authored by Harald Welte's avatar Harald Welte Committed by John Rigby
Browse files

fix USB devices with multiple configurations


This patch fixes bugs in usbdcore*.c related to the use of devices
with multiple configurations.

The original code made mistakes about the meaning of configuration value and
configuration index, and the resulting off-by-one errors resulted in:

* SET_CONFIGURATION always selected the first configuration, no matter what
  wValue is being passed.
* GET_DESCRIPTOR/CONFIGURATION always returned the descriptor for the first
  configuration (index 0).

Signed-off-by: default avatarHarald Welte <laforge@openmoko.org>
Acked-by: default avatarMarkus Klotzbuecher <mk@denx.de>
parent 06c53bea
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment