Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ee78bb95 authored by Jiri Slaby's avatar Jiri Slaby Committed by Greg Kroah-Hartman
Browse files

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: default avatarJiri Slaby <jslaby@suse.cz>
Cc: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@kernel.org> [.34, .35]
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent e38018be
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1611,6 +1611,7 @@ static int ntty_install(struct tty_driver *driver, struct tty_struct *tty)
	ret = tty_init_termios(tty);
	if (ret == 0) {
		tty_driver_kref_get(driver);
		tty->count++;
		driver->ttys[tty->index] = tty;
	}
	return ret;