diff options
author | Panagiotis Issaris <takis@issaris.org> | 2006-01-11 16:40:56 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@brturbo.com.br> | 2006-01-11 16:40:56 -0500 |
commit | 7408187d223f63d46a13b6a35b8f96b032c2f623 (patch) | |
tree | 425a459f760295de488f57e3f97b034aaa76a78d /drivers/media/video/cpia_usb.c | |
parent | 0b3af1b6df82cfdb54ae294ed860263011fa0408 (diff) |
V4L/DVB (3344a): Conversions from kmalloc+memset to k(z|c)alloc
Conversions from kmalloc+memset to k(z|c)alloc.
Signed-off-by: Panagiotis Issaris <takis@issaris.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cpia_usb.c')
-rw-r--r-- | drivers/media/video/cpia_usb.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/media/video/cpia_usb.c b/drivers/media/video/cpia_usb.c index 1439cb752874..03275c37c5d3 100644 --- a/drivers/media/video/cpia_usb.c +++ b/drivers/media/video/cpia_usb.c | |||
@@ -499,14 +499,12 @@ static int cpia_probe(struct usb_interface *intf, | |||
499 | 499 | ||
500 | printk(KERN_INFO "USB CPiA camera found\n"); | 500 | printk(KERN_INFO "USB CPiA camera found\n"); |
501 | 501 | ||
502 | ucpia = kmalloc(sizeof(*ucpia), GFP_KERNEL); | 502 | ucpia = kzalloc(sizeof(*ucpia), GFP_KERNEL); |
503 | if (!ucpia) { | 503 | if (!ucpia) { |
504 | printk(KERN_ERR "couldn't kmalloc cpia struct\n"); | 504 | printk(KERN_ERR "couldn't kmalloc cpia struct\n"); |
505 | return -ENOMEM; | 505 | return -ENOMEM; |
506 | } | 506 | } |
507 | 507 | ||
508 | memset(ucpia, 0, sizeof(*ucpia)); | ||
509 | |||
510 | ucpia->dev = udev; | 508 | ucpia->dev = udev; |
511 | ucpia->iface = interface->desc.bInterfaceNumber; | 509 | ucpia->iface = interface->desc.bInterfaceNumber; |
512 | init_waitqueue_head(&ucpia->wq_stream); | 510 | init_waitqueue_head(&ucpia->wq_stream); |