]> git.baikalelectronics.ru Git - kernel.git/commit
tty: Handle problem if line discipline does not have receive_buf
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 20 Jan 2019 09:46:58 +0000 (10:46 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 21 Jan 2019 16:41:02 +0000 (17:41 +0100)
commit3f19d90db5a7bbec15ed640ede214dca8ee26115
tree04163f2cb58466c7620882f449e0af71ff100bae
parent4c93af6a8bf29b03cd89a3393d352a9399dbe5da
tty: Handle problem if line discipline does not have receive_buf

Some tty line disciplines do not have a receive buf callback, so
properly check for that before calling it.  If they do not have this
callback, just eat the character quietly, as we can't fail this call.

Reported-by: Jann Horn <jannh@google.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/tty_io.c