diff options
author | Rob Clark <robdclark@gmail.com> | 2013-09-28 12:01:25 -0400 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2013-11-01 12:39:44 -0400 |
commit | b4b15c865da67e6f6d52af1441c52e0f74782344 (patch) | |
tree | 722d97a5b93ea4aa9c6549d87846d0f690586ec1 /drivers/gpu/drm/msm/msm_drv.c | |
parent | 05b849111c07454fd2f5b074ca7eb56ccdb8828c (diff) |
drm/msm: support render nodes
Enable support for drm render nodes for msm by flagging the ioctls
that are safe and only needed for rendering.
Signed-off-by: Rob Clark <robdclark@gmail.com>
Acked-by: David Brown <davidb@codeaurora.org>
Diffstat (limited to 'drivers/gpu/drm/msm/msm_drv.c')
-rw-r--r-- | drivers/gpu/drm/msm/msm_drv.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/drivers/gpu/drm/msm/msm_drv.c b/drivers/gpu/drm/msm/msm_drv.c index cfeebdd911dd..e7ac95a38725 100644 --- a/drivers/gpu/drm/msm/msm_drv.c +++ b/drivers/gpu/drm/msm/msm_drv.c | |||
@@ -650,13 +650,13 @@ static int msm_ioctl_wait_fence(struct drm_device *dev, void *data, | |||
650 | } | 650 | } |
651 | 651 | ||
652 | static const struct drm_ioctl_desc msm_ioctls[] = { | 652 | static const struct drm_ioctl_desc msm_ioctls[] = { |
653 | DRM_IOCTL_DEF_DRV(MSM_GET_PARAM, msm_ioctl_get_param, DRM_UNLOCKED|DRM_AUTH), | 653 | DRM_IOCTL_DEF_DRV(MSM_GET_PARAM, msm_ioctl_get_param, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
654 | DRM_IOCTL_DEF_DRV(MSM_GEM_NEW, msm_ioctl_gem_new, DRM_UNLOCKED|DRM_AUTH), | 654 | DRM_IOCTL_DEF_DRV(MSM_GEM_NEW, msm_ioctl_gem_new, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
655 | DRM_IOCTL_DEF_DRV(MSM_GEM_INFO, msm_ioctl_gem_info, DRM_UNLOCKED|DRM_AUTH), | 655 | DRM_IOCTL_DEF_DRV(MSM_GEM_INFO, msm_ioctl_gem_info, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
656 | DRM_IOCTL_DEF_DRV(MSM_GEM_CPU_PREP, msm_ioctl_gem_cpu_prep, DRM_UNLOCKED|DRM_AUTH), | 656 | DRM_IOCTL_DEF_DRV(MSM_GEM_CPU_PREP, msm_ioctl_gem_cpu_prep, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
657 | DRM_IOCTL_DEF_DRV(MSM_GEM_CPU_FINI, msm_ioctl_gem_cpu_fini, DRM_UNLOCKED|DRM_AUTH), | 657 | DRM_IOCTL_DEF_DRV(MSM_GEM_CPU_FINI, msm_ioctl_gem_cpu_fini, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
658 | DRM_IOCTL_DEF_DRV(MSM_GEM_SUBMIT, msm_ioctl_gem_submit, DRM_UNLOCKED|DRM_AUTH), | 658 | DRM_IOCTL_DEF_DRV(MSM_GEM_SUBMIT, msm_ioctl_gem_submit, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
659 | DRM_IOCTL_DEF_DRV(MSM_WAIT_FENCE, msm_ioctl_wait_fence, DRM_UNLOCKED|DRM_AUTH), | 659 | DRM_IOCTL_DEF_DRV(MSM_WAIT_FENCE, msm_ioctl_wait_fence, DRM_UNLOCKED|DRM_AUTH|DRM_RENDER_ALLOW), |
660 | }; | 660 | }; |
661 | 661 | ||
662 | static const struct vm_operations_struct vm_ops = { | 662 | static const struct vm_operations_struct vm_ops = { |
@@ -683,6 +683,7 @@ static struct drm_driver msm_driver = { | |||
683 | .driver_features = DRIVER_HAVE_IRQ | | 683 | .driver_features = DRIVER_HAVE_IRQ | |
684 | DRIVER_GEM | | 684 | DRIVER_GEM | |
685 | DRIVER_PRIME | | 685 | DRIVER_PRIME | |
686 | DRIVER_RENDER | | ||
686 | DRIVER_MODESET, | 687 | DRIVER_MODESET, |
687 | .load = msm_load, | 688 | .load = msm_load, |
688 | .unload = msm_unload, | 689 | .unload = msm_unload, |