diff options
author | Oliver Neukum <oliver@neukum.org> | 2005-10-24 22:42:35 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-10-28 16:47:49 -0700 |
commit | 46f116eab81b21c6ae8c4f169498c632b1f94bf1 (patch) | |
tree | b5165e2e57748140be4dc3fbf7063fdba721c26c /drivers/usb/class | |
parent | eb3c5ed8617d0aa67648cb7d1a486d14099129f2 (diff) |
[PATCH] USB: cdc-acm patch to use kzalloc
another one to use kzalloc. Please apply.
Signed-off-by: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/class')
-rw-r--r-- | drivers/usb/class/cdc-acm.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c index 16ecad30e29c..1b4751412970 100644 --- a/drivers/usb/class/cdc-acm.c +++ b/drivers/usb/class/cdc-acm.c @@ -827,11 +827,10 @@ skip_normal_probe: return -ENODEV; } - if (!(acm = kmalloc(sizeof(struct acm), GFP_KERNEL))) { - dev_dbg(&intf->dev, "out of memory (acm kmalloc)\n"); + if (!(acm = kzalloc(sizeof(struct acm), GFP_KERNEL))) { + dev_dbg(&intf->dev, "out of memory (acm kzalloc)\n"); goto alloc_fail; } - memset(acm, 0, sizeof(struct acm)); ctrlsize = le16_to_cpu(epctrl->wMaxPacketSize); readsize = le16_to_cpu(epread->wMaxPacketSize); |