aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/goku_udc.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/goku_udc.c')
-rw-r--r--drivers/usb/gadget/goku_udc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/usb/gadget/goku_udc.c b/drivers/usb/gadget/goku_udc.c
index d6c5f1150ae7..349b8166f34a 100644
--- a/drivers/usb/gadget/goku_udc.c
+++ b/drivers/usb/gadget/goku_udc.c
@@ -1777,14 +1777,13 @@ static int goku_probe(struct pci_dev *pdev, const struct pci_device_id *id)
1777 } 1777 }
1778 1778
1779 /* alloc, and start init */ 1779 /* alloc, and start init */
1780 dev = kmalloc (sizeof *dev, GFP_KERNEL); 1780 dev = kzalloc (sizeof *dev, GFP_KERNEL);
1781 if (dev == NULL){ 1781 if (dev == NULL){
1782 pr_debug("enomem %s\n", pci_name(pdev)); 1782 pr_debug("enomem %s\n", pci_name(pdev));
1783 retval = -ENOMEM; 1783 retval = -ENOMEM;
1784 goto done; 1784 goto done;
1785 } 1785 }
1786 1786
1787 memset(dev, 0, sizeof *dev);
1788 spin_lock_init(&dev->lock); 1787 spin_lock_init(&dev->lock);
1789 dev->pdev = pdev; 1788 dev->pdev = pdev;
1790 dev->gadget.ops = &goku_ops; 1789 dev->gadget.ops = &goku_ops;