diff options
author | Oliver Neukum <oliver@neukum.org> | 2006-01-06 22:43:32 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-03-20 14:49:53 -0800 |
commit | d874a2bade6eec21abb30d4822d7b3e43cfbae95 (patch) | |
tree | cc5f677e871ed7b9cd67f48c9896a0b55c72f420 /drivers/usb | |
parent | 17590840dc3c14cb059817466884ac9bd97c4a35 (diff) | |
download | linux-d874a2bade6eec21abb30d4822d7b3e43cfbae95.tar.bz2 |
[PATCH] USB: kzalloc in PhidgetServo
another for kzalloc.
Signed-off-by: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/misc/phidgetservo.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/usb/misc/phidgetservo.c b/drivers/usb/misc/phidgetservo.c index b3418d2bcc69..5a040c205eed 100644 --- a/drivers/usb/misc/phidgetservo.c +++ b/drivers/usb/misc/phidgetservo.c @@ -252,12 +252,11 @@ servo_probe(struct usb_interface *interface, const struct usb_device_id *id) struct usb_device *udev = interface_to_usbdev(interface); struct phidget_servo *dev; - dev = kmalloc(sizeof (struct phidget_servo), GFP_KERNEL); + dev = kzalloc(sizeof (struct phidget_servo), GFP_KERNEL); if (dev == NULL) { dev_err(&interface->dev, "%s - out of memory\n", __FUNCTION__); return -ENOMEM; } - memset(dev, 0x00, sizeof (*dev)); dev->udev = usb_get_dev(udev); dev->type = id->driver_info; |