aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/misc.c')
-rw-r--r--drivers/char/misc.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/char/misc.c b/drivers/char/misc.c
index 96eb2a709e21..71e513771048 100644
--- a/drivers/char/misc.c
+++ b/drivers/char/misc.c
@@ -204,7 +204,7 @@ int misc_register(struct miscdevice * misc)
204{ 204{
205 struct miscdevice *c; 205 struct miscdevice *c;
206 dev_t dev; 206 dev_t dev;
207 int err; 207 int err = 0;
208 208
209 down(&misc_sem); 209 down(&misc_sem);
210 list_for_each_entry(c, &misc_list, list) { 210 list_for_each_entry(c, &misc_list, list) {
@@ -241,13 +241,6 @@ int misc_register(struct miscdevice * misc)
241 goto out; 241 goto out;
242 } 242 }
243 243
244 err = devfs_mk_cdev(dev, S_IFCHR|S_IRUSR|S_IWUSR|S_IRGRP,
245 misc->devfs_name);
246 if (err) {
247 class_device_destroy(misc_class, dev);
248 goto out;
249 }
250
251 /* 244 /*
252 * Add it to the front, so that later devices can "override" 245 * Add it to the front, so that later devices can "override"
253 * earlier defaults 246 * earlier defaults