]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/char/mmtimer.c
[S390] cio: change confusing message in cmf.
[linux-2.6-omap-h63xx.git] / drivers / char / mmtimer.c
index c09160383a5332c9635c4813215dabd9063bade8..e60a74c66e3dfa05c00eb45596829e77932ce5c1 100644 (file)
@@ -25,6 +25,7 @@
 #include <linux/init.h>
 #include <linux/errno.h>
 #include <linux/mm.h>
+#include <linux/fs.h>
 #include <linux/mmtimer.h>
 #include <linux/miscdevice.h>
 #include <linux/posix-timers.h>
@@ -705,15 +706,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);