usb: gadget: udc: remove bogus NULL check
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 25 Nov 2014 15:56:22 +0000 (18:56 +0300)
committerFelipe Balbi <balbi@ti.com>
Mon, 12 Jan 2015 18:13:26 +0000 (12:13 -0600)
"ep" isn't NULL here, and static checkers complain because we
dereferenced it on the previous line.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/udc/bdc/bdc_ep.c

index ebf82bd050cf47e286f1e50963f1f739c026e1fc..fdc0e9fc39d0ba55c7f0c30d98a6f16a2c1f4b82 100644 (file)
@@ -719,7 +719,7 @@ static int ep_queue(struct bdc_ep *ep, struct bdc_req *req)
        int ret = 0;
 
        bdc = ep->bdc;
-       if (!req || !ep || !ep->usb_ep.desc)
+       if (!req || !ep->usb_ep.desc)
                return -EINVAL;
 
        req->usb_req.actual = 0;