diff options
author | Jiri Slaby <jslaby@suse.cz> | 2010-07-29 05:09:47 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-08-10 16:47:46 -0400 |
commit | ee78bb95b7bea08b7774a02073ea2bb45611a9e1 (patch) | |
tree | 76c0cf55276de4213d340afc92175e152f0afa0e /drivers/char/nozomi.c | |
parent | e38018be3e7c03dd7e8f4ab0e1d55407cebbf89d (diff) |
Char: nozomi, fix tty->count counting
Currently ntty_install omits to increment tty count and we get the
following warnings:
Warning: dev (noz2) tty->count(0) != #fd's(1) in tty_open
So to fix that, add one tty->count++ there.
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@kernel.org> [.34, .35]
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/char/nozomi.c')
-rw-r--r-- | drivers/char/nozomi.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/char/nozomi.c b/drivers/char/nozomi.c index a6638003f530..21ae1b158b3b 100644 --- a/drivers/char/nozomi.c +++ b/drivers/char/nozomi.c | |||
@@ -1611,6 +1611,7 @@ static int ntty_install(struct tty_driver *driver, struct tty_struct *tty) | |||
1611 | ret = tty_init_termios(tty); | 1611 | ret = tty_init_termios(tty); |
1612 | if (ret == 0) { | 1612 | if (ret == 0) { |
1613 | tty_driver_kref_get(driver); | 1613 | tty_driver_kref_get(driver); |
1614 | tty->count++; | ||
1614 | driver->ttys[tty->index] = tty; | 1615 | driver->ttys[tty->index] = tty; |
1615 | } | 1616 | } |
1616 | return ret; | 1617 | return ret; |