aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorHaavard Skinnemoen <haavard.skinnemoen@atmel.com>2009-05-04 20:22:43 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-05-28 16:54:41 -0400
commitfe92c9e481a147a9e1e14f55870f32903b967777 (patch)
tree1d85176e24445aaabf61ef63bf47ef7905ea2fa8 /drivers/usb
parentf42706c90470851fd2e97eda7a4109e8949bde8a (diff)
USB: atmel_usb_udc: Use kzalloc() to allocate ep structures
This ensures that all fields are properly initialized. Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Acked-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/gadget/atmel_usba_udc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/gadget/atmel_usba_udc.c b/drivers/usb/gadget/atmel_usba_udc.c
index 5644897c1c5d..05c913cc3658 100644
--- a/drivers/usb/gadget/atmel_usba_udc.c
+++ b/drivers/usb/gadget/atmel_usba_udc.c
@@ -1941,7 +1941,7 @@ static int __init usba_udc_probe(struct platform_device *pdev)
1941 usba_writel(udc, CTRL, USBA_DISABLE_MASK); 1941 usba_writel(udc, CTRL, USBA_DISABLE_MASK);
1942 clk_disable(pclk); 1942 clk_disable(pclk);
1943 1943
1944 usba_ep = kmalloc(sizeof(struct usba_ep) * pdata->num_ep, 1944 usba_ep = kzalloc(sizeof(struct usba_ep) * pdata->num_ep,
1945 GFP_KERNEL); 1945 GFP_KERNEL);
1946 if (!usba_ep) 1946 if (!usba_ep)
1947 goto err_alloc_ep; 1947 goto err_alloc_ep;