hexagon: fix strncpy_from_user() error return
authorAl Viro <viro@zeniv.linux.org.uk>
Fri, 19 Aug 2016 01:16:49 +0000 (21:16 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 24 Sep 2016 08:07:44 +0000 (10:07 +0200)
commit0be8d73a033a3fee288c8f51990213449e94b204
tree99c28f51c998cb6f156aa22fbdb9da73e37ddb4c
parentdf243b41c66ebad9361bfb75fa022dd168ffb394
hexagon: fix strncpy_from_user() error return

commit f35c1e0671728d1c9abc405d05ef548b5fcb2fc4 upstream.

It's -EFAULT, not -1 (and contrary to the comment in there,
__strnlen_user() can return 0 - on faults).

Acked-by: Richard Kuo <rkuo@codeaurora.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/hexagon/include/asm/uaccess.h