summaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2019-04-15 19:36:58 +0200
committerFelipe Balbi <felipe.balbi@linux.intel.com>2019-05-03 08:13:47 +0200
commit6574abe69946589bf0f69cf9b32f6a2c71ae764f (patch)
tree011ff7cf6bd66d893a8a33503af2a1571d31bd9b /drivers/usb
parentusb: gadget: fsl: fix link error against usb-gadget module (diff)
downloadlinux-6574abe69946589bf0f69cf9b32f6a2c71ae764f.tar.xz
linux-6574abe69946589bf0f69cf9b32f6a2c71ae764f.zip
USB: UDC: net2280: Remove redundant "if" condition
The net2280 driver includes an unnecessary test for an endpoint's queue being empty. The test is redundant; it sits inside a conditional block of an "if" statement which already tests the endpoint's queue. This patch removes the redundant test. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/gadget/udc/net2280.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/gadget/udc/net2280.c b/drivers/usb/gadget/udc/net2280.c
index 898339e5df10..b17473a00b43 100644
--- a/drivers/usb/gadget/udc/net2280.c
+++ b/drivers/usb/gadget/udc/net2280.c
@@ -1058,7 +1058,7 @@ net2280_queue(struct usb_ep *_ep, struct usb_request *_req, gfp_t gfp_flags)
/* PIO ... stuff the fifo, or unblock it. */
if (ep->is_in)
write_fifo(ep, _req);
- else if (list_empty(&ep->queue)) {
+ else {
u32 s;
/* OUT FIFO might have packet(s) buffered */