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


Groups > linux.kernel > #1485387

Re: Runtime failure running sh:qemu in -next due to 'sh: fix copy_from_user()'

From Al Viro <viro@ZenIV.linux.org.uk>
Newsgroups linux.kernel
Subject Re: Runtime failure running sh:qemu in -next due to 'sh: fix copy_from_user()'
Date 2016-09-16 23:30 +0200
Message-ID <si8RP-1P5-5@gated-at.bofh.it> (permalink)
References <si6Q2-uW-19@gated-at.bofh.it> <si7Cq-13S-27@gated-at.bofh.it> <si85r-1i1-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Sep 16, 2016 at 01:32:05PM -0700, Guenter Roeck wrote:
> > BTW, could you post your .config and information about your userland?  E.g.
> > is that ip(8) a busybox one, etc.  If it's busybox, this smells like EINVAL
> > and EFAULT resp. coming from recvmsg() on netlink sockets, with nothing
> > extraordinary in iovecs, AFAICS...
> 
> Please see https://github.com/groeck/linux-build-test/tree/master/rootfs/sh.
> The rootfs is some three years old. I don't remember how I created it :-).

Will do.  In the meanwhile, could you verify that reverting that commit
really fixes the problem (and, if possible, check if the mainline has
the same problem)?

This is really very strange - I don't see anything in that commit to
alter the return value or to stomp on anything that shouldn't be modified,
error or no error.  The rules from copy_from_user(to, from, n) are
	* if everything in n-bytes range starting at from is readable userland
memory, its contents should be copied into n-bytes range starting at to and
0 should be returned.
	* otherwise a poitive number between 1 and n should be returned;
if it returns n - m, everything in m-bytes range starting at from should be
readable userland memory and its contents should be copied into m-bytes
range starting at to, with remaining n - m bytes of n-bytes range starting
at to getting zeroed.  That includes the case of m equal to 0 (i.e. return
value being equal to n) - then nothing is copied and the entire n-bytes
range starting at to is zeroed.

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


Thread

Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-16 21:20 +0200
  Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-16 21:50 +0200
    Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-16 23:00 +0200
      Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-16 23:40 +0200
        Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Rich Felker <dalias@libc.org> - 2016-09-16 23:50 +0200
          Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-17 00:50 +0200
            Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Rich Felker <dalias@libc.org> - 2016-09-17 01:40 +0200
              Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-17 04:30 +0200
              Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-17 04:30 +0200
                Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Rob Landley <rob@landley.net> - 2016-09-18 06:50 +0200
                Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Rich Felker <dalias@libc.org> - 2016-09-18 17:20 +0200
        Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-17 00:50 +0200
          Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-17 01:10 +0200
  Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-16 22:10 +0200
    Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Guenter Roeck <linux@roeck-us.net> - 2016-09-16 22:40 +0200
      Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' lsorense@csclub.uwaterloo.ca (Lennart Sorensen) - 2016-09-16 22:50 +0200
      Re: Runtime failure running sh:qemu in -next due to 'sh: fix  copy_from_user()' Al Viro <viro@ZenIV.linux.org.uk> - 2016-09-16 23:30 +0200

csiph-web