Skip to content

Commit

Permalink
usb: dwc3: ep0: use proper endianess in SetFeature for wIndex
Browse files Browse the repository at this point in the history
The first access was correct, the second was wrong.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
  • Loading branch information
Sebastian Andrzej Siewior authored and Felipe Balbi committed Dec 12, 2011
1 parent 457d3f2 commit 1e7618d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/usb/dwc3/ep0.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,8 +392,7 @@ static int dwc3_ep0_handle_feature(struct dwc3 *dwc,
case USB_RECIP_ENDPOINT:
switch (wValue) {
case USB_ENDPOINT_HALT:

dep = dwc3_wIndex_to_dep(dwc, ctrl->wIndex);
dep = dwc3_wIndex_to_dep(dwc, wIndex);
if (!dep)
return -EINVAL;
ret = __dwc3_gadget_ep_set_halt(dep, set);
Expand Down

0 comments on commit 1e7618d

Please sign in to comment.