aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/net/zd1201.c
diff options
context:
space:
mode:
authorEric Sesterhenn <snakebyte@gmx.de>2006-02-27 15:29:43 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2006-03-20 17:49:59 -0500
commit80b6ca48321974a6566a1c9048ba34f60420bca6 (patch)
treea350e3cf6b794081c13c89d5b1913b2c1207570d /drivers/usb/net/zd1201.c
parentd54a5cb6484705f7808b337917cc7598f2f971c3 (diff)
[PATCH] USB: kzalloc() conversion for rest of drivers/usb
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/net/zd1201.c')
-rw-r--r--drivers/usb/net/zd1201.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/usb/net/zd1201.c b/drivers/usb/net/zd1201.c
index f3a8e2807c3b..fe9b60cd8d95 100644
--- a/drivers/usb/net/zd1201.c
+++ b/drivers/usb/net/zd1201.c
@@ -621,10 +621,9 @@ static int zd1201_drvr_start(struct zd1201 *zd)
621 __le16 zdmax; 621 __le16 zdmax;
622 unsigned char *buffer; 622 unsigned char *buffer;
623 623
624 buffer = kmalloc(ZD1201_RXSIZE, GFP_KERNEL); 624 buffer = kzalloc(ZD1201_RXSIZE, GFP_KERNEL);
625 if (!buffer) 625 if (!buffer)
626 return -ENOMEM; 626 return -ENOMEM;
627 memset(buffer, 0, ZD1201_RXSIZE);
628 627
629 usb_fill_bulk_urb(zd->rx_urb, zd->usb, 628 usb_fill_bulk_urb(zd->rx_urb, zd->usb,
630 usb_rcvbulkpipe(zd->usb, zd->endp_in), buffer, ZD1201_RXSIZE, 629 usb_rcvbulkpipe(zd->usb, zd->endp_in), buffer, ZD1201_RXSIZE,
@@ -1750,11 +1749,9 @@ static int zd1201_probe(struct usb_interface *interface,
1750 1749
1751 usb = interface_to_usbdev(interface); 1750 usb = interface_to_usbdev(interface);
1752 1751
1753 zd = kmalloc(sizeof(struct zd1201), GFP_KERNEL); 1752 zd = kzalloc(sizeof(struct zd1201), GFP_KERNEL);
1754 if (!zd) { 1753 if (!zd)
1755 return -ENOMEM; 1754 return -ENOMEM;
1756 }
1757 memset(zd, 0, sizeof(struct zd1201));
1758 zd->ap = ap; 1755 zd->ap = ap;
1759 zd->usb = usb; 1756 zd->usb = usb;
1760 zd->removed = 0; 1757 zd->removed = 0;