diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2020-02-18 12:42:57 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2020-05-29 11:03:03 -0400 |
commit | 1a4b8febb6c13766f1af91058b90fee876e11674 (patch) | |
tree | d7e5c3a6c5aa7b3ff5f36a459d9e7ede9186228a /drivers/tty/n_hdlc.c | |
parent | 00fca6b53a88f600c59bae3828e1c2fdce58be0d (diff) | |
download | linux-1a4b8febb6c13766f1af91058b90fee876e11674.tar.bz2 |
n_hdlc_tty_read(): remove pointless access_ok()
only copy_to_user() is done to the address in question
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/tty/n_hdlc.c')
-rw-r--r-- | drivers/tty/n_hdlc.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/tty/n_hdlc.c b/drivers/tty/n_hdlc.c index 991f49ee4026..b09eac4b6d64 100644 --- a/drivers/tty/n_hdlc.c +++ b/drivers/tty/n_hdlc.c @@ -423,13 +423,6 @@ static ssize_t n_hdlc_tty_read(struct tty_struct *tty, struct file *file, struct n_hdlc_buf *rbuf; DECLARE_WAITQUEUE(wait, current); - /* verify user access to buffer */ - if (!access_ok(buf, nr)) { - pr_warn("%s(%d) %s() can't verify user buffer\n", - __FILE__, __LINE__, __func__); - return -EFAULT; - } - add_wait_queue(&tty->read_wait, &wait); for (;;) { |