diff options
Diffstat (limited to 'drivers/char/misc.c')
-rw-r--r-- | drivers/char/misc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/char/misc.c b/drivers/char/misc.c index 7a484fc7cb9e..7e975f606924 100644 --- a/drivers/char/misc.c +++ b/drivers/char/misc.c | |||
@@ -199,6 +199,8 @@ int misc_register(struct miscdevice * misc) | |||
199 | dev_t dev; | 199 | dev_t dev; |
200 | int err = 0; | 200 | int err = 0; |
201 | 201 | ||
202 | INIT_LIST_HEAD(&misc->list); | ||
203 | |||
202 | down(&misc_sem); | 204 | down(&misc_sem); |
203 | list_for_each_entry(c, &misc_list, list) { | 205 | list_for_each_entry(c, &misc_list, list) { |
204 | if (c->minor == misc->minor) { | 206 | if (c->minor == misc->minor) { |