public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Al Viro <viro@ZenIV.linux.org.uk>
Cc: Adam Borowski <kilobyte@angband.pl>, Jiri Slaby <jslaby@suse.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/5] vt: get rid of worst cases of __put_user/__get_user
Date: Fri, 9 Jun 2017 11:18:55 +0200	[thread overview]
Message-ID: <20170609091855.GA15474@kroah.com> (raw)
In-Reply-To: <20170605061350.GR6365@ZenIV.linux.org.uk>

On Mon, Jun 05, 2017 at 07:13:50AM +0100, Al Viro wrote:
> On Sun, Jun 04, 2017 at 12:42:52AM +0900, Greg Kroah-Hartman wrote:
> > On Sat, Jun 03, 2017 at 09:32:55AM +0200, Adam Borowski wrote:
> > > Hi!
> > > In a recent discussion, Linus and Al Viro said quite a bit of expletives
> > > about __put_user() and __get_user(), that it's a bad interface that's
> > > almost always the wrong thing to use:
> > > https://marc.info/?l=linux-kernel&m=149463725626316&w=2
> > > https://marc.info/?l=linux-kernel&m=149465866929092&w=2
> > > 
> > > Here's a few patches applying the lessons from that discussion to vt.
> > > None of the uses is performance-critical, but at least we get a nice bit
> > > of code simplification.  And, it's a start of manual review + conversion
> > > that Al Viro wants.
> > 
> > Ah, nice work, at first glance these all look good to me.  I'll queue
> > them up on Monday.
> 
> Could you put that into a separate no-rebase branch?  Or I could do that
> in vfs.git, for that matter...

Yes, here's a tag/branch for you to pull from that will not go away
until 4.13-rc1.


The following changes since commit 3c2993b8c6143d8a5793746a54eba8f86f95240f:

  Linux 4.12-rc4 (2017-06-04 16:47:43 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git/ tags/vt_copy_cleanup_tag

for you to fetch changes up to f8564c93e0907651e21d586920e629227bb0d024:

  vt: drop access_ok() calls in unimap ioctls (2017-06-09 11:07:36 +0200)

----------------------------------------------------------------
vt: copy/from_to cleanup for vt code for Al to pull from.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

----------------------------------------------------------------
Adam Borowski (5):
      vt: use copy_from/to_user instead of __get/put_user for scrnmap ioctls
      vt: fix unchecked __put_user() in tioclinux ioctls
      vt: use copy_to_user instead of __put_user in GIO_UNIMAP ioctl
      vt: use memdup_user in PIO_UNIMAP ioctl
      vt: drop access_ok() calls in unimap ioctls

 drivers/tty/vt/consolemap.c | 56 +++++++++++++--------------------------------
 drivers/tty/vt/vt.c         |  6 ++---
 drivers/tty/vt/vt_ioctl.c   |  8 -------
 3 files changed, 19 insertions(+), 51 deletions(-)

      parent reply	other threads:[~2017-06-09  9:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-03  7:32 [PATCH 0/5] vt: get rid of worst cases of __put_user/__get_user Adam Borowski
2017-06-03  7:35 ` [PATCH 1/5] vt: use copy_from/to_user instead of __get/put_user for scrnmap ioctls Adam Borowski
2017-06-03  7:35   ` [PATCH 2/5] vt: fix unchecked __put_user() in tioclinux ioctls Adam Borowski
2017-06-03  7:35   ` [PATCH 3/5] vt: use copy_to_user instead of __put_user in GIO_UNIMAP ioctl Adam Borowski
2017-06-05 16:34     ` Alan Cox
2017-06-05 23:05       ` Al Viro
2017-06-03  7:35   ` [PATCH 4/5] vt: use memdup_user in PIO_UNIMAP ioctl Adam Borowski
2017-06-03  7:35   ` [PATCH 5/5] vt: drop access_ok() calls in unimap ioctls Adam Borowski
2017-06-03 15:42 ` [PATCH 0/5] vt: get rid of worst cases of __put_user/__get_user Greg Kroah-Hartman
2017-06-05  6:13   ` Al Viro
2017-06-05  6:41     ` Greg Kroah-Hartman
2017-06-09  9:18     ` Greg Kroah-Hartman [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170609091855.GA15474@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=jslaby@suse.com \
    --cc=kilobyte@angband.pl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@ZenIV.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox