summaryrefslogtreecommitdiff
path: root/drivers/video
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2020-04-23 17:28:49 +0300
committerAl Viro <viro@zeniv.linux.org.uk>2020-05-29 18:04:56 +0300
commit694b9a7157d4dfaaea70dc740e9f8d43b8a1e95b (patch)
treea4eb89807edbfdd900689f13c19825c4ca7aa284 /drivers/video
parent83a4f2e70470be94c582b3d09e774fc9c4470b40 (diff)
downloadlinux-694b9a7157d4dfaaea70dc740e9f8d43b8a1e95b.tar.xz
amifb: get rid of pointless access_ok() calls
addresses passed only to get_user() and put_user() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/fbdev/amifb.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/video/fbdev/amifb.c b/drivers/video/fbdev/amifb.c
index 20e03e00b66d..6062104f3afb 100644
--- a/drivers/video/fbdev/amifb.c
+++ b/drivers/video/fbdev/amifb.c
@@ -1855,8 +1855,6 @@ static int ami_get_var_cursorinfo(struct fb_var_cursorinfo *var,
var->yspot = par->crsr.spot_y;
if (size > var->height * var->width)
return -ENAMETOOLONG;
- if (!access_ok(data, size))
- return -EFAULT;
delta = 1 << par->crsr.fmode;
lspr = lofsprite + (delta << 1);
if (par->bplcon0 & BPC0_LACE)
@@ -1935,8 +1933,6 @@ static int ami_set_var_cursorinfo(struct fb_var_cursorinfo *var,
return -EINVAL;
if (!var->height)
return -EINVAL;
- if (!access_ok(data, var->width * var->height))
- return -EFAULT;
delta = 1 << fmode;
lofsprite = shfsprite = (u_short *)spritememory;
lspr = lofsprite + (delta << 1);