Skip to content
Commit 21c42da1 authored by Dan Carpenter's avatar Dan Carpenter Committed by Rob Clark
Browse files

drm/msm: return -EFAULT if copy_from_user() fails



copy_from_user_inatomic() is actually a local function that returns
-EFAULT or positive values on error.  Otherwise copy_from_user() returns
the number of bytes remaining to be copied.  We want to return -EFAULT
here.

I removed an unlikely() because we just did a copy_from_user()
so I don't think it can possibly make a difference.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarRob Clark <robdclark@gmail.com>
parent f079f6d9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment