mirror of
https://github.com/torvalds/linux.git
synced 2024-11-07 20:51:47 +00:00
usb: musb: gadget: kill duplicate code in musb_gadget_queue()
musb_gadget_queue() checks for '!req->buf' condition twice: in the second case the code is both duplicated and unreachable as the first check returns early. Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
This commit is contained in:
parent
19aab56c7f
commit
0739702105
@ -1169,8 +1169,6 @@ static int musb_gadget_queue(struct usb_ep *ep, struct usb_request *req,
|
||||
: DMA_FROM_DEVICE);
|
||||
request->mapped = 0;
|
||||
}
|
||||
} else if (!req->buf) {
|
||||
return -ENODATA;
|
||||
} else
|
||||
request->mapped = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user