uaccess: add missing __must_check attributes

The usercopy implementation comments describe that callers of the
copy_*_user() family of functions must always have their return values
checked.  This can be enforced at compile time with __must_check, so add
it where needed.

Signed-off-by: Kees Cook <>
Cc: Alexander Viro <>
Cc: Dan Carpenter <>
Signed-off-by: Andrew Morton <>
2 files changed