usb: gadget: mv_udc: remove unneeded NULL check
Subsystems (2)
PATCH 1/1 usb: gadget: mv_udc: remove unneeded NULL check
We've dereferenced req already, and we checked for bogus parameters at the start of the function.
Signed-off-by Dan Carpenter <[email protected]>
drivers/usb/gadget/mv_udc_core.c +1 -2
@@ -771,8 +771,7 @@ mv_ep_queue(struct usb_ep *_ep, struct usb_request *_req, gfp_t gfp_flags) udc->ep0_state =DATA_STATE_XMIT ;/* irq handler advances the queue */ -if (req !=NULL ) -list_add_tail (&req->queue, &ep->queue); +list_add_tail (&req->queue, &ep->queue);spin_unlock_irqrestore (&udc->lock, flags);return 0 ;
Felipe Balbi
AppliedQuoted 4 lines · Dan Carpenter
We've dereferenced req already, and we checked for bogus parameters at the start of the function.
Signed-off-by Dan Carpenter <[email protected]>
applied, thanks
Signature · 1 line
balbi