]>
Commit | Line | Data |
---|---|---|
ac0dd8b4 GKH |
1 | From ee78bb95b7bea08b7774a02073ea2bb45611a9e1 Mon Sep 17 00:00:00 2001 |
2 | From: Jiri Slaby <jslaby@suse.cz> | |
3 | Date: Thu, 29 Jul 2010 11:09:47 +0200 | |
4 | Subject: Char: nozomi, fix tty->count counting | |
5 | ||
6 | From: Jiri Slaby <jslaby@suse.cz> | |
7 | ||
8 | commit ee78bb95b7bea08b7774a02073ea2bb45611a9e1 upstream. | |
9 | ||
10 | Currently ntty_install omits to increment tty count and we get the | |
11 | following warnings: | |
12 | Warning: dev (noz2) tty->count(0) != #fd's(1) in tty_open | |
13 | ||
14 | So to fix that, add one tty->count++ there. | |
15 | ||
16 | Signed-off-by: Jiri Slaby <jslaby@suse.cz> | |
17 | Cc: Alan Cox <alan@linux.intel.com> | |
18 | Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | |
19 | ||
20 | --- | |
21 | drivers/char/nozomi.c | 1 + | |
22 | 1 file changed, 1 insertion(+) | |
23 | ||
24 | --- a/drivers/char/nozomi.c | |
25 | +++ b/drivers/char/nozomi.c | |
26 | @@ -1611,6 +1611,7 @@ static int ntty_install(struct tty_drive | |
27 | ret = tty_init_termios(tty); | |
28 | if (ret == 0) { | |
29 | tty_driver_kref_get(driver); | |
30 | + tty->count++; | |
31 | driver->ttys[tty->index] = tty; | |
32 | } | |
33 | return ret; |