--- zzzz-none-000/linux-4.9.231/drivers/tty/n_tty.c 2020-07-22 07:10:54.000000000 +0000 +++ falcon-5590-729/linux-4.9.231/drivers/tty/n_tty.c 2022-03-30 12:03:35.000000000 +0000 @@ -2313,6 +2313,12 @@ return retval; } + if (tty->driver->ops->avm_console_enabled) { + if (!tty->driver->ops->avm_console_enabled(tty)) { + return nr; + } + } + down_read(&tty->termios_rwsem); /* Write out any echoed characters that are still pending */