aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/f_eem.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/f_eem.c')
-rw-r--r--drivers/usb/gadget/f_eem.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/usb/gadget/f_eem.c b/drivers/usb/gadget/f_eem.c
index 1a7b2dd7d408..a9cf20522ffa 100644
--- a/drivers/usb/gadget/f_eem.c
+++ b/drivers/usb/gadget/f_eem.c
@@ -319,10 +319,9 @@ fail:
319 if (f->hs_descriptors) 319 if (f->hs_descriptors)
320 usb_free_descriptors(f->hs_descriptors); 320 usb_free_descriptors(f->hs_descriptors);
321 321
322 /* we might as well release our claims on endpoints */ 322 if (eem->port.out_ep)
323 if (eem->port.out_ep->desc)
324 eem->port.out_ep->driver_data = NULL; 323 eem->port.out_ep->driver_data = NULL;
325 if (eem->port.in_ep->desc) 324 if (eem->port.in_ep)
326 eem->port.in_ep->driver_data = NULL; 325 eem->port.in_ep->driver_data = NULL;
327 326
328 ERROR(cdev, "%s: can't bind, err %d\n", f->name, status); 327 ERROR(cdev, "%s: can't bind, err %d\n", f->name, status);