Skip to content

Commit

Permalink
usb: gadget: atmel_usba_udc: Remove unneeded condition
Browse files Browse the repository at this point in the history
The removed condition is always true, since the endpoint descriptor is
set prior to calling the enable endpoint.

Signed-off-by: Ido Shayevitz <idos@codeaurora.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
  • Loading branch information
Ido Shayevitz authored and Felipe Balbi committed Jun 4, 2012
1 parent f8f5701 commit 820234c
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions drivers/usb/gadget/atmel_usba_udc.c
Original file line number Diff line number Diff line change
Expand Up @@ -599,12 +599,6 @@ usba_ep_enable(struct usb_ep *_ep, const struct usb_endpoint_descriptor *desc)

spin_lock_irqsave(&ep->udc->lock, flags);

if (ep->ep.desc) {
spin_unlock_irqrestore(&ep->udc->lock, flags);
DBG(DBG_ERR, "ep%d already enabled\n", ep->index);
return -EBUSY;
}

ep->ep.desc = desc;
ep->ep.maxpacket = maxpacket;

Expand Down

0 comments on commit 820234c

Please sign in to comment.