Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1cfb9c94 authored by vignesh babu's avatar vignesh babu Committed by Tony Luck
Browse files

[IA64-SN2][KJ] mmtimer.c-kzalloc



Replacing kmalloc/memset combination with kzalloc.

Signed-off-by: default avatarvignesh babu <vignesh.babu@wipro.com>
Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent 66761522
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -705,15 +705,13 @@ static int __init mmtimer_init(void)
	maxn++;

	/* Allocate list of node ptrs to mmtimer_t's */
	timers = kmalloc(sizeof(mmtimer_t *)*maxn, GFP_KERNEL);
	timers = kzalloc(sizeof(mmtimer_t *)*maxn, GFP_KERNEL);
	if (timers == NULL) {
		printk(KERN_ERR "%s: failed to allocate memory for device\n",
				MMTIMER_NAME);
		goto out3;
	}

	memset(timers,0,(sizeof(mmtimer_t *)*maxn));

	/* Allocate mmtimer_t's for each online node */
	for_each_online_node(node) {
		timers[node] = kmalloc_node(sizeof(mmtimer_t)*NUM_COMPARATORS, GFP_KERNEL, node);