summaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2021-02-22 11:06:08 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2021-02-26 15:18:45 +0100
commit2da9a1a2b2f95d6bd98c5f81fb7d05ec22a1f04b (patch)
treefa41250c2e2d4cdb463969fa1d613f78d29a625c /drivers/gpu
parente926c474ebee404441c838d18224cd6f246a71b7 (diff)
downloadlinux-2da9a1a2b2f95d6bd98c5f81fb7d05ec22a1f04b.tar.bz2
drm/compat: more dummy implementations
drm_noop really doesn't do much, and who cares about the permission checks. So let's delete some code. Acked-by: Maxime Ripard <mripard@kernel.org> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20210222100608.400730-1-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/drm_ioc32.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/drivers/gpu/drm/drm_ioc32.c b/drivers/gpu/drm/drm_ioc32.c
index dc734d4828a1..33390f02f5eb 100644
--- a/drivers/gpu/drm/drm_ioc32.c
+++ b/drivers/gpu/drm/drm_ioc32.c
@@ -302,12 +302,8 @@ static int compat_drm_getstats(struct file *file, unsigned int cmd,
unsigned long arg)
{
drm_stats32_t __user *argp = (void __user *)arg;
- int err;
-
- err = drm_ioctl_kernel(file, drm_noop, NULL, 0);
- if (err)
- return err;
+ /* getstats is defunct, just clear */
if (clear_user(argp, sizeof(drm_stats32_t)))
return -EFAULT;
return 0;
@@ -820,13 +816,8 @@ typedef struct drm_update_draw32 {
static int compat_drm_update_draw(struct file *file, unsigned int cmd,
unsigned long arg)
{
- drm_update_draw32_t update32;
-
- if (copy_from_user(&update32, (void __user *)arg, sizeof(update32)))
- return -EFAULT;
-
- return drm_ioctl_kernel(file, drm_noop, NULL,
- DRM_AUTH|DRM_MASTER|DRM_ROOT_ONLY);
+ /* update_draw is defunct */
+ return 0;
}
#endif