]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/net/wireless/rt2x00/rt2x00queue.c
Merge branch 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes...
[mv-sheeva.git] / drivers / net / wireless / rt2x00 / rt2x00queue.c
index 7e30144c5cfa04189fe94886bc7ded69572aa5a8..e360d287defb01ae61672feae4e3618b3a8bea79 100644 (file)
@@ -804,7 +804,7 @@ static int rt2x00queue_alloc_entries(struct data_queue *queue,
         * Allocate all queue entries.
         */
        entry_size = sizeof(*entries) + qdesc->priv_size;
-       entries = kzalloc(queue->limit * entry_size, GFP_KERNEL);
+       entries = kcalloc(queue->limit, entry_size, GFP_KERNEL);
        if (!entries)
                return -ENOMEM;
 
@@ -937,7 +937,7 @@ int rt2x00queue_allocate(struct rt2x00_dev *rt2x00dev)
         */
        rt2x00dev->data_queues = 2 + rt2x00dev->ops->tx_queues + req_atim;
 
-       queue = kzalloc(rt2x00dev->data_queues * sizeof(*queue), GFP_KERNEL);
+       queue = kcalloc(rt2x00dev->data_queues, sizeof(*queue), GFP_KERNEL);
        if (!queue) {
                ERROR(rt2x00dev, "Queue allocation failed.\n");
                return -ENOMEM;