aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/inode.c')
-rw-r--r--drivers/usb/gadget/inode.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/gadget/inode.c b/drivers/usb/gadget/inode.c
index e60745ffaf8e..173004f60fea 100644
--- a/drivers/usb/gadget/inode.c
+++ b/drivers/usb/gadget/inode.c
@@ -964,7 +964,7 @@ static int setup_req (struct usb_ep *ep, struct usb_request *req, u16 len)
964 } 964 }
965 if (len > sizeof (dev->rbuf)) 965 if (len > sizeof (dev->rbuf))
966 req->buf = kmalloc(len, GFP_ATOMIC); 966 req->buf = kmalloc(len, GFP_ATOMIC);
967 if (req->buf == 0) { 967 if (req->buf == NULL) {
968 req->buf = dev->rbuf; 968 req->buf = dev->rbuf;
969 return -ENOMEM; 969 return -ENOMEM;
970 } 970 }
@@ -1394,7 +1394,7 @@ gadgetfs_setup (struct usb_gadget *gadget, const struct usb_ctrlrequest *ctrl)
1394 dev->setup_abort = 0; 1394 dev->setup_abort = 0;
1395 if (dev->state == STATE_DEV_UNCONNECTED) { 1395 if (dev->state == STATE_DEV_UNCONNECTED) {
1396#ifdef CONFIG_USB_GADGET_DUALSPEED 1396#ifdef CONFIG_USB_GADGET_DUALSPEED
1397 if (gadget->speed == USB_SPEED_HIGH && dev->hs_config == 0) { 1397 if (gadget->speed == USB_SPEED_HIGH && dev->hs_config == NULL) {
1398 spin_unlock(&dev->lock); 1398 spin_unlock(&dev->lock);
1399 ERROR (dev, "no high speed config??\n"); 1399 ERROR (dev, "no high speed config??\n");
1400 return -EINVAL; 1400 return -EINVAL;