diff options
Diffstat (limited to 'fs/proc/proc_tty.c')
-rw-r--r-- | fs/proc/proc_tty.c | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/fs/proc/proc_tty.c b/fs/proc/proc_tty.c index 4b4ca41b8..e241c938e 100644 --- a/fs/proc/proc_tty.c +++ b/fs/proc/proc_tty.c @@ -161,10 +161,9 @@ void proc_tty_unregister_driver(struct tty_driver *driver) if (!ent) return; - proc_unregister(proc_tty_driver, ent->low_ino); + remove_proc_entry(driver->driver_name, proc_tty_driver); driver->proc_entry = 0; - kfree(ent); } /* @@ -172,18 +171,11 @@ void proc_tty_unregister_driver(struct tty_driver *driver) */ void __init proc_tty_init(void) { - struct proc_dir_entry *ent; - - ent = create_proc_entry("tty", S_IFDIR, 0); - if (!ent) + if (!proc_mkdir("tty", 0)) return; - proc_tty_ldisc = create_proc_entry("tty/ldisc", S_IFDIR, 0); - proc_tty_driver = create_proc_entry("tty/driver", S_IFDIR, 0); + proc_tty_ldisc = proc_mkdir("tty/ldisc", 0); + proc_tty_driver = proc_mkdir("tty/driver", 0); - ent = create_proc_entry("tty/ldiscs", 0, 0); - ent->read_proc = tty_ldiscs_read_proc; - - ent = create_proc_entry("tty/drivers", 0, 0); - ent->read_proc = tty_drivers_read_proc; + create_proc_read_entry("tty/ldiscs", 0, 0, tty_ldiscs_read_proc,NULL); + create_proc_read_entry("tty/drivers", 0, 0, tty_drivers_read_proc,NULL); } - |