Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1345549

Re: [PATCH for-4.5] arm/kvm: fix ioctl error handling

From Christoffer Dall <christoffer.dall@linaro.org>
Newsgroups linux.kernel
Subject Re: [PATCH for-4.5] arm/kvm: fix ioctl error handling
Date 2016-02-29 09:30 +0100
Message-ID <r7rnk-x2-5@gated-at.bofh.it> (permalink)
References <r7bBU-4yM-15@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sun, Feb 28, 2016 at 05:32:07PM +0200, Michael S. Tsirkin wrote:
> Calling return copy_to_user(...) in an ioctl will not
> do the right thing if there's a pagefault:
> copy_to_user returns the number of bytes not copied
> in this case.
> 
> Fix up kvm to do
> 	return copy_to_user(...)) ?  -EFAULT : 0;
> 
> everywhere.
> 
> Cc: stable@vger.kernel.org
> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>

Acked-by: Christoffer Dall <christoffer.dall@linaro.org>

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH for-4.5] arm/kvm: fix ioctl error handling "Michael S. Tsirkin" <mst@redhat.com> - 2016-02-28 16:40 +0100
  Re: [PATCH for-4.5] arm/kvm: fix ioctl error handling Christoffer Dall <christoffer.dall@linaro.org> - 2016-02-29 09:30 +0100

csiph-web