summaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorDavid Vrabel <dv02@dv02pc01.europe.root.pri>2008-10-15 14:50:10 +0100
committerDavid Vrabel <dv02@dv02pc01.europe.root.pri>2008-10-15 14:50:10 +0100
commit92c4d9bd1648b3eaca6b8b8f8932eec390ba7327 (patch)
tree86e696c08aca7d30284319f1f6adabeeeace1f18 /drivers/usb
parent45c16cd9287819cf1c870f2d8e7738c4c90512ca (diff)
downloadop-kernel-dev-92c4d9bd1648b3eaca6b8b8f8932eec390ba7327.zip
op-kernel-dev-92c4d9bd1648b3eaca6b8b8f8932eec390ba7327.tar.gz
uwb: use kcalloc where appropriate
Signed-off-by: David Vrabel <david.vrabel@csr.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/wusbcore/mmc.c2
-rw-r--r--drivers/usb/wusbcore/wa-xfer.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/wusbcore/mmc.c b/drivers/usb/wusbcore/mmc.c
index e5390b7..7690728 100644
--- a/drivers/usb/wusbcore/mmc.c
+++ b/drivers/usb/wusbcore/mmc.c
@@ -43,7 +43,7 @@
int wusbhc_mmcie_create(struct wusbhc *wusbhc)
{
u8 mmcies = wusbhc->mmcies_max;
- wusbhc->mmcie = kzalloc(mmcies * sizeof(wusbhc->mmcie[0]), GFP_KERNEL);
+ wusbhc->mmcie = kcalloc(mmcies, sizeof(wusbhc->mmcie[0]), GFP_KERNEL);
if (wusbhc->mmcie == NULL)
return -ENOMEM;
mutex_init(&wusbhc->mmcie_mutex);
diff --git a/drivers/usb/wusbcore/wa-xfer.c b/drivers/usb/wusbcore/wa-xfer.c
index 7d192f3..c038635 100644
--- a/drivers/usb/wusbcore/wa-xfer.c
+++ b/drivers/usb/wusbcore/wa-xfer.c
@@ -674,7 +674,7 @@ static int __wa_xfer_setup_segs(struct wa_xfer *xfer, size_t xfer_hdr_size)
size_t buf_itr, buf_size, buf_itr_size;
result = -ENOMEM;
- xfer->seg = kzalloc(xfer->segs * sizeof(xfer->seg[0]), GFP_ATOMIC);
+ xfer->seg = kcalloc(xfer->segs, sizeof(xfer->seg[0]), GFP_ATOMIC);
if (xfer->seg == NULL)
goto error_segs_kzalloc;
buf_itr = 0;
OpenPOWER on IntegriCloud