summaryrefslogtreecommitdiff
path: root/arch/um/drivers/line.c
diff options
context:
space:
mode:
authorAlexander Viro <viro@www.linux.org.uk>2003-04-23 04:18:59 -0700
committerChristoph Hellwig <hch@lst.de>2003-04-23 04:18:59 -0700
commit345127472f366d63f50fdf29b9dd84e70a084bd7 (patch)
treee1f47d76d696923a8c1d8baa05e75f97748fda56 /arch/um/drivers/line.c
parent07462df3687e6a58846911460f4f4833fbe3d587 (diff)
[PATCH] tty cleanups (6/12)
tty->tty_index added; we initialize it with minor(tty->device) - tty->driver->minor_start. Majority of remaining tty->device uses had that form and are switched to use of tty->index.
Diffstat (limited to 'arch/um/drivers/line.c')
-rw-r--r--arch/um/drivers/line.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/um/drivers/line.c b/arch/um/drivers/line.c
index 5d1f9761e591..82b90a0f8dc5 100644
--- a/arch/um/drivers/line.c
+++ b/arch/um/drivers/line.c
@@ -109,7 +109,7 @@ int line_write(struct line *lines, struct tty_struct *tty, int from_user,
buf = new;
}
- i = minor(tty->device) - tty->driver->minor_start;
+ i = tty->index;
line = &lines[i];
down(&line->sem);
@@ -219,7 +219,7 @@ int line_open(struct line *lines, struct tty_struct *tty,
int n, err = 0;
if(tty == NULL) n = 0;
- else n = minor(tty->device) - tty->driver->minor_start;
+ else n = tty->index;
line = &lines[n];
down(&line->sem);
@@ -267,7 +267,7 @@ void line_close(struct line *lines, struct tty_struct *tty)
int n;
if(tty == NULL) n = 0;
- else n = minor(tty->device) - tty->driver->minor_start;
+ else n = tty->index;
line = &lines[n];
down(&line->sem);