diff options
| author | Kumar Gala <galak@kernel.crashing.org> | 2006-04-05 01:10:34 +0400 |
|---|---|---|
| committer | Kumar Gala <galak@kernel.crashing.org> | 2006-04-05 01:10:34 +0400 |
| commit | 12df7556705aae97f24a397377e17898700d7192 (patch) | |
| tree | 5adc6b1c2aa940263ee2e88fc6645918533da539 /drivers/input/evdev.c | |
| parent | 34ddf733c415a8e336c996a4303d9f336e0c81b5 (diff) | |
| parent | 6246b6128bbe34d0752f119cf7c5111c85fe481d (diff) | |
| download | linux-12df7556705aae97f24a397377e17898700d7192.tar.xz | |
Merge branch 'master'
Diffstat (limited to 'drivers/input/evdev.c')
| -rw-r--r-- | drivers/input/evdev.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index 745979f33dc2..a34e3d91d9ed 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c @@ -130,9 +130,8 @@ static int evdev_open(struct inode * inode, struct file * file) if ((accept_err = input_accept_process(&(evdev_table[i]->handle), file))) return accept_err; - if (!(list = kmalloc(sizeof(struct evdev_list), GFP_KERNEL))) + if (!(list = kzalloc(sizeof(struct evdev_list), GFP_KERNEL))) return -ENOMEM; - memset(list, 0, sizeof(struct evdev_list)); list->evdev = evdev_table[i]; list_add_tail(&list->node, &evdev_table[i]->list); @@ -609,9 +608,8 @@ static struct input_handle *evdev_connect(struct input_handler *handler, struct return NULL; } - if (!(evdev = kmalloc(sizeof(struct evdev), GFP_KERNEL))) + if (!(evdev = kzalloc(sizeof(struct evdev), GFP_KERNEL))) return NULL; - memset(evdev, 0, sizeof(struct evdev)); INIT_LIST_HEAD(&evdev->list); init_waitqueue_head(&evdev->wait); |
