aboutsummaryrefslogtreecommitdiffstats
path: root/fs/proc/proc_tty.c
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2009-03-31 18:19:25 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-01 11:59:10 -0400
commit0f043a81ebe84be3576667f04fdda481609e3816 (patch)
treec54a9ac4a1dc79bd5f2f7ec3ead5aa48802ff7a3 /fs/proc/proc_tty.c
parent140716934f67a9b28c3f7032c07c20c746d97a31 (diff)
proc tty: remove struct tty_operations::read_proc
struct tty_operations::proc_fops took it's place and there is one less create_proc_read_entry() user now! Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/proc/proc_tty.c')
-rw-r--r--fs/proc/proc_tty.c18
1 files changed, 4 insertions, 14 deletions
diff --git a/fs/proc/proc_tty.c b/fs/proc/proc_tty.c
index 854827b1d463..83adcc869437 100644
--- a/fs/proc/proc_tty.c
+++ b/fs/proc/proc_tty.c
@@ -144,22 +144,12 @@ void proc_tty_register_driver(struct tty_driver *driver)
144{ 144{
145 struct proc_dir_entry *ent; 145 struct proc_dir_entry *ent;
146 146
147 if (!driver->driver_name || driver->proc_entry) 147 if (!driver->driver_name || driver->proc_entry ||
148 !driver->ops->proc_fops)
148 return; 149 return;
149 150
150 if (driver->ops->proc_fops) { 151 ent = proc_create_data(driver->driver_name, 0, proc_tty_driver,
151 ent = proc_create_data(driver->driver_name, 0, proc_tty_driver, 152 driver->ops->proc_fops, driver);
152 driver->ops->proc_fops, driver);
153 if (!ent)
154 return;
155 } else if (driver->ops->read_proc) {
156 ent = create_proc_entry(driver->driver_name, 0, proc_tty_driver);
157 if (!ent)
158 return;
159 ent->read_proc = driver->ops->read_proc;
160 ent->data = driver;
161 } else
162 return;
163 driver->proc_entry = ent; 153 driver->proc_entry = ent;
164} 154}
165 155